зеркало из https://github.com/mozilla/pjs.git
fix completely broken browser_bug481560.js
--HG-- extra : rebase_source : 0c0b93b67504c9230c4fb3cced6de6a35e43a1c5
This commit is contained in:
Родитель
e129060313
Коммит
5b300df6c8
|
@ -1,15 +1,6 @@
|
|||
function test() {
|
||||
waitForExplicitFinish();
|
||||
|
||||
// focus the url field so that it will can ensure the focus is there when
|
||||
// the window is refocused after the dialog closes
|
||||
gURLBar.focus();
|
||||
|
||||
window.addEventListener("focus", function () {
|
||||
window.removeEventListener("focus", arguments.callee, false);
|
||||
finish();
|
||||
}, false);
|
||||
|
||||
var win = openDialog(getBrowserURL(), "_blank", "chrome,all,dialog=no");
|
||||
|
||||
win.addEventListener("load", function () {
|
||||
|
@ -18,13 +9,15 @@ function test() {
|
|||
win.content.addEventListener("focus", function () {
|
||||
win.content.removeEventListener("focus", arguments.callee, false);
|
||||
|
||||
win.gBrowser.selectedTab.addEventListener("TabClose", function () {
|
||||
ok(false, "shouldn't have gotten the TabClose event for the last tab");
|
||||
}, false);
|
||||
|
||||
EventUtils.synthesizeKey("w", { accelKey: true }, win);
|
||||
|
||||
ok(win.closed, "accel+w closed the window immediately");
|
||||
}, false);
|
||||
|
||||
win.gBrowser.selectedTab.addEventListener("TabClose", function () {
|
||||
ok(false, "shouldn't have gotten the TabClose event for the last tab");
|
||||
finish();
|
||||
}, false);
|
||||
|
||||
}, false);
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче