From 4c25db3f8a3df0c2e708f4642e24d50fdb3bf634 Mon Sep 17 00:00:00 2001 From: "danm%netscape.com" Date: Fri, 4 Jan 2002 02:32:48 +0000 Subject: [PATCH] allow nsXULWindow::CreateNewWindow to fail; don't fall back on the appshell. bug 115969 r=jaggernaut,jst git-svn-id: svn://10.0.0.236/trunk@111341 18797224-902f-48f8-a5cc-f745e15eee43 --- mozilla/xpfe/bootstrap/nsWindowCreator.cpp | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/mozilla/xpfe/bootstrap/nsWindowCreator.cpp b/mozilla/xpfe/bootstrap/nsWindowCreator.cpp index c704c967d36..3cdc0c40211 100644 --- a/mozilla/xpfe/bootstrap/nsWindowCreator.cpp +++ b/mozilla/xpfe/bootstrap/nsWindowCreator.cpp @@ -106,10 +106,9 @@ nsWindowCreator::CreateChromeWindow(nsIWebBrowserChrome *aParent, NS_ASSERTION(xulParent, "window created using non-XUL parent. that's unexpected, but may work."); if (xulParent) xulParent->CreateNewWindow(aChromeFlags, getter_AddRefs(newWindow)); - } - - // no parent or incompetent parent. try again using basic methods: - if (!newWindow) { + // And if it fails, don't try again without a parent. It could fail + // intentionally (bug 115969). + } else { // try using basic methods: /* You really shouldn't be making dependent windows without a parent. But unparented modal (and therefore dependent) windows happen in our codebase, so we allow it after some bellyaching: */