Bug 1451098 Part 2: Update nsView::DoResetWidgetBounds to check for empty rects returned from CalcWidgetBounds().
MozReview-Commit-ID: F9Mkf9Yjf07
--- a/view/nsView.cpp
+++ b/view/nsView.cpp
@@ -328,16 +328,17 @@ void nsView::DoResetWidgetBounds(bool aM
bool invisiblePopup = type == eWindowType_popup &&
((curBounds.IsEmpty() && mDimBounds.IsEmpty()) ||
mVis == nsViewVisibility_kHide);
if (invisiblePopup) {
// We're going to hit the early exit below, avoid calling CalcWidgetBounds.
} else {
newBounds = CalcWidgetBounds(type);
+ invisiblePopup = newBounds.IsEmpty();
}
bool curVisibility = widget->IsVisible();
bool newVisibility = IsEffectivelyVisible();
if (curVisibility && !newVisibility) {
widget->Show(false);
}