From: Jacek Caban jacek@codeweavers.com
Signed-off-by: Jacek Caban jacek@codeweavers.com --- dlls/winemac.drv/Makefile.in | 1 + dlls/winemac.drv/dllmain.c | 65 +++++++++++++++++++++++++++ dlls/winemac.drv/macdrv.h | 2 + dlls/winemac.drv/macdrv_main.c | 82 +++++++++++++--------------------- dlls/winemac.drv/unixlib.h | 43 ++++++++++++++++++ 5 files changed, 142 insertions(+), 51 deletions(-) create mode 100644 dlls/winemac.drv/dllmain.c create mode 100644 dlls/winemac.drv/unixlib.h
diff --git a/dlls/winemac.drv/Makefile.in b/dlls/winemac.drv/Makefile.in index e345249aac7..06c654344d1 100644 --- a/dlls/winemac.drv/Makefile.in +++ b/dlls/winemac.drv/Makefile.in @@ -9,6 +9,7 @@ EXTRADLLFLAGS = -mcygwin C_SRCS = \ clipboard.c \ display.c \ + dllmain.c \ dragdrop.c \ event.c \ gdi.c \ diff --git a/dlls/winemac.drv/dllmain.c b/dlls/winemac.drv/dllmain.c new file mode 100644 index 00000000000..60ca50474d7 --- /dev/null +++ b/dlls/winemac.drv/dllmain.c @@ -0,0 +1,65 @@ +/* + * winemac.drv entry points + * + * Copyright 2022 Jacek Caban for CodeWeavers + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "config.h" +#include <stdarg.h> +#include "macdrv.h" + + +HMODULE macdrv_module = 0; + +static BOOL process_attach(void) +{ + struct init_params params; + + struct localized_string *str; + struct localized_string strings[] = { + { .id = STRING_MENU_WINE }, + { .id = STRING_MENU_ITEM_HIDE_APPNAME }, + { .id = STRING_MENU_ITEM_HIDE }, + { .id = STRING_MENU_ITEM_HIDE_OTHERS }, + { .id = STRING_MENU_ITEM_SHOW_ALL }, + { .id = STRING_MENU_ITEM_QUIT_APPNAME }, + { .id = STRING_MENU_ITEM_QUIT }, + + { .id = STRING_MENU_WINDOW }, + { .id = STRING_MENU_ITEM_MINIMIZE }, + { .id = STRING_MENU_ITEM_ZOOM }, + { .id = STRING_MENU_ITEM_ENTER_FULL_SCREEN }, + { .id = STRING_MENU_ITEM_BRING_ALL_TO_FRONT }, + + { .id = 0 } + }; + + for (str = strings; str->id; str++) + str->len = LoadStringW(macdrv_module, str->id, (WCHAR *)&str->str, 0); + params.strings = strings; + + return !MACDRV_CALL(init, ¶ms); +} + +BOOL WINAPI DllMain(HINSTANCE instance, DWORD reason, void *reserved) +{ + if (reason != DLL_PROCESS_ATTACH) return TRUE; + + DisableThreadLibraryCalls(instance); + macdrv_module = instance; + return process_attach(); +} diff --git a/dlls/winemac.drv/macdrv.h b/dlls/winemac.drv/macdrv.h index 9cd0509a39c..39aff4d6a9f 100644 --- a/dlls/winemac.drv/macdrv.h +++ b/dlls/winemac.drv/macdrv.h @@ -33,6 +33,7 @@ #include "ntgdi.h" #include "wine/debug.h" #include "wine/gdi_driver.h" +#include "unixlib.h"
extern BOOL skip_single_buffer_flushes DECLSPEC_HIDDEN; @@ -280,6 +281,7 @@ extern void macdrv_status_item_mouse_move(const macdrv_event *event) DECLSPEC_HI extern void check_retina_status(void) DECLSPEC_HIDDEN; extern void macdrv_init_display_devices(BOOL force) DECLSPEC_HIDDEN; extern void init_user_driver(void) DECLSPEC_HIDDEN; +extern NTSTATUS macdrv_init(void *arg) DECLSPEC_HIDDEN;
/************************************************************************** * Mac IME driver diff --git a/dlls/winemac.drv/macdrv_main.c b/dlls/winemac.drv/macdrv_main.c index a0dc9c494da..adcf6f73fc7 100644 --- a/dlls/winemac.drv/macdrv_main.c +++ b/dlls/winemac.drv/macdrv_main.c @@ -63,7 +63,6 @@ int cursor_clipping_locks_windows = TRUE; int use_precise_scrolling = TRUE; int gl_surface_mode = GL_SURFACE_IN_FRONT_OPAQUE; int retina_enabled = FALSE; -HMODULE macdrv_module = 0; int enable_app_nap = FALSE;
CFDictionaryRef localized_strings; @@ -396,25 +395,9 @@ static void setup_options(void) /*********************************************************************** * load_strings */ -static void load_strings(HINSTANCE instance) +static void load_strings(struct localized_string *str) { - static const unsigned int ids[] = { - STRING_MENU_WINE, - STRING_MENU_ITEM_HIDE_APPNAME, - STRING_MENU_ITEM_HIDE, - STRING_MENU_ITEM_HIDE_OTHERS, - STRING_MENU_ITEM_SHOW_ALL, - STRING_MENU_ITEM_QUIT_APPNAME, - STRING_MENU_ITEM_QUIT, - - STRING_MENU_WINDOW, - STRING_MENU_ITEM_MINIMIZE, - STRING_MENU_ITEM_ZOOM, - STRING_MENU_ITEM_ENTER_FULL_SCREEN, - STRING_MENU_ITEM_BRING_ALL_TO_FRONT, - }; CFMutableDictionaryRef dict; - int i;
dict = CFDictionaryCreateMutable(NULL, 0, &kCFTypeDictionaryKeyCallBacks, &kCFTypeDictionaryValueCallBacks); @@ -424,21 +407,20 @@ static void load_strings(HINSTANCE instance) return; }
- for (i = 0; i < ARRAY_SIZE(ids); i++) + while (str->id) { - LPCWSTR str; - int len = LoadStringW(instance, ids[i], (LPWSTR)&str, 0); - if (str && len) + if (str->str && str->len) { - CFNumberRef key = CFNumberCreate(NULL, kCFNumberIntType, &ids[i]); - CFStringRef value = CFStringCreateWithCharacters(NULL, (UniChar*)str, len); + CFNumberRef key = CFNumberCreate(NULL, kCFNumberIntType, &str->id); + CFStringRef value = CFStringCreateWithCharacters(NULL, (UniChar*)str->str, str->len); if (key && value) CFDictionarySetValue(dict, key, value); else - ERR("Failed to add string ID 0x%04x %s\n", ids[i], debugstr_wn(str, len)); + ERR("Failed to add string ID 0x%04x %s\n", str->id, debugstr_wn(str->str, str->len)); } else - ERR("Failed to load string ID 0x%04x\n", ids[i]); + ERR("Failed to load string ID 0x%04x\n", str->id); + str++; }
localized_strings = dict; @@ -446,32 +428,33 @@ static void load_strings(HINSTANCE instance)
/*********************************************************************** - * process_attach + * macdrv_init */ -static BOOL process_attach(void) +NTSTATUS macdrv_init(void *arg) { + struct init_params *params = arg; SessionAttributeBits attributes; OSStatus status;
status = SessionGetInfo(callerSecuritySession, NULL, &attributes); if (status != noErr || !(attributes & sessionHasGraphicAccess)) - return FALSE; + return STATUS_UNSUCCESSFUL;
init_win_context(); setup_options(); - load_strings(macdrv_module); + load_strings(params->strings);
macdrv_err_on = ERR_ON(macdrv); - if (macdrv_start_cocoa_app(GetTickCount64())) + if (macdrv_start_cocoa_app(NtGetTickCount())) { ERR("Failed to start Cocoa app main loop\n"); - return FALSE; + return STATUS_UNSUCCESSFUL; }
init_user_driver(); macdrv_init_display_devices(FALSE);
- return TRUE; + return STATUS_SUCCESS; }
@@ -559,24 +542,6 @@ struct macdrv_thread_data *macdrv_init_thread_data(void) }
-/*********************************************************************** - * DllMain - */ -BOOL WINAPI DllMain(HINSTANCE hinst, DWORD reason, LPVOID reserved) -{ - BOOL ret = TRUE; - - switch(reason) - { - case DLL_PROCESS_ATTACH: - DisableThreadLibraryCalls( hinst ); - macdrv_module = hinst; - ret = process_attach(); - break; - } - return ret; -} - /*********************************************************************** * SystemParametersInfo (MACDRV.@) */ @@ -640,3 +605,18 @@ BOOL macdrv_SystemParametersInfo( UINT action, UINT int_param, void *ptr_param, } return FALSE; } + + +const unixlib_entry_t __wine_unix_call_funcs[] = +{ + macdrv_init, +}; + +C_ASSERT( ARRAYSIZE(__wine_unix_call_funcs) == unix_funcs_count ); + + +/* FIXME: Use __wine_unix_call instead */ +NTSTATUS unix_call(enum macdrv_funcs code, void *params) +{ + return __wine_unix_call_funcs[code]( params ); +} diff --git a/dlls/winemac.drv/unixlib.h b/dlls/winemac.drv/unixlib.h new file mode 100644 index 00000000000..9f8cd4e0acb --- /dev/null +++ b/dlls/winemac.drv/unixlib.h @@ -0,0 +1,43 @@ +/* + * Copyright 2022 Jacek Caban for CodeWeavers + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "ntuser.h" +#include "wine/unixlib.h" + +enum macdrv_funcs +{ + unix_init, + unix_funcs_count +}; + +/* FIXME: Use __wine_unix_call when the rest of the stack is ready */ +extern NTSTATUS unix_call(enum macdrv_funcs code, void *params) DECLSPEC_HIDDEN; +#define MACDRV_CALL(func, params) unix_call( unix_ ## func, params ) + +/* macdrv_init params */ +struct localized_string +{ + UINT id; + UINT len; + const WCHAR *str; +}; + +struct init_params +{ + struct localized_string *strings; +};
From: Jacek Caban jacek@codeweavers.com
Signed-off-by: Jacek Caban jacek@codeweavers.com --- dlls/winemac.drv/systray.c | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-)
diff --git a/dlls/winemac.drv/systray.c b/dlls/winemac.drv/systray.c index dbddbddff9a..a5ea7e55d79 100644 --- a/dlls/winemac.drv/systray.c +++ b/dlls/winemac.drv/systray.c @@ -135,8 +135,8 @@ static BOOL modify_icon(struct tray_icon *icon, NOTIFYICONDATAW *nid)
if (nid->uFlags & NIF_ICON) { - if (icon->image) DestroyIcon(icon->image); - icon->image = CopyIcon(nid->hIcon); + if (icon->image) NtUserDestroyCursor(icon->image, 0); + icon->image = CopyImage(nid->hIcon, IMAGE_ICON, 0, 0, 0); if (icon->status_item) update_image = TRUE; } @@ -195,7 +195,7 @@ static BOOL add_icon(NOTIFYICONDATAW *nid) return FALSE; }
- if (!(icon = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(*icon)))) + if (!(icon = calloc(1, sizeof(*icon)))) { ERR("out of memory\n"); return FALSE; @@ -234,8 +234,8 @@ static BOOL delete_icon(struct tray_icon *icon) macdrv_destroy_status_item(icon->status_item); } list_remove(&icon->entry); - DestroyIcon(icon->image); - HeapFree(GetProcessHeap(), 0, icon); + NtUserDestroyCursor(icon->image, 0); + free(icon); return TRUE; }
@@ -290,7 +290,8 @@ static BOOL notify_owner(struct tray_icon *icon, UINT msg, int x, int y) }
TRACE("posting msg 0x%04x to hwnd %p id 0x%x\n", msg, icon->owner, icon->id); - if (!SendNotifyMessageW(icon->owner, icon->callback_message, wp, lp) && + if (!NtUserMessageCall(icon->owner, icon->callback_message, wp, lp, + 0, NtUserSendNotifyMessage, FALSE) && (GetLastError() == ERROR_INVALID_WINDOW_HANDLE)) { WARN("window %p was destroyed, removing icon 0x%x\n", icon->owner, icon->id); @@ -335,7 +336,7 @@ void macdrv_status_item_mouse_button(const macdrv_event *event) else if (event->status_item_mouse_button.count % 2 == 0) msg += WM_LBUTTONDBLCLK - WM_LBUTTONDOWN;
- if (!SendMessageW(icon->owner, WM_MACDRV_ACTIVATE_ON_FOLLOWING_FOCUS, 0, 0) && + if (!send_message(icon->owner, WM_MACDRV_ACTIVATE_ON_FOLLOWING_FOCUS, 0, 0) && GetLastError() == ERROR_INVALID_WINDOW_HANDLE) { WARN("window %p was destroyed, removing icon 0x%x\n", icon->owner, icon->id);
From: Jacek Caban jacek@codeweavers.com
Signed-off-by: Jacek Caban jacek@codeweavers.com --- dlls/winemac.drv/dllmain.c | 7 +++++++ dlls/winemac.drv/macdrv.h | 4 ++++ dlls/winemac.drv/macdrv_main.c | 1 + dlls/winemac.drv/systray.c | 8 +++++--- dlls/winemac.drv/unixlib.h | 8 ++++++++ 5 files changed, 25 insertions(+), 3 deletions(-)
diff --git a/dlls/winemac.drv/dllmain.c b/dlls/winemac.drv/dllmain.c index 60ca50474d7..23a1e6e2218 100644 --- a/dlls/winemac.drv/dllmain.c +++ b/dlls/winemac.drv/dllmain.c @@ -21,6 +21,7 @@ #include "config.h" #include <stdarg.h> #include "macdrv.h" +#include "shellapi.h"
HMODULE macdrv_module = 0; @@ -63,3 +64,9 @@ BOOL WINAPI DllMain(HINSTANCE instance, DWORD reason, void *reserved) macdrv_module = instance; return process_attach(); } + +int CDECL wine_notify_icon(DWORD msg, NOTIFYICONDATAW *data) +{ + struct notify_icon_params params = { .msg = msg, .data = data }; + return MACDRV_CALL(notify_icon, ¶ms); +} diff --git a/dlls/winemac.drv/macdrv.h b/dlls/winemac.drv/macdrv.h index 39aff4d6a9f..a4736b2d315 100644 --- a/dlls/winemac.drv/macdrv.h +++ b/dlls/winemac.drv/macdrv.h @@ -294,6 +294,10 @@ extern void macdrv_im_set_text(const macdrv_event *event) DECLSPEC_HIDDEN; extern void macdrv_sent_text_input(const macdrv_event *event) DECLSPEC_HIDDEN; extern BOOL query_ime_char_rect(macdrv_query* query) DECLSPEC_HIDDEN;
+/* unixlib interface */ + +extern NTSTATUS macdrv_notify_icon(void *arg) DECLSPEC_HIDDEN; + /* user helpers */
static inline LRESULT send_message(HWND hwnd, UINT msg, WPARAM wparam, LPARAM lparam) diff --git a/dlls/winemac.drv/macdrv_main.c b/dlls/winemac.drv/macdrv_main.c index adcf6f73fc7..6ab7b108909 100644 --- a/dlls/winemac.drv/macdrv_main.c +++ b/dlls/winemac.drv/macdrv_main.c @@ -610,6 +610,7 @@ BOOL macdrv_SystemParametersInfo( UINT action, UINT int_param, void *ptr_param, const unixlib_entry_t __wine_unix_call_funcs[] = { macdrv_init, + macdrv_notify_icon, };
C_ASSERT( ARRAYSIZE(__wine_unix_call_funcs) == unix_funcs_count ); diff --git a/dlls/winemac.drv/systray.c b/dlls/winemac.drv/systray.c index a5ea7e55d79..c1901ae0036 100644 --- a/dlls/winemac.drv/systray.c +++ b/dlls/winemac.drv/systray.c @@ -245,12 +245,14 @@ static BOOL delete_icon(struct tray_icon *icon) * * Driver-side implementation of Shell_NotifyIcon. */ -int CDECL wine_notify_icon(DWORD msg, NOTIFYICONDATAW *data) +NTSTATUS macdrv_notify_icon(void *arg) { + struct notify_icon_params *params = arg; + NOTIFYICONDATAW *data = params->data; BOOL ret = FALSE; struct tray_icon *icon;
- switch (msg) + switch (params->msg) { case NIM_ADD: ret = add_icon(data); @@ -272,7 +274,7 @@ int CDECL wine_notify_icon(DWORD msg, NOTIFYICONDATAW *data) } break; default: - FIXME("unhandled tray message: %u\n", msg); + FIXME("unhandled tray message: %u\n", params->msg); break; } return ret; diff --git a/dlls/winemac.drv/unixlib.h b/dlls/winemac.drv/unixlib.h index 9f8cd4e0acb..c24f8192142 100644 --- a/dlls/winemac.drv/unixlib.h +++ b/dlls/winemac.drv/unixlib.h @@ -22,6 +22,7 @@ enum macdrv_funcs { unix_init, + unix_notify_icon, unix_funcs_count };
@@ -41,3 +42,10 @@ struct init_params { struct localized_string *strings; }; + +/* macdrv_notify_icon params */ +struct notify_icon_params +{ + DWORD msg; + struct _NOTIFYICONDATAW *data; +};
From: Jacek Caban jacek@codeweavers.com
Signed-off-by: Jacek Caban jacek@codeweavers.com --- dlls/winemac.drv/ime.c | 11 +++++++++-- dlls/winemac.drv/keyboard.c | 17 +++++++++++------ dlls/winemac.drv/macdrv.h | 3 +-- dlls/winemac.drv/macdrv_main.c | 8 ++++++++ dlls/winemac.drv/unixlib.h | 13 +++++++++++++ 5 files changed, 42 insertions(+), 10 deletions(-)
diff --git a/dlls/winemac.drv/ime.c b/dlls/winemac.drv/ime.c index 8b89c0089fc..d1d2002fc47 100644 --- a/dlls/winemac.drv/ime.c +++ b/dlls/winemac.drv/ime.c @@ -577,7 +577,7 @@ BOOL WINAPI ImeProcessKey(HIMC hIMC, UINT vKey, LPARAM lKeyData, const LPBYTE lp return FALSE; }
- inIME = macdrv_using_input_method(); + inIME = MACDRV_CALL(ime_using_input_method, NULL); lpIMC = LockRealIMC(hIMC); if (lpIMC) { @@ -658,6 +658,7 @@ BOOL WINAPI ImeSetActiveContext(HIMC hIMC, BOOL fFlag) UINT WINAPI ImeToAsciiEx(UINT uVKey, UINT uScanCode, const LPBYTE lpbKeyState, LPDWORD lpdwTransKey, UINT fuState, HIMC hIMC) { + struct process_text_input_params params; UINT vkey; LPINPUTCONTEXT lpIMC; LPIMEPRIVATE myPrivate; @@ -690,7 +691,13 @@ UINT WINAPI ImeToAsciiEx(UINT uVKey, UINT uScanCode, const LPBYTE lpbKeyState, UnlockRealIMC(hIMC);
TRACE("Processing Mac 0x%04x\n", vkey); - macdrv_process_text_input(uVKey, uScanCode, repeat, lpbKeyState, hIMC, &done); + params.vkey = uVKey; + params.scan = uScanCode; + params.repeat = repeat; + params.key_state = lpbKeyState; + params.himc = hIMC; + params.done = &done; + MACDRV_CALL(ime_process_text_input, ¶ms);
while (!done) MsgWaitForMultipleObjectsEx(0, NULL, INFINITE, QS_POSTMESSAGE | QS_SENDMESSAGE, 0); diff --git a/dlls/winemac.drv/keyboard.c b/dlls/winemac.drv/keyboard.c index 9574b2797b5..181e86afd4a 100644 --- a/dlls/winemac.drv/keyboard.c +++ b/dlls/winemac.drv/keyboard.c @@ -1187,13 +1187,16 @@ void macdrv_hotkey_press(const macdrv_event *event) /*********************************************************************** * macdrv_process_text_input */ -void macdrv_process_text_input(UINT vkey, UINT scan, UINT repeat, const BYTE *key_state, void *himc, int* done) +NTSTATUS macdrv_ime_process_text_input(void *arg) { + struct process_text_input_params *params = arg; struct macdrv_thread_data *thread_data = macdrv_thread_data(); + const BYTE *key_state = params->key_state; unsigned int flags; int keyc;
- TRACE("vkey 0x%04x scan 0x%04x repeat %u himc %p\n", vkey, scan, repeat, himc); + TRACE("vkey 0x%04x scan 0x%04x repeat %u himc %p\n", params->vkey, params->scan, + params->repeat, params->himc);
flags = thread_data->last_modifiers; if (key_state[VK_SHIFT] & 0x80) @@ -1215,17 +1218,19 @@ void macdrv_process_text_input(UINT vkey, UINT scan, UINT repeat, const BYTE *ke
/* Find the Mac keycode corresponding to the scan code */ for (keyc = 0; keyc < ARRAY_SIZE(thread_data->keyc2vkey); keyc++) - if (thread_data->keyc2vkey[keyc] == vkey) break; + if (thread_data->keyc2vkey[keyc] == params->vkey) break;
if (keyc >= ARRAY_SIZE(thread_data->keyc2vkey)) { - *done = -1; - return; + *params->done = -1; + return 0; }
TRACE("flags 0x%08x keyc 0x%04x\n", flags, keyc);
- macdrv_send_text_input_event(((scan & 0x8000) == 0), flags, repeat, keyc, himc, done); + macdrv_send_text_input_event(((params->scan & 0x8000) == 0), flags, params->repeat, keyc, + params->himc, params->done); + return 0; }
diff --git a/dlls/winemac.drv/macdrv.h b/dlls/winemac.drv/macdrv.h index a4736b2d315..2ea6cd638c3 100644 --- a/dlls/winemac.drv/macdrv.h +++ b/dlls/winemac.drv/macdrv.h @@ -287,8 +287,7 @@ extern NTSTATUS macdrv_init(void *arg) DECLSPEC_HIDDEN; * Mac IME driver */
-extern void macdrv_process_text_input(UINT vkey, UINT scan, UINT repeat, const BYTE *key_state, - void *himc, int* done) DECLSPEC_HIDDEN; +extern NTSTATUS macdrv_ime_process_text_input(void *arg) DECLSPEC_HIDDEN;
extern void macdrv_im_set_text(const macdrv_event *event) DECLSPEC_HIDDEN; extern void macdrv_sent_text_input(const macdrv_event *event) DECLSPEC_HIDDEN; diff --git a/dlls/winemac.drv/macdrv_main.c b/dlls/winemac.drv/macdrv_main.c index 6ab7b108909..4a183747796 100644 --- a/dlls/winemac.drv/macdrv_main.c +++ b/dlls/winemac.drv/macdrv_main.c @@ -607,8 +607,16 @@ BOOL macdrv_SystemParametersInfo( UINT action, UINT int_param, void *ptr_param, }
+static NTSTATUS macdrv_ime_using_input_method(void *arg) +{ + return macdrv_using_input_method(); +} + + const unixlib_entry_t __wine_unix_call_funcs[] = { + macdrv_ime_process_text_input, + macdrv_ime_using_input_method, macdrv_init, macdrv_notify_icon, }; diff --git a/dlls/winemac.drv/unixlib.h b/dlls/winemac.drv/unixlib.h index c24f8192142..dc1b314c8cb 100644 --- a/dlls/winemac.drv/unixlib.h +++ b/dlls/winemac.drv/unixlib.h @@ -21,6 +21,8 @@
enum macdrv_funcs { + unix_ime_process_text_input, + unix_ime_using_input_method, unix_init, unix_notify_icon, unix_funcs_count @@ -30,6 +32,17 @@ enum macdrv_funcs extern NTSTATUS unix_call(enum macdrv_funcs code, void *params) DECLSPEC_HIDDEN; #define MACDRV_CALL(func, params) unix_call( unix_ ## func, params )
+/* macdrv_ime_process_text_input params */ +struct process_text_input_params +{ + UINT vkey; + UINT scan; + UINT repeat; + const BYTE *key_state; + void *himc; + int *done; +}; + /* macdrv_init params */ struct localized_string {
This merge request was approved by Huw Davies.