Skip to content

Commit eba68e6

Browse files
Merge pull request #2461 from citelao/patch-3
[GetKeyState] Add a reference to the WinUI replacement for CoreWindow.GetKeyState
2 parents 6467b39 + b9ac912 commit eba68e6

1 file changed

Lines changed: 9 additions & 2 deletions

File tree

windows.ui.core/corewindow_getkeystate_1676715341.md

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,11 +20,18 @@ The virtual key for which state is returned.
2020
The flags indicating the current state of the supplied virtual key when the input event fired.
2121

2222
> [!NOTE]
23-
> All keys support the **Locked** state (not just the standard Caps Lock and Num Lock keys).
23+
> For WinUI 3 apps, this method returns null. Use [**Microsoft.UI.Input.InputKeyboardSource.GetKeyStateForCurrentThread**](/windows/windows-app-sdk/api/winrt/microsoft.ui.input.inputkeyboardsource.getkeystateforcurrentthread) instead.
24+
>
25+
> See [Windows Runtime APIs not supported in desktop apps](/windows/apps/desktop/modernize/desktop-to-uwp-supported-api).
2426
2527
## -remarks
2628

29+
All keys support the **Locked** state (not just the standard Caps Lock and Num Lock keys).
30+
2731
## -examples
2832

2933
## -see-also
30-
[CoreVirtualKeyStates](corevirtualkeystates.md), [GetAsyncKeyState](corewindow_getasynckeystate_1621551046.md)
34+
35+
* [CoreVirtualKeyStates](corevirtualkeystates.md)
36+
* [GetAsyncKeyState](corewindow_getasynckeystate_1621551046.md)
37+
* [InputKeyboardSource.GetKeyStateForCurrentThread](/windows/windows-app-sdk/api/winrt/microsoft.ui.input.inputkeyboardsource.getkeystateforcurrentthread)

0 commit comments

Comments
 (0)