зеркало из https://github.com/mozilla/pjs.git
Bug 542928 - Add some more debugging logs to waitForFocus in order to track down the browser-chrome random orange; r=enndeakin
This commit is contained in:
Родитель
a63234bb3d
Коммит
e9dbf69d65
|
@ -298,6 +298,9 @@ SimpleTest.waitForFocus = function (callback, targetWindow, expectBlankPage) {
|
|||
}
|
||||
|
||||
function waitForEvent(event) {
|
||||
try {
|
||||
debugFocusLog("waitForEvent called <type:" + event.type + ", target" + event.target + ">");
|
||||
|
||||
// Check to make sure that this isn't a load event for a blank or
|
||||
// non-blank page that wasn't desired.
|
||||
if (event.type == "load" && (expectBlankPage != (event.target.location == "about:blank")))
|
||||
|
@ -307,6 +310,10 @@ SimpleTest.waitForFocus = function (callback, targetWindow, expectBlankPage) {
|
|||
var win = (event.type == "load") ? targetWindow : childTargetWindow;
|
||||
win.removeEventListener(event.type, waitForEvent, true);
|
||||
maybeRunTests();
|
||||
} catch (e) {
|
||||
SimpleTest.ok(false, "Exception caught in waitForEvent: " + e.message +
|
||||
", at: " + e.fileName + " (" + e.lineNumber + ")");
|
||||
}
|
||||
}
|
||||
|
||||
// If the current document is about:blank and we are not expecting a blank
|
||||
|
|
Загрузка…
Ссылка в новой задаче