Package | com.yworks.graph.input |
Interface | public interface IReparentStripeHandler |
Implementors | ReparentStripeHandler |
See also
Method | Defined By | ||
---|---|---|---|
Determines whether the user may detach the given stripe from its current parent in
order to reparent it. | IReparentStripeHandler | ||
isValidParent(context:IInputModeContext, stripe:IStripe, newParent:IStripe, index:int, gesture:ReparentGesture):Boolean
Determines whether the provided node may be reparented to the given new parent. | IReparentStripeHandler | ||
reparent(context:IInputModeContext, movedStripe:IStripe, newParent:IStripe, index:int, gesture:ReparentGesture):void
Performs the actual reparenting after the reparent gesture has been finalized. | IReparentStripeHandler |
canReparent | () | method |
public function canReparent(context:IInputModeContext, stripe:IStripe):Boolean
Determines whether the user may detach the given stripe from its current parent in order to reparent it.
Parameters
context:IInputModeContext — The context that provides information about the user input.
| |
stripe:IStripe — The stripe that is about to be detached from its current parent.
|
Boolean — Whether the stripe may be detached and reparented.
|
isValidParent | () | method |
public function isValidParent(context:IInputModeContext, stripe:IStripe, newParent:IStripe, index:int, gesture:ReparentGesture):Boolean
Determines whether the provided node may be reparented to the given new parent.
This method is called to determine whether a reparent operation should actually be executed.
Parameters
context:IInputModeContext — The context that provides information about the user input.
| |
stripe:IStripe — The stripe that will be reparented.
| |
newParent:IStripe — The potential new parent.
| |
index:int — The index where the stripe would be reparented.
| |
gesture:ReparentGesture — The gesture that would be used for the reparent operation.
|
Boolean — Whether newParent is a valid new parent for stripe
for the given index.
|
reparent | () | method |
public function reparent(context:IInputModeContext, movedStripe:IStripe, newParent:IStripe, index:int, gesture:ReparentGesture):void
Performs the actual reparenting after the reparent gesture has been finalized.
Implementations should use ITable.setParentColumn(IColumn,IColumn,int)
or ITable.setParentRow(IRow,IRow,int)
to set the parent of
movedStripe
to newParent
.
Parameters
context:IInputModeContext — The context that provides information about the user input.
| |
movedStripe:IStripe — The stripe that will be reparented.
| |
newParent:IStripe — The potential new parent.
| |
index:int — The index where the stripe should be inserted.
| |
gesture:ReparentGesture — The gesture that triggered the reparent operation.
|
See also