diff options
| author | Stephen Blott | 2014-12-21 07:19:37 +0000 |
|---|---|---|
| committer | Stephen Blott | 2014-12-21 07:19:37 +0000 |
| commit | ae3794d10f11f61d7d78c523afc3abc4d5f72467 (patch) | |
| tree | 2cb0b400596849a5f5c318b8987aa9abf8d36ffb | |
| parent | 681bc13783d1f1b8579f810dbbc68174a84c1a10 (diff) | |
| download | vimium-ae3794d10f11f61d7d78c523afc3abc4d5f72467.tar.bz2 | |
Exclusion; focus last rule.
| -rw-r--r-- | pages/options.coffee | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/pages/options.coffee b/pages/options.coffee index 1cd0661f..c3f619ca 100644 --- a/pages/options.coffee +++ b/pages/options.coffee @@ -107,14 +107,15 @@ class ExclusionRulesOption extends Option for rule in rules @appendRule rule - # If this is the popup page (@url is defined), then hide rules which do not match @url. If no rules - # match, then add a default rule. + # If this is the popup page (@url is truthy), then hide rules which do not match @url. If no rules + # match, then add a default rule. Focus the passKeys field in the last (most recent) rule. if @url haveMatch = false for element in @element.getElementsByClassName "exclusionRuleTemplateInstance" pattern = element.children[0].firstChild.value.trim() if @url.match bgExclusions.RegexpCache.get pattern haveMatch = true + element.children[1].firstChild.focus() else element.style.display = 'none' @addRule() unless haveMatch |
