diff options
| author | Stephen Blott | 2015-05-05 16:43:48 +0100 |
|---|---|---|
| committer | Stephen Blott | 2015-05-05 16:43:48 +0100 |
| commit | 28807bd25b27e5404228a638f2ab5e6c00f606cc (patch) | |
| tree | ce0d1f8aef6911cc250a7e1b57d4b553333eeb90 /background_scripts | |
| parent | 43bdd2787f2bffc4fc9c3397937a0ce9a183beda (diff) | |
| download | vimium-28807bd25b27e5404228a638f2ab5e6c00f606cc.tar.bz2 | |
Search completion; misc.
Diffstat (limited to 'background_scripts')
| -rw-r--r-- | background_scripts/completion.coffee | 2 | ||||
| -rw-r--r-- | background_scripts/completion_engines.coffee (renamed from background_scripts/search_engines.coffee) | 8 |
2 files changed, 5 insertions, 5 deletions
diff --git a/background_scripts/completion.coffee b/background_scripts/completion.coffee index 39f8a140..729e86ab 100644 --- a/background_scripts/completion.coffee +++ b/background_scripts/completion.coffee @@ -385,7 +385,7 @@ class SearchEngineCompleter # immediately. return onComplete [] - SearchEngines.complete searchUrl, queryTerms, (searchSuggestions = []) => + CompletionEngines.complete searchUrl, queryTerms, (searchSuggestions = []) => for suggestion in searchSuggestions insertText = if custom then "#{keyword} #{suggestion}" else suggestion suggestions.push @mkSuggestion insertText, queryTerms, type, mkUrl(suggestion), suggestion, @computeRelevancy, score diff --git a/background_scripts/search_engines.coffee b/background_scripts/completion_engines.coffee index 63c61a47..0177806a 100644 --- a/background_scripts/search_engines.coffee +++ b/background_scripts/completion_engines.coffee @@ -13,8 +13,8 @@ # 3. "parse" - This takes a successful XMLHttpRequest object (the request has completed successfully), and # returns a list of suggestions (a list of strings). # -# The main completion entry point is SearchEngines.complete(). This implements all lookup and caching -# logic. It is possible to add new completion engines without changing the SearchEngines infrastructure +# The main completion entry point is CompletionEngines.complete(). This implements all lookup and caching +# logic. It is possible to add new completion engines without changing the CompletionEngines infrastructure # itself. # A base class for common regexp-based matching engines. @@ -113,7 +113,7 @@ completionEngines = [ DummySearchEngine ] -SearchEngines = +CompletionEngines = debug: true get: (searchUrl, url, callback) -> @@ -216,4 +216,4 @@ SearchEngines = @mostRecentHandler = null root = exports ? window -root.SearchEngines = SearchEngines +root.CompletionEngines = CompletionEngines |
