Class RuntimePanelSimulator
A PanelSimulator for use with runtime tests.
Inherited Members
Namespace: UnityEngine.UIElements.TestFramework
Assembly: Unity.UI.TestFramework.Runtime.dll
Syntax
public sealed class RuntimePanelSimulator : PanelSimulator
Constructors
RuntimePanelSimulator()
Creates a RuntimePanelSimulator with
a null PanelSettings.
Declaration
public RuntimePanelSimulator()
RuntimePanelSimulator(PanelSettings)
Creates a RuntimePanelSimulator with
the provided panelSettings.
Declaration
public RuntimePanelSimulator(PanelSettings panelSettings)
Parameters
| Type | Name | Description |
|---|---|---|
| PanelSettings | panelSettings | The |
Properties
pickingDirection
The direction used for the picking algorithm for pointer interactions in world space. The picking direction can use the element's direction (default) or the panel's direction. When the panel's direction is used, picking occurs in the panel's forward axis regardless of the element's rotation within the panel.
Declaration
public PickingDirection pickingDirection { get; set; }
Property Value
| Type | Description |
|---|---|
| PickingDirection |
pickingDistance
The distance used for the picking algorithm for pointer interactions in world space.
Declaration
public float pickingDistance { get; set; }
Property Value
| Type | Description |
|---|---|
| float |
Methods
FrameUpdate(double)
Performs a frame update of the panel.
Declaration
public override void FrameUpdate(double time)
Parameters
| Type | Name | Description |
|---|---|---|
| double | time | The amount of time in seconds to increment the simulated time. |
Overrides
Remarks
This method simulates yielding a frame by the following:
- Updates the scheduler and the panel's visual tree updaters.
- Advances the time by the amount specified in
time. - When needsRendering is true, it triggers rendering for the panel's
ImmediateModeElementand invokesIMGUIContainer'sOnGUIwith a Repaint Event.