remove clickCatcher: online_notification
Known bug: clicks into .navigation get lost
This commit is contained in:
parent
8df25b9cc2
commit
abbbe2f216
1 changed files with 4 additions and 11 deletions
|
@ -40,6 +40,7 @@ class App.OnlineNotificationWidget extends App.Controller
|
||||||
|
|
||||||
release: =>
|
release: =>
|
||||||
@removeContainer()
|
@removeContainer()
|
||||||
|
$(window).off 'click.notifications'
|
||||||
App.OnlineNotification.unsubscribe( @subscribeId )
|
App.OnlineNotification.unsubscribe( @subscribeId )
|
||||||
|
|
||||||
access: ->
|
access: ->
|
||||||
|
@ -65,11 +66,6 @@ class App.OnlineNotificationWidget extends App.Controller
|
||||||
processData: true
|
processData: true
|
||||||
)
|
)
|
||||||
|
|
||||||
removeClickCatcher: =>
|
|
||||||
return if !@clickCatcher
|
|
||||||
@clickCatcher.remove()
|
|
||||||
@clickCatcher = null
|
|
||||||
|
|
||||||
onShow: =>
|
onShow: =>
|
||||||
@updateContent()
|
@updateContent()
|
||||||
|
|
||||||
|
@ -95,14 +91,11 @@ class App.OnlineNotificationWidget extends App.Controller
|
||||||
@hidePopover()
|
@hidePopover()
|
||||||
)
|
)
|
||||||
|
|
||||||
# add clickCatcher
|
notificationsContainer.on 'click', @stopPropagation
|
||||||
@clickCatcher = new App.ClickCatcher
|
$(window).on 'click.notifications', @hidePopover
|
||||||
holder: @el.offsetParent()
|
|
||||||
callback: @hidePopover
|
|
||||||
zIndexScale: 4
|
|
||||||
|
|
||||||
onHide: =>
|
onHide: =>
|
||||||
@removeClickCatcher()
|
$(window).off 'click.notifications'
|
||||||
|
|
||||||
hidePopover: =>
|
hidePopover: =>
|
||||||
@toggle.popover('hide')
|
@toggle.popover('hide')
|
||||||
|
|
Loading…
Reference in a new issue