Just enable keyboard bindings if widget is shown.
This commit is contained in:
parent
715ed8e6da
commit
dc4c8b0e99
1 changed files with 2 additions and 1 deletions
|
@ -57,7 +57,6 @@ class App.OnlineNotificationWidget extends App.Controller
|
|||
)
|
||||
|
||||
$(window).on 'click.notifications', @hide
|
||||
$(window).on 'keydown.notifications', @listNavigate
|
||||
|
||||
@updateContent()
|
||||
|
||||
|
@ -201,11 +200,13 @@ class App.OnlineNotificationWidget extends App.Controller
|
|||
@show()
|
||||
|
||||
show: =>
|
||||
$(window).on 'keydown.notifications', @listNavigate
|
||||
@shown = true
|
||||
@el.show()
|
||||
@updateHeight()
|
||||
|
||||
hide: =>
|
||||
$(window).off 'keydown.notifications'
|
||||
@shown = false
|
||||
@el.hide()
|
||||
|
||||
|
|
Loading…
Reference in a new issue