Skip to content
This repository has been archived by the owner on Sep 6, 2021. It is now read-only.

Make Windows specific keybindings usable on Linux #2000

Closed
wants to merge 3 commits into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion src/command/KeyBindingManager.js
Original file line number Diff line number Diff line change
Expand Up @@ -422,12 +422,16 @@ define(function (require, exports, module) {
var keyBinding;
results = [];

keyBindings.forEach(function (keyBindingRequest) {
keyBindings.forEach(function addSingleBinding(keyBindingRequest) {
keyBinding = _addBinding(commandID, keyBindingRequest, keyBindingRequest.platform);

if (keyBinding) {
results.push(keyBinding);
}
if(keyBindingRequest.platform && keyBindingRequest.platform == "win") {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To pass JSLint, you need a space after if and you need to use === instead of ==

keyBindingRequest.platform = "linux";
addSingleBinding(keyBindingRequest);
}
});
} else {
results = _addBinding(commandID, keyBindings, platform);
Expand Down