mirror of
https://github.com/zulip/zulip.git
synced 2025-11-03 13:33:24 +00:00
recent_topics: Directly pass jquery element instead of event object.
This commit is contained in:
@@ -216,7 +216,10 @@ export function in_content_editable_widget(e) {
|
||||
|
||||
// Returns true if we handled it, false if the browser should.
|
||||
export function process_escape_key(e) {
|
||||
if (hashchange.in_recent_topics_hash() && recent_topics.change_focused_element(e, "escape")) {
|
||||
if (
|
||||
hashchange.in_recent_topics_hash() &&
|
||||
recent_topics.change_focused_element($(e.target), "escape")
|
||||
) {
|
||||
// Recent topics uses escape to make focus from RT search / filters to topics table.
|
||||
// If focus already in table it returns false.
|
||||
return true;
|
||||
@@ -532,7 +535,7 @@ export function process_hotkey(e, hotkey) {
|
||||
!$(".user-list-filter").is(":focus") &&
|
||||
!$(".stream-list-filter").is(":focus")
|
||||
) {
|
||||
return recent_topics.change_focused_element(e, event_name);
|
||||
return recent_topics.change_focused_element($(e.target), event_name);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user