diff options
| author | Stephen Blott | 2017-04-13 15:57:32 +0100 |
|---|---|---|
| committer | Stephen Blott | 2017-04-18 05:50:51 +0100 |
| commit | b88ee579c4471d27dbb4aba59215f5e85b7d32a2 (patch) | |
| tree | 5a019495f9a262c7bc45c08f74230a7496bf304d /content_scripts/link_hints.coffee | |
| parent | ee83d1a9603a304c9328d3587e2db829fcec7aaf (diff) | |
| download | vimium-b88ee579c4471d27dbb4aba59215f5e85b7d32a2.tar.bz2 | |
Avoid repeating Backspace and Delete keys.
Diffstat (limited to 'content_scripts/link_hints.coffee')
| -rw-r--r-- | content_scripts/link_hints.coffee | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/content_scripts/link_hints.coffee b/content_scripts/link_hints.coffee index 4481ae92..a95d2123 100644 --- a/content_scripts/link_hints.coffee +++ b/content_scripts/link_hints.coffee @@ -175,7 +175,7 @@ class LinkHintsMode @hintMode.onExit (event) => if event?.type == "click" or (event?.type == "keydown" and - (KeyboardUtils.isEscape(event) or event.key in ["Backspace", "Delete"])) + (KeyboardUtils.isEscape(event) or KeyboardUtils.isBackspace event)) HintCoordinator.sendMessage "exit", isSuccess: false # Note(philc): Append these markers as top level children instead of as child nodes to the link itself, @@ -266,7 +266,7 @@ class LinkHintsMode # Therefore, we ensure that it's always removed when hint mode exits. See #1911 and #1926. @hintMode.onExit -> handlerStack.remove handlerId - else if event.key in [ "Backspace", "Delete" ] + else if KeyboardUtils.isBackspace event if @markerMatcher.popKeyChar() @updateVisibleMarkers() else |
