more sensible API for Pane::set_child_minsize
This commit is contained in:
parent
518fd81e6c
commit
7c6cfd9fa0
@ -57,7 +57,7 @@ class LIBGTKMM2EXT_API Pane : public Gtk::Container
|
|||||||
Pane (bool horizontal);
|
Pane (bool horizontal);
|
||||||
void set_divider (std::vector<float>::size_type divider, float fract);
|
void set_divider (std::vector<float>::size_type divider, float fract);
|
||||||
float get_divider (std::vector<float>::size_type divider = 0);
|
float get_divider (std::vector<float>::size_type divider = 0);
|
||||||
void set_child_minsize (Children::size_type n, int32_t);
|
void set_child_minsize (Gtk::Widget const &, int32_t);
|
||||||
|
|
||||||
GType child_type_vfunc() const;
|
GType child_type_vfunc() const;
|
||||||
void set_drag_cursor (Gdk::Cursor);
|
void set_drag_cursor (Gdk::Cursor);
|
||||||
|
@ -45,18 +45,14 @@ Pane::Pane (bool h)
|
|||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
Pane::set_child_minsize (Children::size_type n, int32_t minsize)
|
Pane::set_child_minsize (Gtk::Widget const& w, int32_t minsize)
|
||||||
{
|
{
|
||||||
Children::iterator c = children.begin();
|
for (Children::iterator c = children.begin(); c != children.end(); ++c) {
|
||||||
|
if (c->w == &w) {
|
||||||
while (n--) {
|
c->minsize = minsize;
|
||||||
if (c == children.end()) {
|
break;
|
||||||
return;
|
|
||||||
}
|
}
|
||||||
++c;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
c->minsize = minsize;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
Loading…
Reference in New Issue
Block a user