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:
roc+%cs.cmu.edu 2008-04-21 22:02:17 +00:00
Родитель 2cc30aab50
Коммит c143e0c7d4
1 изменённых файлов: 2 добавлений и 1 удалений

Просмотреть файл

@ -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();