Author: jimtabor Date: Thu Aug 11 22:04:33 2016 New Revision: 72202 URL: http://svn.reactos.org/svn/reactos?rev=72202&view=rev Log: [NtUser] - If focus window null use active.
Modified: trunk/reactos/win32ss/user/ntuser/kbdlayout.c Modified: trunk/reactos/win32ss/user/ntuser/kbdlayout.c URL: http://svn.reactos.org/svn/reactos/trunk/reactos/win32ss/user/ntuser/kbdlayout.c?rev=72202&r1=72201&r2=72202&view=diff ============================================================================== --- trunk/reactos/win32ss/user/ntuser/kbdlayout.c [iso-8859-1] (original) +++ trunk/reactos/win32ss/user/ntuser/kbdlayout.c [iso-8859-1] Thu Aug 11 22:04:33 2016 @@ -410,6 +410,7 @@ co_UserActivateKbl(PTHREADINFO pti, PKL pKl, UINT Flags) { PKL pklPrev; + PWND pWnd; pklPrev = pti->KeyboardLayout; if (pklPrev) @@ -424,8 +425,13 @@ // FIXME } + if (!(pWnd = pti->MessageQueue->spwndFocus)) + { + pWnd = pti->MessageQueue->spwndActive; + } + // Send WM_INPUTLANGCHANGE to thread's focus window - co_IntSendMessage(pti->MessageQueue->spwndFocus ? UserHMGetHandle(pti->MessageQueue->spwndFocus) : 0, + co_IntSendMessage( pWnd ? UserHMGetHandle(pWnd) : 0, WM_INPUTLANGCHANGE, (WPARAM)pKl->iBaseCharset, // FIXME: How to set it? (LPARAM)pKl->hkl); // hkl