* updates fLastBounds in AttachedToWindow
* don't do the checks for invalid rect and Window(), because Invalidate() does this for you git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@17507 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -157,6 +157,8 @@ BMenuBar::AttachedToWindow()
|
|||||||
Window()->SetKeyMenuBar(this);
|
Window()->SetKeyMenuBar(this);
|
||||||
|
|
||||||
BMenu::AttachedToWindow();
|
BMenu::AttachedToWindow();
|
||||||
|
|
||||||
|
*fLastBounds = Bounds();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -218,8 +220,7 @@ BMenuBar::FrameResized(float newWidth, float newHeight)
|
|||||||
BRect rect(fLastBounds->right - 2, fLastBounds->top, bounds.right, bounds.bottom);
|
BRect rect(fLastBounds->right - 2, fLastBounds->top, bounds.right, bounds.bottom);
|
||||||
fLastBounds->Set(0, 0, newWidth, newHeight);
|
fLastBounds->Set(0, 0, newWidth, newHeight);
|
||||||
|
|
||||||
if (rect.IsValid() && Window() != NULL)
|
Invalidate(rect);
|
||||||
Invalidate(rect);
|
|
||||||
|
|
||||||
BMenu::FrameResized(newWidth, newHeight);
|
BMenu::FrameResized(newWidth, newHeight);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user