aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStephen Blott2015-01-30 10:57:28 +0000
committerStephen Blott2015-01-30 10:58:18 +0000
commitec4e2791537c57887471f0d7a6ab1d4e642d1744 (patch)
tree1f8e050ede116f36c0657340c90969c43ad423f1
parente268f1fd57e364feacf372bac92d991fd3abe603 (diff)
downloadvimium-ec4e2791537c57887471f0d7a6ab1d4e642d1744.tar.bz2
Visual/edit modes: correctly suppress backspace/delete.
-rw-r--r--content_scripts/mode_visual_edit.coffee2
1 files changed, 1 insertions, 1 deletions
diff --git a/content_scripts/mode_visual_edit.coffee b/content_scripts/mode_visual_edit.coffee
index 33e854c8..f03c01ab 100644
--- a/content_scripts/mode_visual_edit.coffee
+++ b/content_scripts/mode_visual_edit.coffee
@@ -16,7 +16,7 @@ class SuppressPrintable extends Mode
return @stopBubblingAndTrue if not KeyboardUtils.isPrintable event
return @suppressEvent if event.type != "keydown"
# Completely suppress Backspace and Delete, they change the selection.
- @suppressEvent if event.keyCode in [ 8, 46 ]
+ return @suppressEvent if event.keyCode in [ keyCodes.backspace, keyCodes.deleteKey ]
# Suppress propagation (but not preventDefault) for keydown, printable events.
DomUtils.suppressPropagation event
@stopBubblingAndFalse