diff options
| author | Michael R Sweet <michael.r.sweet@gmail.com> | 2003-01-14 21:30:55 +0000 |
|---|---|---|
| committer | Michael R Sweet <michael.r.sweet@gmail.com> | 2003-01-14 21:30:55 +0000 |
| commit | 9f67d66c3a7ad5fde387ecf1eb7c15d772c8e003 (patch) | |
| tree | 5ccb4ae59517fa2d38ef85942a52153b215020e8 /src | |
| parent | 0df204ff51adce4030a2bb134608ace92b4eb776 (diff) | |
Fix size_range() bug under OSX.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@2905 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src')
| -rw-r--r-- | src/Fl_mac.cxx | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/src/Fl_mac.cxx b/src/Fl_mac.cxx index d521ee272..72e95b45b 100644 --- a/src/Fl_mac.cxx +++ b/src/Fl_mac.cxx @@ -1,5 +1,5 @@ // -// "$Id: Fl_mac.cxx,v 1.1.2.36 2002/10/30 01:01:52 matthiaswm Exp $" +// "$Id: Fl_mac.cxx,v 1.1.2.37 2003/01/14 21:30:15 easysw Exp $" // // MacOS specific code for the Fast Light Tool Kit (FLTK). // @@ -1626,6 +1626,14 @@ void Fl_Window::resize(int X,int Y,int W,int H) { Rect all; all.top=-32000; all.bottom=32000; all.left=-32000; all.right=32000; InvalWindowRect( i->xid, &all ); } + } else if (resize_from_system == this && size_range_set && !parent() && shown()) { + if (size_range_set) { + if (W < minw) W = minw; + else if (W > maxw && maxw) W = maxw; + if (H < minh) H = minh; + else if (H > maxh && maxh) H = maxh; + } + SizeWindow(i->xid, W>0 ? W : 1, H>0 ? H : 1, 1); } resize_from_system = 0; if (is_a_resize) { @@ -1750,6 +1758,6 @@ void Fl::paste(Fl_Widget &receiver, int clipboard) { // -// End of "$Id: Fl_mac.cxx,v 1.1.2.36 2002/10/30 01:01:52 matthiaswm Exp $". +// End of "$Id: Fl_mac.cxx,v 1.1.2.37 2003/01/14 21:30:15 easysw Exp $". // |
