summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDoug Kearns <dougkearns@gmail.com>2007-11-09 11:23:43 +0000
committerDoug Kearns <dougkearns@gmail.com>2007-11-09 11:23:43 +0000
commit2cf6003d0f6f848ed14381346982240a518f3b83 (patch)
treed7968aa03ae83ab18c4b6139e5708f2fd5317b78
parent3d9c6c09308d25938ce9fd9f07f82584ae4b097e (diff)
downloadpentadactyl-2cf6003d0f6f848ed14381346982240a518f3b83.tar.gz
add a validator for the 'activate' option
-rw-r--r--content/options.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/content/options.js b/content/options.js
index 4d680485..cce3b61c 100644
--- a/content/options.js
+++ b/content/options.js
@@ -436,7 +436,8 @@ vimperator.Options = function() //{{{
"<li><b>tabopen</b>: <code class=\"command\">:tabopen[!]</code> command</li>" +
"<li><b>paste</b>: <code class=\"mapping\">P</code> and <code class=\"mapping\">gP</code> mappings</li>" +
"</ul>",
- default_value: "homepage,quickmark,tabopen,paste"
+ default_value: "homepage,quickmark,tabopen,paste",
+ validator: function(value) { return value.split(",").every(function(item) { return /^(homepage|quickmark|tabopen|paste|)$/.test(item); }); }
}
));
this.add(new vimperator.Option(["complete", "cpt"], "charlist",