Class: CapsuleVerticalGroup

CapsuleVerticalGroup

垂直钻石形组单元 由 GroupFactory 通过 CapsuleVertical 生成


new CapsuleVerticalGroup(configs)

Parameters:
Name Type Description
configs Capsule~CapsuleConfigs | GroupTemplate~GroupConfigs

配置

Extends

Members


_layout

Properties:
Type Description
Layout

布局对象

Inherited From:
Mixes In:

_linkStack

Properties:
Type Description
InstanceStack

连线栈

Inherited From:
Mixes In:

_stack

Properties:
Type Description
InstanceStack

对象栈

Inherited From:
Mixes In:

absolutePosition :Node~AbsolutePosition

Type:
Inherited From:

anchor :Array.<number>

Type:
  • Array.<number>
Inherited From:

height :Number

内部矩形高

Type:
  • Number
Inherited From:

instances

Properties:
Type Description
Array.<Node>

对象数组

Inherited From:
Mixes In:

Properties:
Type Description
Array.<BaseLink>

连线数组

Inherited From:
Mixes In:

width :Number

内部矩形宽

Type:
  • Number
Inherited From:

Methods


addToLinkStack(instance)

加入连线对象

Parameters:
Name Type Description
instance BaseLink

连线对象

Inherited From:
Mixes In:

addToStack(instance)

加入节点对象

Parameters:
Name Type Description
instance Node

节点对象

Inherited From:
Mixes In:

clone()

克隆当前节点.

Inherited From:
Returns:

当前节点的副本

Type
Node

initLayout(configs)

初始化布局

Parameters:
Name Type Description
configs LayoutMixin~LayoutConfigs

配置

Inherited From:
Mixes In:

initStack(configs)

初始化对象栈

Parameters:
Name Type Description
configs JflowConfigs

配置

Inherited From:
Mixes In:

interateNodeStack()

循环当前栈中节点

Properties:
Name Type Description
循环访问栈中每个节点 stackIteratorCallback
Inherited From:
Mixes In:

recalculate()

重新计算布局,相当于浏览器里面重排,并重算当前布局下的最小外接矩形

Inherited From:
Mixes In:

recalculateUp()

从当前层出发,向上层递归重排

Inherited From:
Mixes In:

reflow()

重新计算布局,相当于浏览器里面重排

Inherited From:
Mixes In:

removeFromLinkStack(target)

删除连线对象

Parameters:
Name Type Description
target Node

连线对象

Inherited From:
Mixes In:

removeFromStack(target)

删除节点对象

Parameters:
Name Type Description
target Node

节点对象

Inherited From:
Mixes In:

replaceFromStack(target, instance)

替换对象

Parameters:
Name Type Description
target Instance

被替换的对象

instance Instance

替换对象

Inherited From:
Mixes In:

resetChildrenPosition()

重置当前栈中对象的位置

Inherited From:
Mixes In:

staticCheck(instance)

布局静态检查

Parameters:
Name Type Description
instance Instance

检查单元

Inherited From:
Mixes In:
Returns:
  • 检查结果
Type
Boolean

Events


afterResolveMovingTarget

开始拖拽时,拖拽对象设置之前

Type: object
Properties:
Name Type Description
event Event

原始事件

jflow JFlow

当前JFlow对象

target Node

目标节点

Inherited From:

drop

丢在节点上事件

Type: object
Properties:
Name Type Description
event Event

原始事件

instance Object

拖动的对象

jflow JFlow

当前JFlow对象

target Node

目标节点

point Array.<number>

已经计算到绘图栈对应坐标系下的坐标

Inherited From:

instancemousemove

instance mousemove 原生事件,仅在无拖拽时触发

Type: object
Properties:
Name Type Description
event Event

原始事件

instance Node

原始事件

jflow JFlow

当前JFlow对象

Inherited From:

instancePressStart

开始拖动对象事件(就是目标对象的拖动事件,事件支持冒泡)

Type: object
Properties:
Name Type Description
event Event

原始事件

instance Node

拖动的对象

jflow JFlow

当前JFlow对象

bubbles Boolean

冒泡

Inherited From:

canvas mousemove 原生事件

Type: object
Properties:
Name Type Description
event Event

原始事件

target Node

原始事件

payload object

传入的消息

jflow JFlow

当前JFlow对象 - 当前JFlow对象

Inherited From:

pressEnd

拖动后放置到 Instance 上的事件,由被拖动到的对象触发

Type: object
Properties:
Name Type Description
event Event

原始事件

instance Node

拖动的对象

jflow JFlow

当前JFlow对象

target Instance

拖动到的对象

bubbles boolean

冒泡

Inherited From:

pressStart

开始拖动组的事件(特指lock的顶层组)

Type: object
Properties:
Name Type Description
event Event

原始事件

instance Node

拖动的对象

jflow JFlow

当前JFlow对象

Inherited From: