class SceneSelection

Inherits: IScriptExportable

Handles scene object selection.

Triggers events when selection changes and allows the user to query current selection state.

Public

Constructors

SceneSelection

SceneSelection()

Methods

~SceneSelection

~SceneSelection() noexcept

SetSelectedSceneObject

void SetSelectedSceneObject(const HSceneObject &sceneObject)

Currently selected scene object.

If there are multiple objects selected returns the first one.

GetSelectedSceneObject

HSceneObject GetSelectedSceneObject() const

SetSelectedSceneObjects

void SetSelectedSceneObjects(const Vector<HSceneObject> &sceneObjects)

Currently selected set of scene objects.

GetSelectedSceneObjects

const Vector<HSceneObject> &GetSelectedSceneObjects() const

ClearSceneSelection

void ClearSceneSelection()

Deselects all currently selected scene objects.

PingSceneObject

void PingSceneObject(const HSceneObject &sceneObject)

Pings the scene object, highlighting it in its respective editors.

Fields

OnSceneObjectsAdded

Event<void (const Vector<HSceneObject> &)> OnSceneObjectsAdded

Triggered when one or multiple scene objects is being added to the selection.

OnSceneObjectsRemoved

Event<void (const Vector<HSceneObject> &)> OnSceneObjectsRemoved

Triggered when one or multiple scene objects is being removed from the selection.

OnSelectionChanged

Event<void (const Vector<HSceneObject> &)> OnSelectionChanged

Triggered whenever scene object selection changes.

The provided parameters will contain the newly selected objects.

OnSceneObjectPing

Event<void (const HSceneObject &)> OnSceneObjectPing

Triggered when a scene object ping is requested.

Ping usually means the object will be highlighted in its respective editors.

Private

Methods

SceneSelectionChanged

void SceneSelectionChanged()

Triggered when the scene object selection in the scene tree view changes.

UpdateTreeView

void UpdateTreeView()

Updates scene tree view with new selection.

PruneDestroyedSceneObjects

void PruneDestroyedSceneObjects(Vector<HSceneObject> &sceneObjects) const

Removes any destroyed scene objects from the provided scene object list.

Fields

mSelectedSceneObjects

Vector<HSceneObject> mSelectedSceneObjects

mSceneSelectionChangedConn

HMessage mSceneSelectionChangedConn

mTempPrune

Vector<HSceneObject> mTempPrune

mTempSceneObjects

Vector<HSceneObject> mTempSceneObjects