mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Try to fix topcrash bug 752428 by null-checking the result of nsIPresShell::FrameManager(), which isn't supposed to need it. r=roc
--HG-- extra : transplant_source : %DF%9D%B8%F3%06%C5%85%00%245%FFK%AC%3F%3B%0C%90%3D%EF%A0
This commit is contained in:
parent
21c21c227a
commit
678686d952
@ -308,10 +308,13 @@ MaybeReflowForInflationScreenWidthChange(nsPresContext *aPresContext)
|
||||
nsCOMPtr<nsIPresShell> shell;
|
||||
nsCOMPtr<nsIContentViewer> cv = do_QueryInterface(array[i]);
|
||||
cv->GetPresShell(getter_AddRefs(shell));
|
||||
nsIFrame *rootFrame = shell->GetRootFrame();
|
||||
if (rootFrame) {
|
||||
shell->FrameNeedsReflow(rootFrame, nsIPresShell::eResize,
|
||||
NS_FRAME_IS_DIRTY);
|
||||
nsFrameManager *fm = shell->FrameManager();
|
||||
if (fm) {
|
||||
nsIFrame *rootFrame = fm->GetRootFrame();
|
||||
if (rootFrame) {
|
||||
shell->FrameNeedsReflow(rootFrame, nsIPresShell::eResize,
|
||||
NS_FRAME_IS_DIRTY);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user