diff options
| author | mrmr1993 | 2015-05-01 07:02:06 +0100 |
|---|---|---|
| committer | mrmr1993 | 2015-05-01 07:02:06 +0100 |
| commit | 1d7cc1e43ada7baf394f58e2f0e586a5c252f7b3 (patch) | |
| tree | 723ab33896b39bd4ec586c70b379b5913d45329c | |
| parent | 2bd819e98d85fbc5d463735afec53f3b5433fd2f (diff) | |
| download | vimium-1d7cc1e43ada7baf394f58e2f0e586a5c252f7b3.tar.bz2 | |
Don't try and enter GrabBackFocus mode if the last click introduced focus
| -rw-r--r-- | content_scripts/vimium_frontend.coffee | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/content_scripts/vimium_frontend.coffee b/content_scripts/vimium_frontend.coffee index 661ea1c4..e1d7b581 100644 --- a/content_scripts/vimium_frontend.coffee +++ b/content_scripts/vimium_frontend.coffee @@ -139,6 +139,9 @@ class GrabBackFocus extends Mode handlerStack.push _name: "GrabBackFocus-pushState-monitor" click: (event) -> + # If a focusable element is focused, the user must have clicked on it. Retain focus and bail. + return true if DomUtils.isFocusable document.activeElement + target = event.target while target # Often, a link which triggers a content load and url change with javascript will also have the new |
