From aa9c028aeb9d036e9be5b9b9bae103289e29ba91 Mon Sep 17 00:00:00 2001 From: Michael R Sweet Date: Wed, 15 Sep 1999 16:07:03 +0000 Subject: Added Fl_Roller fix from 2.0 tree. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@719 ea41ed52-d2ee-0310-a9c1-e6b18d33e121 --- src/Fl_Roller.cxx | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/Fl_Roller.cxx b/src/Fl_Roller.cxx index 4ee89b8de..81981a64f 100644 --- a/src/Fl_Roller.cxx +++ b/src/Fl_Roller.cxx @@ -1,5 +1,5 @@ // -// "$Id: Fl_Roller.cxx,v 1.6 1999/01/07 19:17:26 mike Exp $" +// "$Id: Fl_Roller.cxx,v 1.6.2.1 1999/09/15 16:07:03 mike Exp $" // // Roller widget for the Fast Light Tool Kit (FLTK). // @@ -55,6 +55,7 @@ void Fl_Roller::draw() { int Y = y()+Fl::box_dy(box()); int W = w()-Fl::box_dw(box())-1; int H = h()-Fl::box_dh(box())-1; + if (W<=0 || H <=0) return; int offset = step() ? int(value()/step()) : 0; const double ARC = 1.5; // 1/2 the number of radians visible const double delta = .2; // radians per knurl @@ -136,5 +137,5 @@ Fl_Roller::Fl_Roller(int X,int Y,int W,int H,const char* L) } // -// End of "$Id: Fl_Roller.cxx,v 1.6 1999/01/07 19:17:26 mike Exp $". +// End of "$Id: Fl_Roller.cxx,v 1.6.2.1 1999/09/15 16:07:03 mike Exp $". // -- cgit v1.2.3