Navigation
Unreal Engine C++ API Reference > Developer > SlateReflector
References
Module | SlateReflector |
Header | /Engine/Source/Developer/SlateReflector/Public/SlateNavigationEventSimulator.h |
Include | #include "SlateNavigationEventSimulator.h" |
Syntax
class FSlateNavigationEventSimulator
Remarks
HOW TO DEBUG NAVIGATION EVENTS Test the static result via FSlateNavigationEventSimulator. If the simulation doesn't work, your widget is probably not be configured properly. If the simulation does work, use the "WidgetReflector events log" or the "Console Slate Debugger" to get information on the navigation event while playing. A - If you do not find the event, check it has been consumed by the viewport or by a widget with OnKeyDown. B - If you find the event, note if the Reply and Consumed widget are different. i- If they are different, then use the "WidgetReflector routing" tool to understand why another widget has consumed the routing. For example, the widget can be disabled or it may have a custom OnNavigation event. ii- If they are not different, then the GameViewportClient or the application may have consumed the event. You may also check if you received the focus event with the "WidgetReflector events log" or with the "Console Slate Debugger". Simulate navigation attempt and collect the result for later display. Some elements may steel the navigation attempt dynamically and can be evaluated until evaluated in game. A list of elements that can still the navigation attempt and modify the result.
The viewport may consume the Navigation.
A widget may override the OnNavigation function and return a different result dynamically.
A widget can change its "enabled" and "supports keyboard focus" flags dynamically during gameplay.
The GameViewportClient may consume the event via the CustomNavigationEvent.
The application or a widget can consume the "set focus" event. Resulting in different behavior.
Variables
Type | Name | Description | |
---|---|---|---|
![]() |
FHandleNavigation | OnViewportHandleNavigation | Once the destination widget has been decided, the viewport may handled the event. |
Functions
Type | Name | Description | |
---|---|---|---|
![]() |
TArray< FSimulationResult > | Simulate
(
const FWidgetPath& WidgetPath, |
Simulate a navigation event for a widget |
![]() |
FSimulationResult | Simulate
(
const FWidgetPath& WidgetPath, |
Simulate a navigation event for a widget |
![]() |
TArray< FSimulationResult > | SimulateForEachWidgets
(
const FWidgetPath& WidgetPath, |
Simulate for each widgets that are enabled and support keyboard focus |
![]() |
TArray< FSimulationResult > | SimulateForEachWidgets
(
const TSharedRef< SWindow >& Window, |
Simulate for each widgets that are enabled and support keyboard focus |
![]() |
TArray< FSimulationResult > | SimulateForEachWidgets
(
const FWidgetPath& WidgetPath, |
Simulate for each widgets that are enabled and support keyboard focus |
![]() |
TArray< FSimulationResult > | SimulateForEachWidgets
(
const TSharedRef< SWindow >& Window, |
Simulate for each widgets that are enabled and support keyboard focus |
![]() ![]() |
FText | ToText
(
ENavigationStyle NavigationStyle |
|
![]() ![]() |
FText | ToText
(
ERoutedReason RoutedReason |
Classes
Type | Name | Description | |
---|---|---|---|
![]() |
FSimulatedReply | ||
![]() |
FSimulationResult |
Enums
Type | Name | Description | |
---|---|---|---|
![]() |
ENavigationStyle | ||
![]() |
ERoutedReason |
Typedefs
Name | Description |
---|---|
FHandleNavigation |