Author: tretiakov
Date: Wed Feb 28 16:23:51 2007
New Revision: 25923
URL:
http://svn.reactos.org/svn/reactos?rev=25923&view=rev
Log:
WM_INPUTLANGCHANGE is sent not posted.
Modified:
trunk/reactos/subsystems/win32/win32k/include/input.h
trunk/reactos/subsystems/win32/win32k/ntuser/kbdlayout.c
Modified: trunk/reactos/subsystems/win32/win32k/include/input.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/include/input.h (original)
+++ trunk/reactos/subsystems/win32/win32k/include/input.h Wed Feb 28 16:23:51 2007
@@ -7,7 +7,7 @@
{
LIST_ENTRY List;
DWORD Flags;
- WCHAR Name[9]; // used w GetKeyboardLayoutName same as wszKLID.
+ WCHAR Name[KL_NAMELENGTH]; // used w GetKeyboardLayoutName same as wszKLID.
struct _KBDTABLES* KBTables; // KBDTABLES in ntoskrnl/include/internal/kbd.h
HANDLE hModule;
ULONG RefCount;
Modified: trunk/reactos/subsystems/win32/win32k/ntuser/kbdlayout.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/nt…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/ntuser/kbdlayout.c (original)
+++ trunk/reactos/subsystems/win32/win32k/ntuser/kbdlayout.c Wed Feb 28 16:23:51 2007
@@ -318,10 +318,9 @@
return NULL;
}
-static PKBL UserActivateKbl(PW32THREAD Thread, PKBL pKbl)
+static PKBL co_UserActivateKbl(PW32THREAD Thread, PKBL pKbl)
{
PKBL Prev;
- MSG Msg;
Prev = Thread->KeyboardLayout;
Prev->RefCount--;
@@ -329,13 +328,10 @@
pKbl->RefCount++;
// Send WM_INPUTLANGCHANGE to thread's focus window
-
- Msg.hwnd = Thread->MessageQueue->FocusWindow;
- Msg.message = WM_INPUTLANGCHANGE;
- Msg.wParam = 0; // Charset. FIXME: what is this?
- Msg.lParam = (LPARAM)pKbl->hkl; // klid
-
- MsqPostMessage(Thread->MessageQueue, &Msg, FALSE, QS_POSTMESSAGE);
+ co_IntSendMessage(Thread->MessageQueue->FocusWindow,
+ WM_INPUTLANGCHANGE,
+ 0, // FIXME: put charset here (what is this?)
+ (LPARAM)pKbl->hkl); //klid
return Prev;
}
@@ -489,7 +485,7 @@
if(Flags & KLF_ACTIVATE)
{
- UserActivateKbl(PsGetCurrentThreadWin32Thread(), pKbl);
+ co_UserActivateKbl(PsGetCurrentThreadWin32Thread(), pKbl);
}
Ret = pKbl->hkl;
@@ -547,7 +543,7 @@
}
else
{
- pKbl = UserActivateKbl(pWThread, pKbl);
+ pKbl = co_UserActivateKbl(pWThread, pKbl);
Ret = pKbl->hkl;
}
}