mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 468053 - treat gBrowser.addTab(null) and gBrowser.addTab("about:blank") equally. r=mano
This commit is contained in:
parent
9437300eb2
commit
d9f27bea07
@ -1266,7 +1266,7 @@
|
||||
"http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul",
|
||||
"tab");
|
||||
|
||||
var blank = (aURI == "about:blank");
|
||||
var blank = !aURI || (aURI == "about:blank");
|
||||
|
||||
if (blank)
|
||||
t.setAttribute("label", this.mStringBundle.getString("tabs.untitled"));
|
||||
|
@ -45,6 +45,7 @@ function test() {
|
||||
key = "Unique name: " + Math.random();
|
||||
value = "Unique value: " + Date.now();
|
||||
let tab = tabbrowser.addTab();
|
||||
tab.linkedBrowser.stop();
|
||||
|
||||
// test adding
|
||||
ok(test(function() ss.setTabValue(tab, key, value)), "store a tab value");
|
||||
|
@ -63,7 +63,7 @@ function test() {
|
||||
newWin.gBrowser.removeEventListener("load", arguments.callee, true);
|
||||
|
||||
executeSoon(function() {
|
||||
newWin.gBrowser.addTab();
|
||||
newWin.gBrowser.addTab().linkedBrowser.stop();
|
||||
executeSoon(function() {
|
||||
// mark the window with some unique data to be restored later on
|
||||
ss.setWindowValue(newWin, uniqueKey, uniqueValue);
|
||||
|
@ -47,6 +47,7 @@ function test() {
|
||||
|
||||
// set a unique value on a new, blank tab
|
||||
var tab = gBrowser.addTab();
|
||||
tab.linkedBrowser.stop();
|
||||
ss.setTabValue(tab, uniqueName, uniqueValue);
|
||||
let valueWasCleaned = false;
|
||||
|
||||
|
@ -40,6 +40,7 @@ function test() {
|
||||
let ss = Cc["@mozilla.org/browser/sessionstore;1"].getService(Ci.nsISessionStore);
|
||||
|
||||
let tab = gBrowser.addTab();
|
||||
tab.linkedBrowser.stop();
|
||||
let tabState = JSON.parse(ss.getTabState(tab));
|
||||
is(tabState.disallow || "", "", "Everything is allowed per default");
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user