Huw Davies : winemac: Retrieve the real keyboard layout where appropriate.

Alexandre Julliard julliard at winehq.org
Wed Nov 20 13:38:58 CST 2013


Module: wine
Branch: master
Commit: f6e2af6843c70e848390ea5706a57941af8a1a3a
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=f6e2af6843c70e848390ea5706a57941af8a1a3a

Author: Huw Davies <huw at codeweavers.com>
Date:   Wed Nov 20 15:30:37 2013 +0000

winemac: Retrieve the real keyboard layout where appropriate.

---

 dlls/winemac.drv/keyboard.c |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/dlls/winemac.drv/keyboard.c b/dlls/winemac.drv/keyboard.c
index cc0df4e..15a4c1b 100644
--- a/dlls/winemac.drv/keyboard.c
+++ b/dlls/winemac.drv/keyboard.c
@@ -395,6 +395,7 @@ static const struct {
     { VK_VOLUME_UP | 0x100,     "Volume Up" },
 };
 
+HKL CDECL macdrv_GetKeyboardLayout(DWORD);
 
 static BOOL char_matches_string(WCHAR wchar, UniChar *string, BOOL ignore_diacritics)
 {
@@ -1239,7 +1240,7 @@ HKL CDECL macdrv_ActivateKeyboardLayout(HKL hkl, UINT flags)
     }
 
     oldHkl = thread_data->active_keyboard_layout;
-    if (!oldHkl) oldHkl = get_locale_keyboard_layout();
+    if (!oldHkl) oldHkl = macdrv_GetKeyboardLayout(0);
 
     thread_data->active_keyboard_layout = hkl;
 
@@ -1396,7 +1397,7 @@ BOOL CDECL macdrv_GetKeyboardLayoutName(LPWSTR name)
     static const WCHAR formatW[] = {'%','0','8','x',0};
     DWORD layout;
 
-    layout = HandleToUlong(get_locale_keyboard_layout());
+    layout = HandleToUlong(macdrv_GetKeyboardLayout(0));
     if (HIWORD(layout) == LOWORD(layout)) layout = LOWORD(layout);
     sprintfW(name, formatW, layout);
     TRACE("returning %s\n", debugstr_w(name));




More information about the wine-cvs mailing list