diff --git a/browser/components/search/Makefile.in b/browser/components/search/Makefile.in index d35ecfa96fd..8967c6ef3a3 100644 --- a/browser/components/search/Makefile.in +++ b/browser/components/search/Makefile.in @@ -48,6 +48,7 @@ XPIDL_MODULE = browsersearch XPIDLSRCS = nsIBrowserSearchService.idl -EXTRA_PP_COMPONENTS = nsSearchService.js +EXTRA_PP_COMPONENTS = nsSearchService.js \ + nsSearchSuggestions.js include $(topsrcdir)/config/rules.mk diff --git a/browser/components/search/content/search.xml b/browser/components/search/content/search.xml index 5e83c3fcf54..bfdd3b4173e 100644 --- a/browser/components/search/content/search.xml +++ b/browser/components/search/content/search.xml @@ -108,6 +108,9 @@ Components.classes["@mozilla.org/observer-service;1"] .getService(Components.interfaces.nsIObserverService); os.addObserver(this, "browser-search-engine-modified", false); + + // make sure we're using the right autocomplete + this._updateAutocompleteSearch(); ]]> @@ -355,11 +358,31 @@ if (newIndex >= 0 && newIndex < this._engines.length) this.currentEngine = this._engines[newIndex]; + this._updateAutocompleteSearch() + aEvent.preventDefault(); aEvent.stopPropagation(); ]]> + + + + 0), @@ -1509,6 +1512,13 @@ Engine.prototype = { closeSafeOutputStream(fos); }, + _createSuggestionURI: function SRCH_ENG_createSuggestionURI (aURLString) { + var suggestionURI = makeURI(aURLString, this._queryCharset); + if (suggestionURI && + (suggestionURI.schemeIs("http") || suggestionURI.schemeIs("https"))) + this._suggestionURI = suggestionURI; + }, + /** * Remove the engine's file from disk. The search service calls this once it * removes the engine from its internal store. This function will throw if @@ -1557,6 +1567,10 @@ Engine.prototype = { } }, + get suggestionURI() { + return this._suggestionURI; + }, + get iconURI() { return this._iconURI; }, diff --git a/browser/locales/en-US/searchplugins/google.xml b/browser/locales/en-US/searchplugins/google.xml index 712126f4253..597be3946a9 100755 --- a/browser/locales/en-US/searchplugins/google.xml +++ b/browser/locales/en-US/searchplugins/google.xml @@ -3,6 +3,7 @@ Google Search UTF-8 data:image/x-icon;base64,R0lGODlhEAAQAPfLAAATVikwdA8SnxUfg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M0eZTlCXMgQJtRSE4gmgUkwh1EiZTNUiamy6NUUExcuoJgDCdDjQg9KgVL2SNFT1hwEvKglLBWuixZ+jSrlSBdRlL04bBBkTBdpZTpIqWsFaBcTEr0QaEhl6dWlswKW6poDRUPlmAUQKWMkTJLc76QMQNGUZMWgIgkCFJnlq5WXigwkFClVZQQyuRgELAlk7JBymCZGYAF0ZEPrQixgUDAihxVdPpoAZAFUZIRfThxgvPCwAILDipk+OFG2ZIVoxApERtPfvwlvZ+kQFzPvv0MJQEBADs= +http://www.google.com/complete/search?csv=t&qu= diff --git a/browser/locales/en-US/searchplugins/yahoo.xml b/browser/locales/en-US/searchplugins/yahoo.xml index ee6701410cf..9c51852142b 100755 --- a/browser/locales/en-US/searchplugins/yahoo.xml +++ b/browser/locales/en-US/searchplugins/yahoo.xml @@ -2,6 +2,7 @@ Yahoo Yahoo Search UTF-8 +http://ff.search.yahoo.com/gossip?output=fxjson&command= data:image/x-icon;base64,R0lGODlhEAAQAJECAP8AAAAAAP///wAAACH5BAEAAAIALAAAAAAQABAAAAIplI+py+0NogQuyBDEnEd2kHkfFWUamEzmpZSfmaIHPHrRguUm/fT+UwAAOw==