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

LibGUI: Add layout change propagation to Widget

This function is intended to propagate layout changes upwards in the
widget hierarchy. Widgets that can know what to do with this
information without causing a full layout invalidation (i.e. just
because one of their child widgets changed layout/size, doesn't
necessairily mean that they have to change their layout/size) can
override this and prevent a full relayout and redraw.
This commit is contained in:
FrHun 2022-06-28 17:56:47 +02:00 committed by Andreas Kling
parent f59c167bb0
commit 6f9777d35b
3 changed files with 16 additions and 8 deletions

View file

@ -52,7 +52,7 @@ void GroupBox::paint_event(PaintEvent& event)
void GroupBox::fonts_change_event(FontsChangeEvent& event)
{
Widget::fonts_change_event(event);
invalidate_layout();
layout_relevant_change_occured();
}
void GroupBox::set_title(StringView title)