diff options
author | Brendan Taylor <whateley@gmail.com> | 2011-09-26 18:28:43 +0000 |
---|---|---|
committer | Brendan Taylor <whateley@gmail.com> | 2011-09-26 18:28:43 +0000 |
commit | 4bb5c202f366bb1818054ceaa89474545344d554 (patch) | |
tree | 826f394c4f8f19a13f9ac0e414e47b4a00ce9e62 /examples/data/scripts/formfiller.js | |
parent | 17f5e0d6bb15965573df41de12c77f0b26f1397a (diff) |
fix following input[type=email], [type=search], etc.
Diffstat (limited to 'examples/data/scripts/formfiller.js')
-rw-r--r-- | examples/data/scripts/formfiller.js | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/examples/data/scripts/formfiller.js b/examples/data/scripts/formfiller.js index 4470661..1b10db4 100644 --- a/examples/data/scripts/formfiller.js +++ b/examples/data/scripts/formfiller.js @@ -1,14 +1,16 @@ uzbl.formfiller = { - inputTypeIsText: function(type) { - var types = [ 'text', 'password', 'search', 'email', 'url', - 'number', 'range', 'color', 'date', 'month', - 'week', 'time', 'datetime', 'datetime-local' ]; + // this is pointlessly duplicated in uzbl.follow + textInputTypes: [ + 'text', 'password', 'search', 'email', 'url', 'number', 'range', 'color', + 'date', 'month', 'week', 'time', 'datetime', 'datetime-local' + ] - for(var i = 0; i < types.length; ++i) - if(types[i] == type) return true; + , - return false; + // this is pointlessly duplicated in uzbl.follow + inputTypeIsText: function(type) { + return uzbl.formfiller.textInputTypes.indexOf(type) >= 0; } , |