mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 507926. Make sure CreateWindowEx doesn't fail when we're creating an invisible window. r=jmathies
This commit is contained in:
parent
0535295ab4
commit
02bbe8dd79
@ -2315,7 +2315,11 @@ DocumentViewerImpl::FindContainerView()
|
|||||||
parentDocShell->GetPresShell(getter_AddRefs(parentPresShell));
|
parentDocShell->GetPresShell(getter_AddRefs(parentPresShell));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (content && parentPresShell) {
|
if (!content) {
|
||||||
|
NS_WARNING("Subdocument container has no content");
|
||||||
|
} else if (!parentPresShell) {
|
||||||
|
NS_WARNING("Subdocument container has no presshell");
|
||||||
|
} else {
|
||||||
nsIFrame* f = parentPresShell->GetRealPrimaryFrameFor(content);
|
nsIFrame* f = parentPresShell->GetRealPrimaryFrameFor(content);
|
||||||
if (f) {
|
if (f) {
|
||||||
nsIFrame* subdocFrame = f->GetContentInsertionFrame();
|
nsIFrame* subdocFrame = f->GetContentInsertionFrame();
|
||||||
@ -2329,7 +2333,11 @@ DocumentViewerImpl::FindContainerView()
|
|||||||
nsIView* innerView = subdocFrameView->GetFirstChild();
|
nsIView* innerView = subdocFrameView->GetFirstChild();
|
||||||
NS_ASSERTION(innerView, "Subdoc frames must have an inner view too");
|
NS_ASSERTION(innerView, "Subdoc frames must have an inner view too");
|
||||||
containerView = innerView;
|
containerView = innerView;
|
||||||
|
} else {
|
||||||
|
NS_WARNING("Subdocument container has non-subdocument frame");
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
NS_WARNING("Subdocument container has no frame");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -642,6 +642,9 @@ nsWindow::StandardWindowCreate(nsIWidget *aParent,
|
|||||||
extendedStyle = WS_EX_TOOLWINDOW;
|
extendedStyle = WS_EX_TOOLWINDOW;
|
||||||
else
|
else
|
||||||
parent = NULL;
|
parent = NULL;
|
||||||
|
} else if (mWindowType == eWindowType_invisible) {
|
||||||
|
// Make sure CreateWindowEx succeeds at creating a toplevel window
|
||||||
|
style &= ~WS_CHILDWINDOW;
|
||||||
} else if (nsnull != aInitData) {
|
} else if (nsnull != aInitData) {
|
||||||
// See if the caller wants to explictly set clip children and clip siblings
|
// See if the caller wants to explictly set clip children and clip siblings
|
||||||
if (aInitData->clipChildren) {
|
if (aInitData->clipChildren) {
|
||||||
|
Loading…
Reference in New Issue
Block a user