diff options
author | Nivesh Rajbhandari | 2012-04-17 11:10:10 -0700 |
---|---|---|
committer | Nivesh Rajbhandari | 2012-04-17 11:10:10 -0700 |
commit | 6d3af6cb9dc8223102854ad95a5c4c501fc62c8b (patch) | |
tree | 07afdbeacd26f01414933d5b3318786cec30f4a8 /js/mediators/keyboard-mediator.js | |
parent | 2a87a750f06003fc62e8e0e73983e14ce24fc7a7 (diff) | |
parent | cacb4a21825818af392c2949967b0f3c1df509c5 (diff) | |
download | ninja-6d3af6cb9dc8223102854ad95a5c4c501fc62c8b.tar.gz |
Merge branch 'refs/heads/ninja-internal' into WebGLFixes
Diffstat (limited to 'js/mediators/keyboard-mediator.js')
-rwxr-xr-x | js/mediators/keyboard-mediator.js | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/js/mediators/keyboard-mediator.js b/js/mediators/keyboard-mediator.js index 82596693..79967799 100755 --- a/js/mediators/keyboard-mediator.js +++ b/js/mediators/keyboard-mediator.js | |||
@@ -168,6 +168,24 @@ exports.KeyboardMediator = Montage.create(Component, { | |||
168 | return; | 168 | return; |
169 | } | 169 | } |
170 | 170 | ||
171 | // Paint Bucket Tool and Ink Bottle tools share keyboard shortcut K | ||
172 | if(evt.keyCode === Keyboard.K ) { | ||
173 | evt.preventDefault(); | ||
174 | if(this.application.ninja.toolsData.selectedTool.id === "FillTool") { | ||
175 | this.application.ninja.handleSelectTool({"detail": this.application.ninja.toolsData.defaultToolsData[11]}); | ||
176 | } else { | ||
177 | this.application.ninja.handleSelectTool({"detail": this.application.ninja.toolsData.defaultToolsData[10]}); | ||
178 | } | ||
179 | return; | ||
180 | } | ||
181 | |||
182 | // Shortcut for Eyedropper Tool is I | ||
183 | if(evt.keyCode === Keyboard.I ) { | ||
184 | evt.preventDefault(); | ||
185 | this.application.ninja.handleSelectTool({"detail": this.application.ninja.toolsData.defaultToolsData[12]}); | ||
186 | return; | ||
187 | } | ||
188 | |||
171 | // Rotate Stage Tool is M | 189 | // Rotate Stage Tool is M |
172 | if(evt.keyCode === Keyboard.M ) { | 190 | if(evt.keyCode === Keyboard.M ) { |
173 | evt.preventDefault(); | 191 | evt.preventDefault(); |