XamlSourceFocusNavigationReason Enum
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Specifies values that represent reasons that a UIElement got focus in a desktop application that uses a DesktopWindowXamlSource object to host XAML-based UI.
public enum class XamlSourceFocusNavigationReason
/// [Windows.Foundation.Metadata.ContractVersion(Microsoft.UI.Xaml.WinUIContract, 327680)]
enum class XamlSourceFocusNavigationReason
[Windows.Foundation.Metadata.ContractVersion(typeof(Microsoft.UI.Xaml.WinUIContract), 327680)]
public enum XamlSourceFocusNavigationReason
Public Enum XamlSourceFocusNavigationReason
- Inheritance
-
XamlSourceFocusNavigationReason
- Attributes
Fields
Name | Value | Description |
---|---|---|
Programmatic | 0 | The focus was set programmatically. |
Restore | 1 | The focus was restored after a task switch, such as pressing Alt + Tab. |
First | 3 | The focus was set in response to the user navigating to the next element by using bidirectional navigation, such as pressing Tab. |
Last | 4 | The focus was set in response to the user navigating to the previous element by using bidirectional navigation, such as pressing Shift-Tab. |
Left | 7 | The focus was set in response to the user navigating left by using 4-direction navigation, such as pressing keyboard arrow keys. |
Up | 8 | The focus was set in response to the user navigating up by using 4-direction navigation, such as pressing keyboard arrow keys. |
Right | 9 | The focus was set in response to the user navigating right by using 4-direction navigation, such as pressing keyboard arrow keys. |
Down | 10 | The focus was set in response to the user navigating down by using 4-direction navigation, such as pressing keyboard arrow keys. |
Examples
This sample shows how to add a WASDK island with XAML content to a Win32 app (the Windows App SDK runtime must be installed for the app to run).
Applies to
See also
- <xref:Microsoft.UI.Xaml.Hosting.XamlSourceFocusNavigationRequest.Reason%0a%0a%5bUsing+the+WinRT+XAML+hosting+API+in+a+C%2b%2b+desktop+(Win32)+app%5d(%2fwindows%2fapps%2fdesktop%2fmodernize%2fusing-the-xaml-hosting-api)>