Default implementation of the IReparentStripeHandler interface.
Remarks
Type Details
- yfiles module
- view-table
- yfiles-umd modules
- view-table, view
- Legacy UMD name
- yfiles.input.ReparentStripeHandler
Constructors
Initializes a new instance of the ReparentStripeHandler class.
Parameters
A map of options to pass to the method.
- maxRowLevel - number
The maximum nesting level the row hierarchy may acquire during a reparent gesture. This option sets the maxRowLevel property on the created object.
- maxColumnLevel - number
The maximum nesting level the column hierarchy may acquire during a reparent gesture. This option sets the maxColumnLevel property on the created object.
Properties
Gets or sets the maximum nesting level the column hierarchy may acquire during a reparent gesture.
Remarks
0x7FFFFFFF
, which effectively means an unlimited nesting depth.Gets or sets the maximum nesting level the row hierarchy may acquire during a reparent gesture.
Remarks
0x7FFFFFFF
, which effectively means an unlimited nesting depth.Methods
adjustSize
(context: IInputModeContext, stripe: IStripe, newParent: IStripe, reparentPosition: StripeReparentPolicy, index: number, originalStripeSize: number, originalParentSize: number)Adjust the size of the source or the target stripe.
Remarks
stripe
to Math.Max(originalStripeSize, originalParentSize)
if reparentPosition
is an ADD_CHILD operationParameters
A map of options to pass to the method.
- 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.
- reparentPosition - StripeReparentPolicy
- Where to place the stripe as a result of the gesture that triggered the reparent operation.
- index - number
- The index where the stripe should be inserted.
- originalStripeSize - number
- The original size of
stripe
- originalParentSize - number
- The original size of
newParent
isValidParent
(context: IInputModeContext, stripe: IStripe, newParent: IStripe, index: number, reparentPosition: StripeReparentPolicy) : booleanChecks the constraints imposed by maxRowLevel or maxColumnLevel for a valid gesture.
Parameters
A map of options to pass to the method.
- 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 - number
- The index where the stripe would be reparented
- reparentPosition - StripeReparentPolicy
- Where to place the stripe as a result of the gesture that would be used for the reparent operation.
Returns
- ↪boolean
true
iff the resulting nesting depth is smaller than maxRowLevel or maxColumnLevel, or if the nesting depth would not increase by the operation.
Implements
reparent
(context: IInputModeContext, stripe: IStripe, newParent: IStripe, index: number, reparentPosition: StripeReparentPolicy)Performs the actual reparenting after the reparent gesture has been finalized.
Remarks
Parameters
A map of options to pass to the method.
- 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 - number
- The index where the stripe should be inserted.
- reparentPosition - StripeReparentPolicy
- Where to place the stripe as a result of the gesture that triggered the reparent operation.
Implements
Determines whether the user may detach the given stripe from its current parent in order to reparent it.
Parameters
A map of options to pass to the method.
- 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.
Returns
- ↪boolean
- This implementation returns always
true
.