mirror of https://github.com/zulip/zulip.git
narrow: Remove `narrow_activated.zulip` event trigger.
This commit is contained in:
parent
654c3240e4
commit
990d7fb37d
|
@ -46,14 +46,6 @@ global.patch_builtin('setTimeout', (f, t) => {
|
|||
f();
|
||||
});
|
||||
|
||||
function stub_trigger(f) {
|
||||
set_global('document', 'document-stub');
|
||||
$('document-stub').trigger = f;
|
||||
$.Event = (name) => {
|
||||
assert.equal(name, 'narrow_activated.zulip');
|
||||
};
|
||||
}
|
||||
|
||||
set_global('muting', {
|
||||
is_topic_muted: () => false,
|
||||
});
|
||||
|
@ -92,8 +84,6 @@ function test_helper() {
|
|||
stub('compose', 'update_stream_button_for_stream');
|
||||
stub('compose', 'update_stream_button_for_private');
|
||||
|
||||
stub_trigger(() => { events.push('trigger event'); });
|
||||
|
||||
blueslip.debug = noop;
|
||||
|
||||
message_util.add_messages = (messages, target_list, opts) => {
|
||||
|
@ -223,7 +213,6 @@ run_test('basics', () => {
|
|||
'stream_list.handle_narrow_activated',
|
||||
'typing_events.render_notifications_for_narrow',
|
||||
'tab_bar.initialize',
|
||||
'trigger event',
|
||||
]);
|
||||
|
||||
current_msg_list.selected_id = () => { return -1; };
|
||||
|
|
|
@ -273,9 +273,6 @@ exports.activate = function (raw_operators, opts) {
|
|||
typing_events.render_notifications_for_narrow();
|
||||
tab_bar.initialize();
|
||||
|
||||
$(document).trigger($.Event('narrow_activated.zulip', {msg_list: message_list.narrowed,
|
||||
filter: current_filter,
|
||||
trigger: opts.trigger}));
|
||||
msg_list.initial_core_time = new Date();
|
||||
setTimeout(function () {
|
||||
msg_list.initial_free_time = new Date();
|
||||
|
|
Loading…
Reference in New Issue