From f7e4caec2575619b6578b866bb59630bb513049c Mon Sep 17 00:00:00 2001 From: Bill Spitzak Date: Tue, 20 Jun 2000 05:47:38 +0000 Subject: Whoops, I screwed up the timeout callbacks a bit. add_timeout will now do the callback at time t after the call to add_timeout, like before. add_interval_timeout is a new call that measures time from when the last timeout was called. This has slightly less overhead and allows accurate spacing of timeouts. Patch from Stuart Levy so the *last* widget in an Fl_Pack may be resizable. This should be compatable because resizable didn't do anything before so there was no reason to set it. Makefiles for no-cygwin from Paul Baxter (see README.win32 for info). git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@1222 ea41ed52-d2ee-0310-a9c1-e6b18d33e121 --- src/Fl_Pack.cxx | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'src/Fl_Pack.cxx') diff --git a/src/Fl_Pack.cxx b/src/Fl_Pack.cxx index d3818c10c..dac8e4501 100644 --- a/src/Fl_Pack.cxx +++ b/src/Fl_Pack.cxx @@ -1,5 +1,5 @@ // -// "$Id: Fl_Pack.cxx,v 1.6.2.2 2000/06/05 21:20:55 mike Exp $" +// "$Id: Fl_Pack.cxx,v 1.6.2.3 2000/06/20 05:47:37 bill Exp $" // // Packing widget for the Fast Light Tool Kit (FLTK). // @@ -63,6 +63,13 @@ void Fl_Pack::draw() { Y = current_position; H = o->h(); } + // Last child, if resizable, takes all remaining room + if(i == 0 && o == this->resizable()) { + if(horizontal()) + W = this->w() - Fl::box_dw(box()) - maximum_position; + else + H = this->h() - Fl::box_dh(box()) - maximum_position; + } if (spacing_ && current_position>maximum_position && (X != o->x() || Y != o->y() || d&FL_DAMAGE_ALL)) { fl_color(color()); @@ -105,5 +112,5 @@ void Fl_Pack::draw() { } // -// End of "$Id: Fl_Pack.cxx,v 1.6.2.2 2000/06/05 21:20:55 mike Exp $". +// End of "$Id: Fl_Pack.cxx,v 1.6.2.3 2000/06/20 05:47:37 bill Exp $". // -- cgit v1.2.3