- Fixed unexpected shortcut behavior for Win32 (STR #2199)
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@6803 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
This commit is contained in:
parent
378494cefe
commit
a7723c902a
1
CHANGES
1
CHANGES
@ -1,5 +1,6 @@
|
||||
CHANGES IN FLTK 1.1.10
|
||||
|
||||
- Fixed unexpected shortcut behavior for Win32 (STR #2199)
|
||||
- Added cast to Fl_Color in all Fluid code (STR #2206)
|
||||
- Fixed wrong identifier for special keys combined with
|
||||
modifier (STR #2196)
|
||||
|
||||
@ -222,6 +222,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))
|
||||
|
||||
Loading…
Reference in New Issue
Block a user