зеркало из https://github.com/mozilla/gecko-dev.git
Bug 348141: Adding an autodetected search engine should choose it too. r=beng, r (on irc)=gavin
This commit is contained in:
Родитель
677552e876
Коммит
aa54933ea9
|
@ -434,11 +434,11 @@
|
|||
searchService.addEngine(aTarget.getAttribute("uri"), type,
|
||||
aTarget.getAttribute("src"), false);
|
||||
}
|
||||
else if (aTarget.engine) {
|
||||
else if (aTarget.engine)
|
||||
this.currentEngine = aTarget.engine;
|
||||
this.focus();
|
||||
this.select();
|
||||
}
|
||||
|
||||
this.focus();
|
||||
this.select();
|
||||
]]></body>
|
||||
</method>
|
||||
|
||||
|
|
|
@ -167,8 +167,10 @@ interface nsIBrowserSearchService : nsISupports
|
|||
{
|
||||
/**
|
||||
* Adds a new search engine from the file at the supplied URI, optionally
|
||||
* asking the user for confirmation first. The confirmation dialog also
|
||||
* offers the option to begin using the newly added engine right away.
|
||||
* asking the user for confirmation first. If a confirmation dialog is
|
||||
* shown, it will offer the option to begin using the newly added engine
|
||||
* right away; if no confirmation dialog is shown, the new engine will be
|
||||
* used right away automatically.
|
||||
*
|
||||
* @param engineURL
|
||||
* The URL to the search engine's description file.
|
||||
|
@ -195,7 +197,8 @@ interface nsIBrowserSearchService : nsISupports
|
|||
in boolean confirm);
|
||||
|
||||
/**
|
||||
* Adds a new search engine, without asking the user for confirmation.
|
||||
* Adds a new search engine, without asking the user for confirmation and
|
||||
* without starting to use it right away.
|
||||
*
|
||||
* @param name
|
||||
* The search engine's name. Must be unique. Must not be null.
|
||||
|
|
|
@ -983,7 +983,7 @@ Engine.prototype = {
|
|||
_confirm: false,
|
||||
// Whether to set this as the current engine as soon as it is loaded. This
|
||||
// is only used when the engine is first added to the list.
|
||||
_useNow: false,
|
||||
_useNow: true,
|
||||
// Whether the search engine file is in the app dir.
|
||||
__isInAppDir: null,
|
||||
// The number of days between update checks for new versions
|
||||
|
|
Загрузка…
Ссылка в новой задаче