From 4b5985eb49e057aa69b8ba4e91d0ad11e1cc87ff Mon Sep 17 00:00:00 2001 From: Matthias Melcher Date: Fri, 27 Oct 2023 18:31:14 +0200 Subject: FLUID: Fixes issues when pasting widget into Fl_Flex #809 * new virtual function layout_widget() to inform parents after all children were added --- fluid/Fl_Type.h | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'fluid/Fl_Type.h') diff --git a/fluid/Fl_Type.h b/fluid/Fl_Type.h index 28611fb90..7e2072228 100644 --- a/fluid/Fl_Type.h +++ b/fluid/Fl_Type.h @@ -195,6 +195,13 @@ public: virtual void move_child(Fl_Type*, Fl_Type* beforethis) { } virtual void remove_child(Fl_Type*) { } + /** Give widgets a change to arrange their children after all children were add. + If adding individual children, this is called immediately, but if children + are read via a project file, we wait until all children are read and then + lay out the group. + */ + virtual void layout_widget() { } + static Fl_Type *current; // most recently picked object static Fl_Type *current_dnd; -- cgit v1.2.3