1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2025-12-20 22:28:00 +01:00

Fix regex filters for site-specific mappings.

--HG--
branch : key-processing
This commit is contained in:
Kris Maglione
2011-01-27 20:58:13 -05:00
parent a8eed85aaf
commit 7f15781e41
2 changed files with 3 additions and 3 deletions

View File

@@ -324,7 +324,7 @@ var CommandMode = Class("CommandMode", {
if (this.command || stack.pop && commandline.command) { if (this.command || stack.pop && commandline.command) {
this.onChange(commandline.command); this.onChange(commandline.command);
if (this.completions) if (this.completions)
this.completions.autocompleteTimer.flush(true); this.completions.complete(true, false);
} }
}, },

View File

@@ -311,8 +311,8 @@ var Styles = Module("Styles", {
matchFilter: function (filter) { matchFilter: function (filter) {
if (filter === "*") if (filter === "*")
var test = function test(uri) true; var test = function test(uri) true;
else if (filter[0] == "^") { else if (filter[0] === "^") {
let re = RegExp(filter[0]); let re = RegExp(filter);
test = function test(uri) re.test(uri.spec); test = function test(uri) re.test(uri.spec);
} }
else if (/[*]$/.test(filter)) { else if (/[*]$/.test(filter)) {