diff options
| author | Phil Crosby | 2011-01-30 18:04:45 -0800 |
|---|---|---|
| committer | Phil Crosby | 2011-01-30 18:09:22 -0800 |
| commit | 35d58590b0e09e88c92ca3d49b5ba3b1ff622665 (patch) | |
| tree | 675afce8b9a48553475d8c1921417f6a99639465 /commands.js | |
| parent | 4f2d27d850c4ea82adc367362bbee41f4943c1a6 (diff) | |
| download | vimium-35d58590b0e09e88c92ca3d49b5ba3b1ff622665.tar.bz2 | |
Make "d" and "u" scroll up and down a page instead of closing and restoring tabs. This implements #274.
The motivation behind this change is that scrolling a page is far more common than
closing a tab, and so those actions should be on a hotkey which doesn't require a modifier.
Once you get used to scrolling without hitting ctrl, you won't be able to go back.
For existing users, this change also adds a custom mapping for them in their preferences to preserve
the old behavior as they upgrade from 1.21 to 1.22.
Diffstat (limited to 'commands.js')
| -rw-r--r-- | commands.js | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/commands.js b/commands.js index f2b19467..de70a0a9 100644 --- a/commands.js +++ b/commands.js @@ -99,6 +99,12 @@ function clearKeyMappingsAndSetDefaults() { "zL": "scrollToRight", "<c-e>": "scrollDown", "<c-y>": "scrollUp", + + // scrollPageDown and scrollPageUp are mapped to two keys because they are very common actions so we + // want them to be mapped without a modifier key, but we also want to be faithful to Vim convention which + // has them on ctrl+D and ctrl+U. + "d": "scrollPageDown", + "u": "scrollPageUp", "<c-d>": "scrollPageDown", "<c-u>": "scrollPageUp", "<c-f>": "scrollFullPageDown", @@ -137,8 +143,8 @@ function clearKeyMappingsAndSetDefaults() { "gT": "previousTab", "t": "createTab", - "d": "removeTab", - "u": "restoreTab", + "x": "removeTab", + "X": "restoreTab", "gf": "nextFrame" }; |
