mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-01-27 07:34:20 +00:00
Bug 464756: Opening new tab after closing another recycles previous favicon in new tab. r=gavin
This commit is contained in:
parent
bae977405b
commit
6ea3f23a8a
@ -44,6 +44,8 @@ pref("browser.startup.homepage", "about:firstrun");
|
|||||||
pref("browser.ui.cursor", false);
|
pref("browser.ui.cursor", false);
|
||||||
pref("browser.ui.panning.kinetic", true);
|
pref("browser.ui.panning.kinetic", true);
|
||||||
|
|
||||||
|
pref("javascript.options.showInConsole", false);
|
||||||
|
|
||||||
/* cache prefs */
|
/* cache prefs */
|
||||||
pref("browser.cache.disk.enable", false);
|
pref("browser.cache.disk.enable", false);
|
||||||
pref("browser.cache.disk.capacity", 0);
|
pref("browser.cache.disk.capacity", 0);
|
||||||
|
@ -40,7 +40,6 @@ Components.utils.import("resource://gre/modules/utils.js");
|
|||||||
|
|
||||||
const TOOLBARSTATE_LOADING = 1;
|
const TOOLBARSTATE_LOADING = 1;
|
||||||
const TOOLBARSTATE_LOADED = 2;
|
const TOOLBARSTATE_LOADED = 2;
|
||||||
const TOOLBARSTATE_INDETERMINATE = 3;
|
|
||||||
|
|
||||||
const UIMODE_NONE = 0;
|
const UIMODE_NONE = 0;
|
||||||
const UIMODE_URLVIEW = 1;
|
const UIMODE_URLVIEW = 1;
|
||||||
@ -115,6 +114,10 @@ var BrowserUI = {
|
|||||||
var browser = Browser.currentBrowser;
|
var browser = Browser.currentBrowser;
|
||||||
this._titleChanged(browser.contentDocument);
|
this._titleChanged(browser.contentDocument);
|
||||||
this._favicon.src = browser.mIconURL || kDefaultFavIconURL;
|
this._favicon.src = browser.mIconURL || kDefaultFavIconURL;
|
||||||
|
|
||||||
|
// for new tabs, _tabSelect & update(TOOLBARSTATE_LOADED) are called when
|
||||||
|
// about:blank is loaded. set _faviconLink here so it is not overriden in update
|
||||||
|
this._faviconLink = this._favicon.src;
|
||||||
this.updateIcon();
|
this.updateIcon();
|
||||||
},
|
},
|
||||||
|
|
||||||
@ -321,11 +324,6 @@ var BrowserUI = {
|
|||||||
var toolbar = document.getElementById("toolbar-main");
|
var toolbar = document.getElementById("toolbar-main");
|
||||||
|
|
||||||
switch (aState) {
|
switch (aState) {
|
||||||
case TOOLBARSTATE_INDETERMINATE:
|
|
||||||
this._faviconAdded = false;
|
|
||||||
aState = TOOLBARSTATE_LOADED;
|
|
||||||
this.setURI();
|
|
||||||
|
|
||||||
case TOOLBARSTATE_LOADED:
|
case TOOLBARSTATE_LOADED:
|
||||||
toolbar.setAttribute("mode", "view");
|
toolbar.setAttribute("mode", "view");
|
||||||
|
|
||||||
@ -334,6 +332,7 @@ var BrowserUI = {
|
|||||||
}
|
}
|
||||||
this._setIcon(this._faviconLink);
|
this._setIcon(this._faviconLink);
|
||||||
this.updateIcon();
|
this.updateIcon();
|
||||||
|
this._faviconLink = null;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case TOOLBARSTATE_LOADING:
|
case TOOLBARSTATE_LOADING:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user