зеркало из https://github.com/mozilla/pjs.git
Bug 325286 r=ben@mozilla.org Don't unnecessarily load favicons, make them get
set properly.
This commit is contained in:
Родитель
6a3f583324
Коммит
60e52a1cde
|
@ -2252,19 +2252,6 @@ function SetPageProxyState(aState)
|
||||||
|
|
||||||
function PageProxySetIcon (aURL)
|
function PageProxySetIcon (aURL)
|
||||||
{
|
{
|
||||||
#ifdef MOZ_PLACES
|
|
||||||
/*
|
|
||||||
// Save this favicon in the favicon service
|
|
||||||
if (aURL) {
|
|
||||||
var faviconService = Components.classes["@mozilla.org/browser/favicon-service;1"].
|
|
||||||
getService(Components.interfaces.nsIFaviconService);
|
|
||||||
var uri = Components.classes["@mozilla.org/network/io-service;1"]
|
|
||||||
.getService(Components.interfaces.nsIIOService).newURI(aURL, null, null);
|
|
||||||
faviconService.setAndLoadFaviconForPage(gBrowser.currentURI, uri, false);
|
|
||||||
}
|
|
||||||
*/
|
|
||||||
#endif
|
|
||||||
|
|
||||||
if (!gProxyFavIcon)
|
if (!gProxyFavIcon)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
@ -3391,7 +3378,19 @@ nsBrowserStatusHandler.prototype =
|
||||||
gBrowser.mCurrentBrowser == aBrowser &&
|
gBrowser.mCurrentBrowser == aBrowser &&
|
||||||
gBrowser.userTypedValue === null)
|
gBrowser.userTypedValue === null)
|
||||||
{
|
{
|
||||||
|
// update the favicon in the URL bar
|
||||||
PageProxySetIcon(aBrowser.mIconURL);
|
PageProxySetIcon(aBrowser.mIconURL);
|
||||||
|
|
||||||
|
#ifdef MOZ_PLACES
|
||||||
|
// Save this favicon in the favicon service
|
||||||
|
if (aBrowser.mIconURL) {
|
||||||
|
var faviconService = Components.classes["@mozilla.org/browser/favicon-service;1"].
|
||||||
|
getService(Components.interfaces.nsIFaviconService);
|
||||||
|
var uri = Components.classes["@mozilla.org/network/io-service;1"]
|
||||||
|
.getService(Components.interfaces.nsIIOService).newURI(aBrowser.mIconURL, null, null);
|
||||||
|
faviconService.setAndLoadFaviconForPage(gBrowser.currentURI, uri, false);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
Загрузка…
Ссылка в новой задаче