mirror of
https://github.com/atom/atom.git
synced 2026-01-23 13:58:08 -05:00
Prefix events handled by root-view with "root-view:"
This commit is contained in:
@@ -20,4 +20,8 @@ window.keymap.bindKeys 'body'
|
||||
'meta-v': 'core:paste'
|
||||
pageup: 'core:page-up'
|
||||
pagedown: 'core:page-down'
|
||||
'meta-S': 'save-all'
|
||||
|
||||
'meta-S': 'root-view:save-all'
|
||||
'meta-+': 'root-view:increase-font-size'
|
||||
'meta--': 'root-view:decrease-font-size'
|
||||
'ctrl-w w': 'root-view:focus-next-pane'
|
||||
|
||||
@@ -19,9 +19,7 @@ window.keymap.bindKeys '.editor',
|
||||
'meta-]': 'editor:indent-selected-rows'
|
||||
'meta-{': 'editor:show-previous-buffer'
|
||||
'meta-}': 'editor:show-next-buffer'
|
||||
'meta-+': 'editor:increase-font-size'
|
||||
'meta--': 'editor:decrease-font-size'
|
||||
'meta-/': 'editor:toggle-line-comments'
|
||||
'ctrl-w w': 'editor:focus-next-pane'
|
||||
'ctrl-W': 'editor:select-word'
|
||||
'meta-alt-p': 'editor:log-cursor-scope'
|
||||
|
||||
|
||||
@@ -73,10 +73,10 @@ class RootView extends View
|
||||
@project.setPath(path) unless @project.getRootDirectory()
|
||||
@setTitle(path)
|
||||
|
||||
@on 'increase-font-size', => @setFontSize(@getFontSize() + 1)
|
||||
@on 'decrease-font-size', => @setFontSize(@getFontSize() - 1)
|
||||
@on 'focus-next-pane', => @focusNextPane()
|
||||
@on 'save-all', => @saveAll()
|
||||
@on 'root-view:increase-font-size', => @setFontSize(@getFontSize() + 1)
|
||||
@on 'root-view:decrease-font-size', => @setFontSize(@getFontSize() - 1)
|
||||
@on 'root-view:focus-next-pane', => @focusNextPane()
|
||||
@on 'root-view:save-all', => @saveAll()
|
||||
|
||||
afterAttach: (onDom) ->
|
||||
@focus() if onDom
|
||||
|
||||
Reference in New Issue
Block a user