diff options
| author | Matthias Melcher <github@matthiasm.com> | 2023-12-16 14:22:22 +0100 |
|---|---|---|
| committer | Matthias Melcher <github@matthiasm.com> | 2023-12-16 14:22:22 +0100 |
| commit | 046bf23a5d7290861df1e020babfa2e1535a0389 (patch) | |
| tree | 150f165aa8e333dca68667469e94c6c8261c420e /src/Fl_Counter.cxx | |
| parent | ca028872e7a33376576eb5b039e7eafedaad90e9 (diff) | |
Adds mouse wheel input to Fl_Counter
Diffstat (limited to 'src/Fl_Counter.cxx')
| -rw-r--r-- | src/Fl_Counter.cxx | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/Fl_Counter.cxx b/src/Fl_Counter.cxx index 49fd6b32a..852658a1d 100644 --- a/src/Fl_Counter.cxx +++ b/src/Fl_Counter.cxx @@ -197,6 +197,9 @@ int Fl_Counter::handle(int event) { redraw(); } return 1; + case FL_MOUSEWHEEL: + handle_drag(clamp(increment(value(),(Fl::event_dy() - Fl::event_dx()) / 2 ))); + return 1; case FL_KEYBOARD : switch (Fl::event_key()) { case FL_Left: |
