win32u: Move NtUserSetKeyboardState implementation from user32.

Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Jacek Caban 2021-11-16 12:33:36 +01:00 committed by Alexandre Julliard
parent deb455ec25
commit 05db9f63e1
7 changed files with 27 additions and 19 deletions

View File

@ -593,23 +593,6 @@ BOOL WINAPI GetLastInputInfo(PLASTINPUTINFO plii)
}
/**********************************************************************
* SetKeyboardState (USER32.@)
*/
BOOL WINAPI SetKeyboardState( LPBYTE state )
{
BOOL ret;
SERVER_START_REQ( set_key_state )
{
wine_server_add_data( req, state, 256 );
ret = !wine_server_call_err( req );
}
SERVER_END_REQ;
return ret;
}
/**********************************************************************
* VkKeyScanA (USER32.@)
*

View File

@ -673,7 +673,7 @@
@ stdcall SetForegroundWindow(long)
@ stdcall SetGestureConfig(ptr long long ptr long)
@ stdcall SetInternalWindowPos(long long ptr ptr)
@ stdcall SetKeyboardState(ptr)
@ stdcall SetKeyboardState(ptr) NtUserSetKeyboardState
@ stdcall SetLastErrorEx(long long)
@ stdcall SetLayeredWindowAttributes(ptr long long long)
@ stdcall SetLogonNotifyWindow(long long)

View File

@ -93,3 +93,19 @@ BOOL WINAPI NtUserGetKeyboardState( BYTE *state )
SERVER_END_REQ;
return ret;
}
/**********************************************************************
* NtUserSetKeyboardState (win32u.@)
*/
BOOL WINAPI NtUserSetKeyboardState( BYTE *state )
{
BOOL ret;
SERVER_START_REQ( set_key_state )
{
wine_server_add_data( req, state, 256 );
ret = !wine_server_call_err( req );
}
SERVER_END_REQ;
return ret;
}

View File

@ -123,6 +123,7 @@ static void * const syscalls[] =
NtUserOpenWindowStation,
NtUserRemoveClipboardFormatListener,
NtUserRemoveProp,
NtUserSetKeyboardState,
NtUserSetObjectInformation,
NtUserSetProcessWindowStation,
NtUserSetProp,

View File

@ -1202,7 +1202,7 @@
@ stub NtUserSetInteractiveControlFocus
@ stub NtUserSetInteractiveCtrlRotationAngle
@ stub NtUserSetInternalWindowPos
@ stub NtUserSetKeyboardState
@ stdcall -syscall NtUserSetKeyboardState(ptr)
@ stub NtUserSetLayeredWindowAttributes
@ stub NtUserSetMagnificationDesktopMagnifierOffsetsDWMUpdated
@ stub NtUserSetManipulationInputTarget

View File

@ -110,6 +110,7 @@
SYSCALL_ENTRY( NtUserOpenWindowStation ) \
SYSCALL_ENTRY( NtUserRemoveClipboardFormatListener ) \
SYSCALL_ENTRY( NtUserRemoveProp ) \
SYSCALL_ENTRY( NtUserSetKeyboardState ) \
SYSCALL_ENTRY( NtUserSetObjectInformation ) \
SYSCALL_ENTRY( NtUserSetProcessWindowStation ) \
SYSCALL_ENTRY( NtUserSetProp ) \

View File

@ -251,3 +251,10 @@ NTSTATUS WINAPI wow64_NtUserGetKeyboardState( UINT *args )
return NtUserGetKeyboardState( state );
}
NTSTATUS WINAPI wow64_NtUserSetKeyboardState( UINT *args )
{
BYTE *state = get_ptr( &args );
return NtUserSetKeyboardState( state );
}