Bug 812528 - Port speculativeConnect changes to search.xml from bug 804655 and bug 722979. r=Neil
This commit is contained in:
Родитель
f4cbd60338
Коммит
a85367303f
|
@ -487,13 +487,16 @@
|
|||
var engine = this.currentEngine;
|
||||
var connector = Components.classes["@mozilla.org/network/io-service;1"]
|
||||
.getService(Components.interfaces.nsISpeculativeConnect);
|
||||
var callbacks = window.QueryInterface(Components.interfaces.nsIInterfaceRequestor)
|
||||
.getInterface(Components.interfaces.nsIWebNavigation)
|
||||
.QueryInterface(Components.interfaces.nsILoadContext);
|
||||
var searchURI = engine.getSubmission("dummy").uri;
|
||||
connector.speculativeConnect(searchURI, null);
|
||||
connector.speculativeConnect(searchURI, callbacks);
|
||||
|
||||
if (engine.supportsResponseType(SUGGEST_TYPE)) {
|
||||
var suggestURI = engine.getSubmission("dummy", SUGGEST_TYPE).uri;
|
||||
if (suggestURI.prePath != searchURI.prePath)
|
||||
connector.speculativeConnect(suggestURI, null);
|
||||
connector.speculativeConnect(suggestURI, callbacks);
|
||||
}
|
||||
]]></handler>
|
||||
</handlers>
|
||||
|
|
Загрузка…
Ссылка в новой задаче