-
Notifications
You must be signed in to change notification settings - Fork 7.6k
Use windows-specific keybindings on linux #2331
Conversation
While keeping Win and Mac specific keybindings separate.
…nux-keybindings Conflicts: src/command/KeyBindingManager.js
…c-specific override. remove linux patch.
One quick note on this -- I think during sprint planning we talked about doing something a little farther from the original pull request. I think we wanted to have a notion of a default keybinding alongside platform-specific (so rather than registering Mac-specific + Win-specific, we could register Mac-specific plus default). We also talked about making it possible to register Linux-specific bindings distinct from Windows ones, but I forget where we landed on whether that needs to happen now or could wait. |
Yes, that's also how I remember it. |
Thanks for the reminders guys. I'll get to it now. |
Long story, but I was working on this inside the linux shell and even though my date/time was managed automatically my system date was way wrong. Commits 6881bf2 and 9bca94b were submitted today 12/21 near 3:30pm. Anyhow, I've fixed the base-config file to change windows-specific bindings default (for win and linux) and leave the mac shortcut untouched. I also corrected some logic around detecting mac vs. non-mac. Ready for review. |
I guess this would mean extra work converting all those win+mac bindings Even so, I think this is a very good design decision, and only wish this On Thu, Dec 13, 2012 at 5:06 AM, Jason San Jose [email protected]:
|
@@ -407,7 +409,7 @@ define(function (require, exports, module) { | |||
* @param {?({key: string, displayKey: string} | Array.<{key: string, displayKey: string, platform: string}>)} keyBindings - a single key binding |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wrap these lines at 80 (or so) chars.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed
@jasonsanjose : @pritambaral makes a good point. Maybe there should be a check for the case where:
Then use win keybinding |
Done with initial review. |
By request, added a fallback for linux to use windows bindings. Also, if a linux or generic binding comes in after a windows binding is used, the windows binding is clobbered. |
@@ -46,7 +46,7 @@ define(function (require, exports, module) { | |||
CommandsManagerModule = require("command/CommandManager"), | |||
LiveDevelopmentModule = require("LiveDevelopment/LiveDevelopment"), | |||
InspectorModule = require("LiveDevelopment/Inspector/Inspector"), | |||
CSSDocumentModule = require("LiveDevelopment/documents/CSSDocument"), | |||
CSSDocumentModule = require("LiveDevelopment/Documents/CSSDocument"), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixes a bug loading unit tests on linux
The "fallback for linux to use windows bindings" code looks good. @pritambaral Please create a test extension to verify this works. |
Looks good. Merging. |
Use windows-specific keybindings on linux
Completes pull request #2000 from @pritambaral. Adds additional check for linux as the current platform before mapping linux.