diff options
| -rw-r--r-- | CHANGES | 1 | ||||
| -rw-r--r-- | src/fl_shortcut.cxx | 4 |
2 files changed, 5 insertions, 0 deletions
@@ -1,5 +1,6 @@ CHANGES IN FLTK 1.3.0 + - Fixed unexpected shortcut behavior for Win32 (STR #2199) - Fixed documentation for Fl_Progress (STR #2209) - Fluid printing used wrong colors under Windows (STR #2195) - Updated documentation for Fl_Input_ diff --git a/src/fl_shortcut.cxx b/src/fl_shortcut.cxx index 50acfdcf8..cd6f1cf9e 100644 --- a/src/fl_shortcut.cxx +++ b/src/fl_shortcut.cxx @@ -305,6 +305,10 @@ char Fl_Widget::label_shortcut(const char *t) { } int Fl_Widget::test_shortcut(const char *t) { + #ifdef WIN32 + // on MSWindows, users expect shortcuts to work only when the Alt modifier is pressed + if (Fl::event_state(FL_ALT)==0) return 0; + #endif char c = Fl::event_text()[0]; if (!c || !t) return 0; if (c == label_shortcut(t)) |
