Protected
_Protected
Optional
_Protected
_Optional
uiReadonly
undoOptional
undoStatic
Optional
Readonly
OldStatic
Readonly
PluginProtected
_Protected
_Protected
_Optional
prefix: stringOptional
meta: SerializationMetaTypePerforms an action with undo/redo support.
the target object to call the action on
a function that returns - 1. an undo function, 2. an object with undo and redo functions (and optional action)
the arguments to pass to the action function
unique identifier for the command, not really used in actions
Optional
onUndoRedo: (c: ActionUndoCommand) => voidoptional callback function to be called on undo/redo of the command. Not called on first action execution, only on undo/redo.
Optional
setSets a value in the target object with undo/redo support.
a tuple of target object and key to set the value on
the value to set
properties for the undo command, including last, and lastValue(optional)
Optional
uid: anyunique identifier for the command, used to merge commands
Optional
forceOnChange: booleanwhether to track the undo command or not, defaults to true
Optional
onUndoRedo: (c: SetValueUndoCommand) => voidoptional callback function to be called on undo/redo of the command
true if the value was set and the command was recorded, false if the command was not recorded (e.g. if it was not undoable or forceOnChange was false)
Optional
uid: anyOptional
forceOnChange: booleanOptional
onUndoRedo: (c: SetValueUndoCommand) => void
UndoManagerPlugin is a plugin for ThreeViewer that provides undo/redo functionality. It uses the JSUndoManager(from ts-browser-helpers) library to maintain a common undo/redo history across the viewer and other plugins.