class
DockManager
GUI element that allows editor windows to be docked in it using arbitrary layouts.
Docked windows can be resized, undocked, maximized or closed as needed.
Public
Methods
staticCreate
Creates a new dock manager for the specified window.
Update
Internal method.
Called once every frame.
Insert
Inserts a new window at the specified location.
- relativeTo
- Tab group relative to which to insert the window. Can be null in which case the window is inserted at the root.
- windowToInsert
- Window we want to insert into the dock layout.
- location
- Location to insert the window at, relative to container. If is null this is ignored.
GetLayout
Returns a saved layout of all the currently docked windows and their positions and areas.
SetLayout
Sets a previously saved layout of docked windows.
This will close all currently active windows and open and position new ones according to the layout.
SetArea
Changes the position and size of the dock manager.
SetDPIScale
Sets the DPI scale of all the container GUI widgets.
CloseAll
Closes all docked windows.
IsInInteractionBounds
Checks is the specified position within interactable bounds of a GUI element.
These are the bounds that will be used for hit tests for e.g. mouse cursor. By default this is the same as the absolute clipped bounds of the GUI element. Position is relative to parent GUI widget.
Private
Constructors
DockManager
Methods
~DockManager
UpdateDropOverlay
Updates the dock overlay mesh that is displayed when user is dragging a window over a certain area.
InsidePolygon
Checks is the provided point inside the provided polygon.
- polygonPoints
- Points of the polygon to test against.
- pointCount
- Number of points in "polyPoints".
- point
- Point to check if it's in the polygon.
Returns: True if the point is in the polygon.
ToggleMaximize
Maximizes or restored the specified container.
If any container is previously maximized it needs to be toggled back to restored state before maximizing another.
DoOnMouseEvent
Called when a mouse event is received on any GUI element the mouse is interacting with.
Return true if you have processed the event and don't want other elements to process it.