mirror of
https://github.com/atom/atom.git
synced 2026-01-23 13:58:08 -05:00
Use subscribe for window focus event handler
This commit is contained in:
@@ -80,7 +80,7 @@ class RootView extends View
|
||||
handleEvents: ->
|
||||
@command 'toggle-dev-tools', => atom.toggleDevTools()
|
||||
@on 'focus', (e) => @handleFocus(e)
|
||||
$(window).on 'focus', (e) =>
|
||||
@subscribe $(window), 'focus', (e) =>
|
||||
@handleFocus(e) if document.activeElement is document.body
|
||||
|
||||
@on 'root-view:active-path-changed', (e, path) =>
|
||||
|
||||
Reference in New Issue
Block a user