1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2025-12-23 07:17:59 +01:00

Add CompletionContextoptions.jswait. Dont preview 1 character substrings.

This commit is contained in:
Kris Maglione
2008-11-28 16:15:45 +00:00
parent 0698afef24
commit e0a3e761ed
5 changed files with 130 additions and 6 deletions

View File

@@ -944,10 +944,12 @@ function Options() //{{{
// TODO: Run this by default?
validateCompleter: function (values)
{
let self = this;
let completions = completion.runCompleter(function (context) self.completer(context), "");
let context = CompletionContext("");
let res = this.completer(context);
if (!res)
res = context.allItems.map(function (item) [item.text]);
return Array.concat(values).every(
function (value) completions.some(function (item) item[0] == value));
function (value) res.some(function (item) item[0] == value));
},
get store() storage.options,