зеркало из https://github.com/mozilla/pjs.git
Bug 281709 - Buffer view visibility changes like resizes. r/sr=roc
This commit is contained in:
Родитель
83984a26e1
Коммит
68197ec44d
|
@ -427,6 +427,16 @@ void nsView::ResetWidgetBounds(PRBool aRecurse, PRBool aMoveOnly,
|
|||
mWindow->Resize(newBounds.width, newBounds.height, aInvalidateChangedSize);
|
||||
} // else do nothing!
|
||||
}
|
||||
PRBool vis = PR_FALSE;
|
||||
mWindow->IsVisible(vis);
|
||||
if (vis != (mVis == nsViewVisibility_kShow)) {
|
||||
#ifndef HIDE_ALL_WIDGETS
|
||||
if (mVis == nsViewVisibility_kShow)
|
||||
mWindow->Show(PR_TRUE);
|
||||
else
|
||||
#endif
|
||||
mWindow->Show(PR_FALSE);
|
||||
}
|
||||
} else if (aRecurse) {
|
||||
// reposition any widgets under this view
|
||||
for (nsView* v = GetFirstChild(); v; v = v->GetNextSibling()) {
|
||||
|
@ -461,15 +471,7 @@ NS_IMETHODIMP nsView::SetVisibility(nsViewVisibility aVisibility)
|
|||
DropMouseGrabbing();
|
||||
}
|
||||
|
||||
if (nsnull != mWindow)
|
||||
{
|
||||
#ifndef HIDE_ALL_WIDGETS
|
||||
if (mVis == nsViewVisibility_kShow)
|
||||
mWindow->Show(PR_TRUE);
|
||||
else
|
||||
#endif
|
||||
mWindow->Show(PR_FALSE);
|
||||
}
|
||||
ResetWidgetBounds(PR_FALSE, PR_FALSE, PR_FALSE);
|
||||
|
||||
return NS_OK;
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче