зеркало из https://github.com/mozilla/pjs.git
Revert incorrect patch
This commit is contained in:
Родитель
a506a17d09
Коммит
71d0836f0c
|
@ -41,7 +41,6 @@
|
||||||
#include "nsISupports.idl"
|
#include "nsISupports.idl"
|
||||||
|
|
||||||
interface nsIURI;
|
interface nsIURI;
|
||||||
interface nsIFile;
|
|
||||||
interface nsIInputStream;
|
interface nsIInputStream;
|
||||||
|
|
||||||
[scriptable, uuid(58e4f602-a7c8-4cd1-9dca-716705e826ef)]
|
[scriptable, uuid(58e4f602-a7c8-4cd1-9dca-716705e826ef)]
|
||||||
|
@ -163,17 +162,9 @@ interface nsISearchEngine : nsISupports
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
[scriptable, uuid(c2e8ae4f-9fea-4a24-81e3-c94cdc055c1b)]
|
[scriptable, uuid(8307b8f2-08ea-45b8-96bf-b1dc7688fe3b)]
|
||||||
interface nsIBrowserSearchService : nsISupports
|
interface nsIBrowserSearchService : nsISupports
|
||||||
{
|
{
|
||||||
/**
|
|
||||||
* Loads all the engines in the supplied directory.
|
|
||||||
*
|
|
||||||
* @param enginesDir
|
|
||||||
* The directory containing the engine description files.
|
|
||||||
*/
|
|
||||||
void loadEngines(in nsIFile enginesDir);
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Adds a new search engine from the file at the supplied URI, optionally
|
* Adds a new search engine from the file at the supplied URI, optionally
|
||||||
* asking the user for confirmation first. If a confirmation dialog is
|
* asking the user for confirmation first. If a confirmation dialog is
|
||||||
|
|
|
@ -2222,7 +2222,7 @@ SearchService.prototype = {
|
||||||
|
|
||||||
while (locations.hasMoreElements()) {
|
while (locations.hasMoreElements()) {
|
||||||
var location = locations.getNext().QueryInterface(Ci.nsIFile);
|
var location = locations.getNext().QueryInterface(Ci.nsIFile);
|
||||||
this.loadEngines(location);
|
this._loadEngines(location);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Now that all engines are loaded, build the sorted engine list
|
// Now that all engines are loaded, build the sorted engine list
|
||||||
|
@ -2298,8 +2298,8 @@ SearchService.prototype = {
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
loadEngines: function SRCH_SVC_loadEngines(aDir) {
|
_loadEngines: function SRCH_SVC_loadEngines(aDir) {
|
||||||
LOG("loadEngines: Searching in " + aDir.path + " for search engines.");
|
LOG("_loadEngines: Searching in " + aDir.path + " for search engines.");
|
||||||
|
|
||||||
// Check whether aDir is the user profile dir
|
// Check whether aDir is the user profile dir
|
||||||
var isInProfile = aDir.equals(getDir(NS_APP_USER_SEARCH_DIR));
|
var isInProfile = aDir.equals(getDir(NS_APP_USER_SEARCH_DIR));
|
||||||
|
@ -2338,7 +2338,7 @@ SearchService.prototype = {
|
||||||
addedEngine = new Engine(file, dataType, !isWritable);
|
addedEngine = new Engine(file, dataType, !isWritable);
|
||||||
addedEngine._initFromFile();
|
addedEngine._initFromFile();
|
||||||
} catch (ex) {
|
} catch (ex) {
|
||||||
LOG("loadEngines: Failed to load " + file.path + "!\n" + ex);
|
LOG("_loadEngines: Failed to load " + file.path + "!\n" + ex);
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2347,7 +2347,7 @@ SearchService.prototype = {
|
||||||
try {
|
try {
|
||||||
this._convertSherlockFile(addedEngine, fileURL.fileBaseName);
|
this._convertSherlockFile(addedEngine, fileURL.fileBaseName);
|
||||||
} catch (ex) {
|
} catch (ex) {
|
||||||
LOG("loadEngines: Failed to convert: " + fileURL.path + "\n" + ex);
|
LOG("_loadEngines: Failed to convert: " + fileURL.path + "\n" + ex);
|
||||||
// The engine couldn't be converted, mark it as read-only
|
// The engine couldn't be converted, mark it as read-only
|
||||||
addedEngine._readOnly = true;
|
addedEngine._readOnly = true;
|
||||||
}
|
}
|
||||||
|
|
Загрузка…
Ссылка в новой задаче