summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--CHANGES2
-rw-r--r--src/Fl_Repeat_Button.cxx2
2 files changed, 4 insertions, 0 deletions
diff --git a/CHANGES b/CHANGES
index 42ae10d68..01e7a2643 100644
--- a/CHANGES
+++ b/CHANGES
@@ -1,5 +1,7 @@
CHANGES IN FLTK 1.1.8
+ - Repeat button now cancels timeout if it should get
+ deactivated during a callback (STR #1330)
- Added support for assigning Fl_Menu_Items to array
variables in Fluid (STR #1280)
- Added --with-archflags configure option to allow
diff --git a/src/Fl_Repeat_Button.cxx b/src/Fl_Repeat_Button.cxx
index 638cc4c81..2252a3a24 100644
--- a/src/Fl_Repeat_Button.cxx
+++ b/src/Fl_Repeat_Button.cxx
@@ -49,6 +49,8 @@ int Fl_Repeat_Button::handle(int event) {
if (Fl::visible_focus()) Fl::focus(this);
newval = Fl::event_inside(this);
J1:
+ if (!active())
+ newval = 0;
if (value(newval)) {
if (newval) {
Fl::add_timeout(INITIALREPEAT,repeat_callback,this);