Allows call bulk actions with scene items and folders. Selection can contain items only for one scene.

see

Scene.getSelection() to fetch a new selection object

see

SelectionService to make items active

Hierarchy

Implements

  • ISceneItemActions

Index

Constructors

constructor

  • new Selection(sceneId: string, itemsList?: string[]): Selection

Accessors

sceneId

  • get sceneId(): string

Methods

add

centerOnScreen

  • centerOnScreen(): void

clone

copyTo

  • copyTo(sceneId: string, folderId?: string, duplicateSources?: boolean): void
  • Copy selected item and folders to specific scene or folder For sources duplication use .copyTo() method.

    see

    ISelection.copyTo()

    Parameters

    • sceneId: string
    • Optional folderId: string
    • Optional duplicateSources: boolean

    Returns void

deselect

fitToScreen

  • fitToScreen(): void

flipX

  • flipX(): void

flipY

  • flipY(): void

getBoundingRect

  • getBoundingRect(): IRectangle

getFolders

getIds

  • getIds(): string[]

getInverted

  • Returns the inverted selection. The current object will not be changed. To change the current object use .invert()

    see

    ISelection.invert()

    Returns SceneNode[]

getInvertedIds

  • getInvertedIds(): string[]

getItems

getLastSelected

getLastSelectedId

  • getLastSelectedId(): string

getModel

getRootNodes

  • Returns a minimal representation of selection for selection list like this:

    Folder1 <- selected |_ Item1 <- selected _ Folder2 <- selected Item3 <- selected Folder3 |_ Item3 _ Item4 <- selected

    returns Folder1, Item3, Item4

    Returns SceneNode[]

getScene

getSize

  • getSize(): number

getSources

getVisualItems

invert

  • Invert current selection. If you need to get an inverted selection without changing the current object use .getInverted()

    see

    ISelection.getInverted()

    Returns Selection

isSceneFolder

  • isSceneFolder(): boolean

isSceneItem

  • isSceneItem(): boolean

isSelected

  • isSelected(nodeId: string): boolean

moveTo

  • moveTo(sceneId: string, folderId?: string): void
  • Do the same as .copyTo() and remove copied items

    Parameters

    • sceneId: string
    • Optional folderId: string

    Returns void

placeAfter

  • placeAfter(sceneNodeId: string): void
  • Bulk version of SceneNodeApi.placeAfter()

    see

    SceneNodeApi.placeAfter()

    Parameters

    • sceneNodeId: string

    Returns void

placeBefore

  • placeBefore(sceneNodeId: string): void
  • Bulk version of SceneNodeApi.placeBefore()

    see

    SceneNodeApi.placeBefore()

    Parameters

    • sceneNodeId: string

    Returns void

remove

  • remove(): void

reset

resetTransform

  • resetTransform(): void

rotate

  • rotate(deg: number): void

scale

  • scale(scale: IVec2, origin?: IVec2): void

scaleWithOffset

  • scaleWithOffset(scale: IVec2, offset: IVec2): void

select

selectAll

setContentCrop

  • setContentCrop(): void

setParent

  • setParent(folderId: string): void
  • Bulk version of SceneNodeApi.setParent()

    see

    SceneNodeApi.setParent()

    Parameters

    • folderId: string

    Returns void

setRecordingVisible

  • setRecordingVisible(recordingVisible: boolean): void

setSettings

  • setSettings(settings: Partial<ISceneItemSettings>): void

setStreamVisible

  • setStreamVisible(streamVisible: boolean): void

setTransform

  • setTransform(transform: IPartialTransform): void

setVisibility

  • setVisibility(visible: boolean): void

stretchToScreen

  • stretchToScreen(): void