1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 10:18:11 +00:00

GWidget: Dispatch Show and Hide events when widget visibility changes

This commit is contained in:
Andreas Kling 2019-10-02 20:24:03 +02:00
parent 3f2c1a2e3d
commit 7e2b9c3c40

View file

@ -456,6 +456,14 @@ void GWidget::set_visible(bool visible)
parent->invalidate_layout();
if (m_visible)
update();
if (m_visible) {
GShowEvent e;
event(e);
} else {
GHideEvent e;
event(e);
}
}
bool GWidget::spans_entire_window_horizontally() const