X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Fpanel.cpp;h=836d991eb73e3b226d859b5c2c4a2da7acf5037a;hb=31e9ee682f8a9cd77c97ed9dc142283559ddaacc;hp=930a68f980f96a065552f11942c1b14f519ac2db;hpb=72db2a8d41cc0eb8404572d1a720d59fab0551cd;p=libs%2Fgltk.git diff --git a/source/panel.cpp b/source/panel.cpp index 930a68f..836d991 100644 --- a/source/panel.cpp +++ b/source/panel.cpp @@ -3,6 +3,7 @@ #include #include "button.h" #include "column.h" +#include "draghandle.h" #include "dropdown.h" #include "entry.h" #include "grid.h" @@ -13,6 +14,7 @@ #include "panel.h" #include "part.h" #include "row.h" +#include "stack.h" #include "toggle.h" #include "vslider.h" @@ -38,10 +40,10 @@ void Panel::set_layout(Layout *l) layout = l; } -void Panel::autosize() +void Panel::autosize_special(const Part &part, Geometry &ageom) { - if(layout) - layout->autosize(); + if(part.get_name()=="children" && layout) + layout->autosize(ageom); } void Panel::render_special(const Part &part, GL::Renderer &renderer) const @@ -87,6 +89,7 @@ Panel::Loader::Loader(Panel &p, map &m): add("button", &Loader::child