Piccolo.NET

PNode.ReplaceWith Method 

Swaps this node out of the scene graph tree, and replaces it with the specified replacement node.

public virtual void ReplaceWith(
   PNode replacementNode
);

Parameters

replacementNode
The new node that replaces the current node in the scene graph tree.

Remarks

This node is left dangling, and it is up to the caller to manage it. The replacement node will be added to this node's parent in the same position as this node was located. That is, if this was the 3rd child of its parent, then after calling ReplaceWith, the replacement node will also be the 3rd child of its parent. If this node has no parent when ReplaceWith is called, then nothing will be done at all.

See Also

PNode Class | UMD.HCIL.Piccolo Namespace


Web Accessibility