Skip to content

Commit

Permalink
Add accelerators to context menu
Browse files Browse the repository at this point in the history
  • Loading branch information
inukshuk committed Mar 16, 2019
1 parent d830b0f commit d6adaa2
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 16 deletions.
5 changes: 1 addition & 4 deletions res/menu/app.en.yml
Original file line number Diff line number Diff line change
Expand Up @@ -275,11 +275,8 @@ en:
- label: '&Edit'
submenu:
- *undo
- id: 'redo'
label: '&Redo'
- <<: *redo
accelerator: 'Control+Y'
command: 'app:redo'
enabled: false
- type: 'separator'
- *cut
- *copy
Expand Down
39 changes: 27 additions & 12 deletions res/menu/context.en.yml
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
en:
linux:
history: &history
- id: 'undo'
history:
- &undo
id: 'undo'
label: 'Undo'
command: 'app:undo'
enabled: false
- id: 'redo'
accelerator: 'CmdOrCtrl+Z'
- &redo
id: 'redo'
label: 'Redo'
command: 'app:redo'
enabled: false
sidebar: &sidebar
- label: 'Hide Sidebar'
command: 'app:hide-sidebar'
enabled: false
accelerator: 'Shift+CmdOrCtrl+Z'
project: &project
- label: 'Rename Project'
command: 'app:rename-project'
Expand All @@ -21,6 +21,7 @@ en:
lists: &lists
- label: 'New List'
command: 'app:create-list'
accelerator: 'CmdOrCtrl+Shift+L'
list: &list
- label: 'Rename List'
command: 'app:rename-list'
Expand All @@ -29,7 +30,8 @@ en:
tags: &tags
- label: 'New Tag'
command: 'app:create-tag'
- label: 'Export All Tags …'
accelerator: 'CmdOrCtrl+Shift+A'
- label: 'Export Tags …'
command: 'app:export-tags'
- label: 'Default Tag Color'
submenu:
Expand Down Expand Up @@ -133,6 +135,7 @@ en:
items: &items
- label: 'New Item'
command: 'app:create-item'
accelerator: 'CmdOrCtrl+Shift+N'
item: &item
- label: 'Explode Item'
command: 'app:explode-item'
Expand All @@ -157,8 +160,10 @@ en:
item-rotate: &item-rotate
- label: 'Rotate Left'
command: 'app:rotate-item-left'
accelerator: 'CmdOrCtrl+['
- label: 'Rotate Right'
command: 'app:rotate-item-right'
accelerator: 'CmdOrCtrl+]'
item-bulk: &item-bulk
- label: 'Merge Selected Items'
command: 'app:merge-item'
Expand Down Expand Up @@ -193,8 +198,10 @@ en:
photo-rotate: &photo-rotate
- label: 'Rotate Left'
command: 'app:rotate-photo-left'
accelerator: 'CmdOrCtrl+['
- label: 'Rotate Right'
command: 'app:rotate-photo-right'
accelerator: 'CmdOrCtrl+]'
selection: &selection
- label: 'Delete Selection'
command: 'app:delete-selection'
Expand All @@ -204,8 +211,10 @@ en:
selection-rotate: &selection-rotate
- label: 'Rotate Left'
command: 'app:rotate-selection-left'
accelerator: 'CmdOrCtrl+['
- label: 'Rotate Right'
command: 'app:rotate-selection-right'
accelerator: 'CmdOrCtrl+]'
item-deleted: &item-deleted
- label: 'Restore Item'
command: 'app:restore-item'
Expand Down Expand Up @@ -239,15 +248,19 @@ en:
dev: &dev
- label: 'Reload'
command: 'win:reload'
accelerator: 'CmdOrCtrl+R'
- label: 'Reload Styles'
command: 'win:refresh'
accelerator: 'CmdOrCtrl+S'
- type: 'separator'
- label: 'Inspect'
command: 'app:inspect'
accelerator: 'CmdOrCtrl+D'

darwin:
history: *history
sidebar: *sidebar
history:
- *undo
- *redo
project: *project
lists: *lists
list: *list
Expand Down Expand Up @@ -275,8 +288,10 @@ en:
dev: *dev

win32:
history: *history
sidebar: *sidebar
history:
- *undo
- <<: *redo
accelerator: 'Control+Y'
project: *project
lists: *lists
list: *list
Expand Down

0 comments on commit d6adaa2

Please sign in to comment.