Module: wine Branch: master Commit: 158d6caabe4fe8776cfd9702d1c8de5d082fafc7 URL: https://gitlab.winehq.org/wine/wine/-/commit/158d6caabe4fe8776cfd9702d1c8de5...
Author: Rémi Bernon rbernon@codeweavers.com Date: Thu Mar 30 15:33:10 2023 +0200
winemac: Rename imeData / data members and variables to himc.
---
dlls/winemac.drv/cocoa_window.h | 2 +- dlls/winemac.drv/cocoa_window.m | 14 +++++++------- dlls/winemac.drv/event.c | 8 ++++---- dlls/winemac.drv/ime.c | 4 ++-- dlls/winemac.drv/macdrv_cocoa.h | 4 ++-- dlls/winemac.drv/unixlib.h | 4 ++-- 6 files changed, 18 insertions(+), 18 deletions(-)
diff --git a/dlls/winemac.drv/cocoa_window.h b/dlls/winemac.drv/cocoa_window.h index a83f2aa803b..9539e4ebdd7 100644 --- a/dlls/winemac.drv/cocoa_window.h +++ b/dlls/winemac.drv/cocoa_window.h @@ -65,7 +65,7 @@ NSRect frameAtResizeStart; BOOL resizingFromLeft, resizingFromTop;
- void* imeData; + void* himc; BOOL commandDone;
NSSize savedContentMinSize; diff --git a/dlls/winemac.drv/cocoa_window.m b/dlls/winemac.drv/cocoa_window.m index 2525c894d09..67e178c8ad3 100644 --- a/dlls/winemac.drv/cocoa_window.m +++ b/dlls/winemac.drv/cocoa_window.m @@ -403,7 +403,7 @@ static CVReturn WineDisplayLinkCallback(CVDisplayLinkRef displayLink, const CVTi @property (nonatomic) CGFloat colorKeyRed, colorKeyGreen, colorKeyBlue; @property (nonatomic) BOOL usePerPixelAlpha;
-@property (assign, nonatomic) void* imeData; +@property (assign, nonatomic) void* himc; @property (nonatomic) BOOL commandDone;
@property (readonly, copy, nonatomic) NSArray* childWineWindows; @@ -714,7 +714,7 @@ static CVReturn WineDisplayLinkCallback(CVDisplayLinkRef displayLink, const CVTi WineWindow* window = (WineWindow*)[self window];
event = macdrv_create_event(IM_SET_TEXT, window); - event->im_set_text.data = [window imeData]; + event->im_set_text.himc = [window himc]; event->im_set_text.text = (CFStringRef)[text copy]; event->im_set_text.complete = TRUE;
@@ -797,7 +797,7 @@ static CVReturn WineDisplayLinkCallback(CVDisplayLinkRef displayLink, const CVTi markedTextSelection.location += replacementRange.location;
event = macdrv_create_event(IM_SET_TEXT, window); - event->im_set_text.data = [window imeData]; + event->im_set_text.himc = [window himc]; event->im_set_text.text = (CFStringRef)[[markedText string] copy]; event->im_set_text.complete = FALSE; event->im_set_text.cursor_pos = markedTextSelection.location + markedTextSelection.length; @@ -860,7 +860,7 @@ static CVReturn WineDisplayLinkCallback(CVDisplayLinkRef displayLink, const CVTi query = macdrv_create_query(); query->type = QUERY_IME_CHAR_RECT; query->window = (macdrv_window)[window retain]; - query->ime_char_rect.data = [window imeData]; + query->ime_char_rect.himc = [window himc]; query->ime_char_rect.range = CFRangeMake(aRange.location, aRange.length);
if ([window.queue query:query timeout:0.3 flags:WineQueryNoPreemptWait]) @@ -947,7 +947,7 @@ static CVReturn WineDisplayLinkCallback(CVDisplayLinkRef displayLink, const CVTi @synthesize shapeChangedSinceLastDraw; @synthesize colorKeyed, colorKeyRed, colorKeyGreen, colorKeyBlue; @synthesize usePerPixelAlpha; - @synthesize imeData, commandDone; + @synthesize himc, commandDone;
+ (WineWindow*) createWindowWithFeatures:(const struct macdrv_window_features*)wf windowFrame:(NSRect)window_frame @@ -3903,7 +3903,7 @@ uint32_t macdrv_window_background_color(void) /*********************************************************************** * macdrv_send_text_input_event */ -void macdrv_send_text_input_event(int pressed, unsigned int flags, int repeat, int keyc, void* data, int* done) +void macdrv_send_text_input_event(int pressed, unsigned int flags, int repeat, int keyc, void* himc, int* done) { OnMainThreadAsync(^{ BOOL ret; @@ -3922,7 +3922,7 @@ void macdrv_send_text_input_event(int pressed, unsigned int flags, int repeat, i CGEventRef c; NSEvent* event;
- window.imeData = data; + window.himc = himc; fix_device_modifiers_by_generic(&localFlags);
// An NSEvent created with +keyEventWithType:... is internally marked diff --git a/dlls/winemac.drv/event.c b/dlls/winemac.drv/event.c index 5953dc0e0d8..03c49b34bae 100644 --- a/dlls/winemac.drv/event.c +++ b/dlls/winemac.drv/event.c @@ -154,7 +154,7 @@ static void macdrv_im_set_text(const macdrv_event *event) struct ime_set_text_params *params; CFIndex length = 0, size;
- TRACE_(imm)("win %p/%p himc %p text %s complete %u\n", hwnd, event->window, event->im_set_text.data, + TRACE_(imm)("win %p/%p himc %p text %s complete %u\n", hwnd, event->window, event->im_set_text.himc, debugstr_cf(event->im_set_text.text), event->im_set_text.complete);
if (event->im_set_text.text) @@ -163,7 +163,7 @@ static void macdrv_im_set_text(const macdrv_event *event) size = offsetof(struct ime_set_text_params, text[length]); if (!(params = malloc(size))) return; params->hwnd = HandleToUlong(hwnd); - params->data = (UINT_PTR)event->im_set_text.data; + params->himc = (UINT_PTR)event->im_set_text.himc; params->cursor_pos = event->im_set_text.cursor_pos; params->complete = event->im_set_text.complete;
@@ -287,7 +287,7 @@ static BOOL query_drag_operation(macdrv_query *query) BOOL query_ime_char_rect(macdrv_query* query) { HWND hwnd = macdrv_get_window_hwnd(query->window); - void *himc = query->ime_char_rect.data; + void *himc = query->ime_char_rect.himc; CFRange *range = &query->ime_char_rect.range; CGRect *rect = &query->ime_char_rect.rect; struct ime_query_char_rect_result result = { .location = 0 }; @@ -298,7 +298,7 @@ BOOL query_ime_char_rect(macdrv_query* query) range->length);
params.hwnd = HandleToUlong(hwnd); - params.data = (UINT_PTR)himc; + params.himc = (UINT_PTR)himc; params.result = (UINT_PTR)&result; params.location = range->location; params.length = range->length; diff --git a/dlls/winemac.drv/ime.c b/dlls/winemac.drv/ime.c index 94953a1fd66..363bd8f9a1f 100644 --- a/dlls/winemac.drv/ime.c +++ b/dlls/winemac.drv/ime.c @@ -1321,7 +1321,7 @@ NTSTATUS WINAPI macdrv_ime_set_text(void *arg, ULONG size) { struct ime_set_text_params *params = arg; ULONG length = (size - offsetof(struct ime_set_text_params, text)) / sizeof(WCHAR); - void *himc = param_ptr(params->data); + void *himc = param_ptr(params->himc); HWND hwnd = UlongToHandle(params->hwnd);
if (!himc) himc = RealIMC(FROM_MACDRV); @@ -1365,7 +1365,7 @@ NTSTATUS WINAPI macdrv_ime_query_char_rect(void *arg, ULONG size) { struct ime_query_char_rect_params *params = arg; struct ime_query_char_rect_result *result = param_ptr(params->result); - void *himc = param_ptr(params->data); + void *himc = param_ptr(params->himc); IMECHARPOSITION charpos; BOOL ret = FALSE;
diff --git a/dlls/winemac.drv/macdrv_cocoa.h b/dlls/winemac.drv/macdrv_cocoa.h index a82dd319330..4f17d861785 100644 --- a/dlls/winemac.drv/macdrv_cocoa.h +++ b/dlls/winemac.drv/macdrv_cocoa.h @@ -378,7 +378,7 @@ typedef struct macdrv_event { unsigned long time_ms; } hotkey_press; struct { - void *data; + void *himc; CFStringRef text; /* new text or NULL if just completing existing text */ unsigned int cursor_pos; unsigned int complete; /* is completing text? */ @@ -487,7 +487,7 @@ typedef struct macdrv_query { CFTypeRef pasteboard; } drag_operation; struct { - void *data; + void *himc; CFRange range; CGRect rect; } ime_char_rect; diff --git a/dlls/winemac.drv/unixlib.h b/dlls/winemac.drv/unixlib.h index 07f0da4a6f3..108ace8914c 100644 --- a/dlls/winemac.drv/unixlib.h +++ b/dlls/winemac.drv/unixlib.h @@ -177,7 +177,7 @@ struct ime_query_char_rect_params { UINT32 hwnd; UINT32 location; - UINT64 data; + UINT64 himc; UINT64 result; /* FIXME: Use NtCallbackReturn instead */ UINT32 length; }; @@ -187,7 +187,7 @@ struct ime_set_text_params { UINT32 hwnd; UINT32 cursor_pos; - UINT64 data; + UINT64 himc; UINT32 complete; WCHAR text[1]; };