winemac: Send WM_CANCELMODE when keyboard layout changes from Cocoa side.

The standard keyboard shortcut for switching the keyboard layout is Command-
Space, but the Mac driver never sees the Space key press.  So, Wine only sees
a press and release of Alt, which puts focus on the menu bar.  This prevents
that focus change.
This commit is contained in:
Ken Thomases 2013-10-23 20:13:10 -05:00 committed by Alexandre Julliard
parent 2e9aa0c599
commit 35f0cf26b0

View file

@ -905,6 +905,8 @@ void macdrv_keyboard_changed(const macdrv_event *event)
thread_data->dead_key_state = 0;
macdrv_compute_keyboard_layout(thread_data);
SendMessageW(GetActiveWindow(), WM_CANCELMODE, 0, 0);
}