Bug 393791. Don't show a popup menu if we haven't generated its children yet. r=enn,sr=neil,a=beltzner

This commit is contained in:
2008-04-21 15:02:17 -07:00
parent 70ab2ee8be
commit d8ac3b04a6

View File

@@ -312,7 +312,8 @@ nsMenuPopupFrame::SetPreferredBounds(nsBoxLayoutState& aState,
void
nsMenuPopupFrame::AdjustView()
{
if (mPopupState == ePopupOpen || mPopupState == ePopupOpenAndVisible) {
if ((mPopupState == ePopupOpen || mPopupState == ePopupOpenAndVisible) &&
mGeneratedChildren) {
// if the popup has just opened, make sure the scrolled window is at 0,0
if (mIsOpenChanged) {
nsIBox* child = GetChildBox();