layer.draggable.bounceOptions

Options for the spring animations when momentum runs beyond constraints.
译:当动量超出约束条件时,弹簧动画的选项。

layerA = new Layer
layerA.draggable.enabled = true

layerA.draggable.constraints =
    x: 0
    y: 0
    width: 200
    height: 200

# Define friction, tension and tolerance of bounce 
layerA.draggable.bounceOptions =
    friction: 40,
    tension: 200,
    tolerance: 0.0001

results matching ""

    No results matching ""