diff options
| -rw-r--r-- | README.md | 5 | ||||
| -rw-r--r-- | content_scripts/link_hints.coffee | 8 | ||||
| -rw-r--r-- | lib/keyboard_utils.coffee | 3 |
3 files changed, 14 insertions, 2 deletions
@@ -159,6 +159,11 @@ Please see [CONTRIBUTING.md](https://github.com/philc/vimium/blob/master/CONTRIB Release Notes ------------- +Changes since previous release (not in the Chrome Store version) + +- Bug fixes: + - `<c-a-[>` is no longer handled (incorrectly) as `Escape`. This also affects `<Alt-Gr-[>`. + 1.56 (2016-06-11) - Vimium now works around a Chromium bug affecting users with non-standard keyboard layouts (see #2147). diff --git a/content_scripts/link_hints.coffee b/content_scripts/link_hints.coffee index 0f2425c3..2548abb3 100644 --- a/content_scripts/link_hints.coffee +++ b/content_scripts/link_hints.coffee @@ -326,6 +326,8 @@ class LinkHintsMode else if localHintDescriptor.reason == "Scroll." # Tell the scroller that this is the activated element. handlerStack.bubbleEvent "DOMActivate", target: clickEl + else if localHintDescriptor.reason == "Open." + clickEl.open = !clickEl.open else if DomUtils.isSelectable clickEl window.focus() DomUtils.simulateSelect clickEl @@ -621,7 +623,8 @@ LocalHints = when "button", "select" isClickable ||= not element.disabled when "label" - isClickable ||= element.control? and (@getVisibleClickable element.control).length == 0 + isClickable ||= element.control? and not element.control.disabled and + (@getVisibleClickable element.control).length == 0 when "body" isClickable ||= if element == document.body and not windowIsFocused() and @@ -637,6 +640,9 @@ LocalHints = isClickable ||= if element.clientHeight < element.scrollHeight and Scroller.isScrollableElement element reason = "Scroll." + when "details" + isClickable = true + reason = "Open." # An element with a class name containing the text "button" might be clickable. However, real clickables # are often wrapped in elements with such class names. So, when we find clickables based only on their diff --git a/lib/keyboard_utils.coffee b/lib/keyboard_utils.coffee index 3871b066..dabf864d 100644 --- a/lib/keyboard_utils.coffee +++ b/lib/keyboard_utils.coffee @@ -81,7 +81,8 @@ KeyboardUtils = isEscape: (event) -> # c-[ is mapped to ESC in Vim by default. - (event.keyCode == @keyCodes.ESC) || (event.ctrlKey && @getKeyChar(event) == '[' and not event.metaKey) + (event.keyCode == @keyCodes.ESC) || + (event.ctrlKey && @getKeyChar(event) == '[' and not event.metaKey and not event.altKey) # TODO. This is probably a poor way of detecting printable characters. However, it shouldn't incorrectly # identify any of chrome's own keyboard shortcuts as printable. |
