Uranium
Application Framework
|
Operation that adds a new node to the scene. More...
Public Member Functions | |
__init__ (self, SceneNode node, Optional[SceneNode] parent) | |
Creates the scene node operation. | |
undo (self) | |
Reverses the operation of adding a scene node. | |
redo (self) | |
Re-applies this operation after it has been undone. | |
![]() | |
__init__ (self) | |
undo (self) | |
Undo the operation. | |
redo (self) | |
Redo the operation. | |
mergeWith (self, other) | |
Perform operation merging. | |
push (self) | |
Push the operation onto the stack. | |
Protected Attributes | |
_node | |
_parent | |
_selected | |
![]() | |
_timestamp | |
_always_merge | |
Operation that adds a new node to the scene.
UM.Operations.AddSceneNodeOperation.AddSceneNodeOperation.__init__ | ( | self, | |
SceneNode | node, | ||
Optional[SceneNode] | parent | ||
) |
Creates the scene node operation.
This saves the node and its parent to be able to search for the node to remove the node if we want to undo, and to be able to re-do the adding of the node.
node | The node to add to the scene. |
parent | The parent of the new node. |
Reimplemented from UM.Operations.Operation.Operation.
UM.Operations.AddSceneNodeOperation.AddSceneNodeOperation.redo | ( | self | ) |
Re-applies this operation after it has been undone.
Reimplemented from UM.Operations.Operation.Operation.
UM.Operations.AddSceneNodeOperation.AddSceneNodeOperation.undo | ( | self | ) |
Reverses the operation of adding a scene node.
This removes the scene node again.
Reimplemented from UM.Operations.Operation.Operation.