Skip to content

Commit

Permalink
toggle gizmos shortcut changed to alt key
Browse files Browse the repository at this point in the history
  • Loading branch information
kleber-swf committed Sep 3, 2021
1 parent b8a6ee8 commit 1057e21
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
5 changes: 4 additions & 1 deletion src/data/actions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,10 @@ class ActionsClass {
}

private onKeyDown(e: KeyboardEvent) {
const k = (e.ctrlKey ? 'ctrl+' : '') + (e.shiftKey ? 'shift+' : '') + e.key;
const k = (e.ctrlKey ? 'ctrl+' : '')
+ (e.altKey ? 'alt+' : '')
+ (e.shiftKey ? 'shift+' : '')
+ e.key;
if (k in this.actions) {
const action = this.actions[k];
action.command();
Expand Down
2 changes: 1 addition & 1 deletion src/plugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ export class Plugin extends Phaser.Plugin {
id: 'TOGGLE_GIZMOS',
toggle: true,
hold: true,
shortcut: 'shift+Shift',
shortcut: 'alt+Alt',
command: () => Preferences.gizmos = !Preferences.gizmos,
state: () => Preferences.gizmos,
},
Expand Down

0 comments on commit 1057e21

Please sign in to comment.