Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor(windows): remove wm_keyman_keydown and wm_keyman_keyup #11920

Merged
merged 1 commit into from
Jul 3, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 0 additions & 3 deletions windows/src/engine/keyman32/appint/aiTIP.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -191,9 +191,6 @@ extern "C" __declspec(dllexport) BOOL WINAPI TIPProcessKey(WPARAM wParam, LPARAM
_td->TIPFUpdateable = Updateable;
_td->TIPFPreserved = Preserved; // I4290

_td->state.msg.hwnd = GetFocus();
_td->state.msg.lParam = 0;
_td->state.msg.message = wm_keymankeydown;
_td->state.vkey = (WORD) wParam;
_td->state.isDown = !isUp;

Expand Down
2 changes: 1 addition & 1 deletion windows/src/engine/keyman32/calldll.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -270,7 +270,7 @@ extern "C" uint8_t IM_CallBackCore(km_core_state *km_state, uint32_t UniqueStore
SendDebugMessageFormat(0, sdmKeyboard, 0, "IM_CallBackCore: td TIPFUpdatable about to call function [%s]", imdh->name);
LogContext(_td->lpActiveKeyboard->lpCoreKeyboardState, CONTEXT_CORE);
LogContext(_td->lpActiveKeyboard->lpCoreKeyboardState, CONTEXT_INT);
(*imdh->function)(_td->state.msg.hwnd, _td->state.vkey, _td->state.charCode, Globals::get_ShiftState());
(*imdh->function)(GetFocus(), _td->state.vkey, _td->state.charCode, Globals::get_ShiftState());

//SendDebugMessageFormat(0, sdmKeyboard, 0, "IM_CallBackCore: Exit");
return TRUE;
Expand Down
2 changes: 0 additions & 2 deletions windows/src/engine/keyman32/globals.h
Original file line number Diff line number Diff line change
Expand Up @@ -252,8 +252,6 @@ extern UINT
wm_keyman, // user message - ignore msg
wm_keyman_control, // messages to main Keyman window - replaces WM_USER+*
wm_keyman_control_internal, // messages to all windows to notify of changes to Keyman // I4412
wm_keymankeydown,
wm_keymankeyup,
wm_keyman_grabwindowproc,
wm_keyman_refresh,
wm_kmgetactivekeymanid,
Expand Down
8 changes: 1 addition & 7 deletions windows/src/engine/keyman32/k32_dbg.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -225,13 +225,7 @@ void DebugMessage(LPMSG msg, WPARAM wParam) // I2908
{
char ds[256];

if(msg->message == wm_keymankeydown)
wsprintf(ds, "DebugMessage(%x, wm_keymankeydown: %s lParam: %X) [message flags: %x time: %d]", PtrToInt(msg->hwnd),
Debug_VirtualKey((WORD) msg->wParam), (unsigned int) msg->lParam, wParam, (int) msg->time);
else if(msg->message == wm_keymankeyup)
wsprintf(ds, "DebugMessage(%x, wm_keymankeyup: %s lParam: %X) [message flags: %x time: %d]", PtrToInt(msg->hwnd),
Debug_VirtualKey((WORD) msg->wParam), (unsigned int) msg->lParam, wParam, (int) msg->time);
else if (msg->message == WM_KEYMAN_KEY_EVENT)
if (msg->message == WM_KEYMAN_KEY_EVENT)
wsprintf(ds, "DebugMessage(%x, WM_KEYMAN_KEY_EVENT: %s lParam: %X) [message flags: %x time: %d]", PtrToInt(msg->hwnd),
Debug_VirtualKey((WORD)msg->wParam), (unsigned int) msg->lParam, wParam, (int) msg->time);
else if(msg->message == WM_KEYDOWN || msg->message == WM_KEYUP || msg->message == WM_SYSKEYDOWN || msg->message == WM_SYSKEYUP)
Expand Down
2 changes: 0 additions & 2 deletions windows/src/engine/keyman32/k32_globals.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,6 @@ UINT
//TODO: consolidate these messages -- they are probably not all required now
wm_keyman = 0, // user message - ignore msg // I3594

wm_keymankeydown = 0,
wm_keymankeyup = 0,
wm_keyman_grabwindowproc = 0,
wm_keyman_refresh = 0,
wm_kmgetactivekeymanid = 0,
Expand Down
4 changes: 0 additions & 4 deletions windows/src/engine/keyman32/keyman32.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -190,8 +190,6 @@ void DoChangeWindowMessageFilter()
}

DoCWMF(wm_keyman); // I3594
DoCWMF(wm_keymankeydown);
DoCWMF(wm_keymankeyup);
DoCWMF(wm_keyman_grabwindowproc);
DoCWMF(wm_keyman_refresh);
DoCWMF(wm_kmgetactivekeymanid);
Expand Down Expand Up @@ -255,8 +253,6 @@ BOOL InitialiseProcess(HWND hwnd)
Initialise_Flag_ShouldSerializeInput();

wm_keyman = RegisterWindowMessage(RWM_KEYMAN);
wm_keymankeydown = RegisterWindowMessage("WM_KEYMANKEYDOWN");
wm_keymankeyup = RegisterWindowMessage("WM_KEYMANKEYUP");
wm_keyman_grabwindowproc = RegisterWindowMessage("WM_KEYMAN_GRABWINDOWPROC");
wm_keyman_refresh = RegisterWindowMessage("WM_KEYMANREFRESH");
wm_kmgetactivekeymanid = RegisterWindowMessage("WM_KEYMAN_GETACTIVEKEYMANID");
Expand Down
1 change: 0 additions & 1 deletion windows/src/engine/keyman32/keymanengine.h
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,6 @@ typedef struct tagINTKEYBOARDINFO
typedef struct tagKMSTATE
{
BOOL NoMatches;
MSG msg;
WORD vkey; // I934
WCHAR charCode; // I4582
BOOL windowunicode; // I4287
Expand Down
Loading
Loading