diff options
| -rw-r--r-- | CHANGES | 2 | ||||
| -rw-r--r-- | src/Fl_Button.cxx | 8 | ||||
| -rw-r--r-- | src/Fl_Tabs.cxx | 13 |
3 files changed, 16 insertions, 7 deletions
@@ -1,5 +1,7 @@ CHANGES IN FLTK 1.1.0 + - Optimized the redrawing of tabs and radio/check + buttons when the keyboard focus changes. - More tooltip fixes. - DND text operations would loop under X11. diff --git a/src/Fl_Button.cxx b/src/Fl_Button.cxx index 2a94d21ed..614ea19be 100644 --- a/src/Fl_Button.cxx +++ b/src/Fl_Button.cxx @@ -1,5 +1,5 @@ // -// "$Id: Fl_Button.cxx,v 1.4.2.6.2.12 2002/03/25 21:08:41 easysw Exp $" +// "$Id: Fl_Button.cxx,v 1.4.2.6.2.13 2002/05/15 16:50:27 easysw Exp $" // // Button widget for the Fast Light Tool Kit (FLTK). // @@ -116,8 +116,8 @@ int Fl_Button::handle(int event) { Fl_Widget *p; for (p = parent(); p; p = p->parent()) if (p->box() != FL_NO_BOX) break; - if (p) p->redraw(); - else window()->redraw(); + if (p) p->damage(FL_DAMAGE_EXPOSE, x(), y(), w() + 1, h() + 1); + else window()->damage(FL_DAMAGE_EXPOSE, x(), y(), w() + 1, h() + 1); } else redraw(); return 1; @@ -149,5 +149,5 @@ Fl_Button::Fl_Button(int x,int y,int w,int h, const char *l) } // -// End of "$Id: Fl_Button.cxx,v 1.4.2.6.2.12 2002/03/25 21:08:41 easysw Exp $". +// End of "$Id: Fl_Button.cxx,v 1.4.2.6.2.13 2002/05/15 16:50:27 easysw Exp $". // diff --git a/src/Fl_Tabs.cxx b/src/Fl_Tabs.cxx index ab4093a34..16a3adff2 100644 --- a/src/Fl_Tabs.cxx +++ b/src/Fl_Tabs.cxx @@ -1,5 +1,5 @@ // -// "$Id: Fl_Tabs.cxx,v 1.6.2.10.2.9 2002/01/30 13:38:15 easysw Exp $" +// "$Id: Fl_Tabs.cxx,v 1.6.2.10.2.10 2002/05/15 16:50:27 easysw Exp $" // // Tab widget for the Fast Light Tool Kit (FLTK). // @@ -140,7 +140,14 @@ int Fl_Tabs::handle(int event) { case FL_FOCUS: case FL_UNFOCUS: if (Fl::visible_focus()) { - redraw(); + int H = tab_height(); + if (H >= 0) { + H += Fl::box_dy(box()); + damage(FL_DAMAGE_EXPOSE, x(), y(), w(), H); + } else { + H = Fl::box_dy(box()) - H; + damage(FL_DAMAGE_EXPOSE, x(), y() + h() - H, w(), H); + } return 1; } else return 0; case FL_KEYBOARD: @@ -293,5 +300,5 @@ Fl_Tabs::Fl_Tabs(int X,int Y,int W, int H, const char *l) : } // -// End of "$Id: Fl_Tabs.cxx,v 1.6.2.10.2.9 2002/01/30 13:38:15 easysw Exp $". +// End of "$Id: Fl_Tabs.cxx,v 1.6.2.10.2.10 2002/05/15 16:50:27 easysw Exp $". // |
