diff options
| author | Luan Nico | 2014-08-22 08:55:42 -0300 |
|---|---|---|
| committer | Luan Nico | 2014-08-22 08:55:42 -0300 |
| commit | 34e3e91de12128f1d23c120f97c80b41dae9b42c (patch) | |
| tree | 31ac5f499920865a5a0937bc7628008bc5c3d840 | |
| parent | fdbf483207c5654885290da88d16a156e86bc375 (diff) | |
| download | vimium-34e3e91de12128f1d23c120f97c80b41dae9b42c.tar.bz2 | |
Changed key biding to use right arrow instead of tab, returning previous tab functionalities
| -rw-r--r-- | content_scripts/vomnibar.coffee | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/content_scripts/vomnibar.coffee b/content_scripts/vomnibar.coffee index b7703583..95e080e8 100644 --- a/content_scripts/vomnibar.coffee +++ b/content_scripts/vomnibar.coffee @@ -90,15 +90,19 @@ class VomnibarUI if (KeyboardUtils.isEscape(event)) return "dismiss" else if (key == "up" || + (event.shiftKey && event.keyCode == keyCodes.tab) || (event.ctrlKey && (key == "k" || key == "p"))) return "up" else if (key == "down" || + (event.keyCode == keyCodes.tab && !event.shiftKey) || (event.ctrlKey && (key == "j" || key == "n"))) return "down" else if (event.keyCode == keyCodes.enter) return "enter" - else if (event.keyCode == keyCodes.tab) + else if (key == "right") return "complete" + else if (key == "left") + return "current" onKeydown: (event) -> action = @actionFromKeyEvent(event) @@ -138,6 +142,8 @@ class VomnibarUI @input.value = window.location else @input.value = @completions[@selection].url + else if (action == "current") + @input.value = window.location # It seems like we have to manually suppress the event here and still return true. event.stopPropagation() |
