Packageardisia.components.scroller
Classpublic class VScrollBar
InheritanceVScrollBar Inheritance spark.components.VScrollBar

Vertical scroll bar designed for use by the Ardisia Scroller. Extended to allow the user to control the stepSize without extending the viewport or layout.

Delegates mouse wheel handling to the Ardisia Scroller class.

This class is not designed to be used alone, without being parented by the Ardisia Scroller class.

Notes:

This extended class does not support animation for a single step. The reason is because the animation code is hidden behind private members and methods and I agree with the SDK devs that the first step should be instantaneous. The superclass handles stepping by (A) immediately changing the scroll without animation, and (B) setting a startDelay on a animation. If the mouse button is released before the delay expires, the animation is stopped before it begins. Otherwise, a single animation is started to smoothly scroll the entire viewport. On mouseup, another animation is triggered to smoothly de-accelerate the easing. This is why the stepping animation is so smooth, it is actually a single animation for the entire viewport. Lastly, (C) a final changeValueByStep() is called at the end of the animation.

The animated paging and stepping is so fast under default "repeatDelay" and "repeatInterval" styles that it is easy to not notice they are animated at all. I slowed them down a bit in the defaults.css stylesheet.

The superclass handles paging very well, so I left it alone.



Public Properties
 PropertyDefined By
  nextStepIsAnimated : Boolean
Flag that the next changeValueByStep() call is animated.
VScrollBar
  scrollStepSize : Number = 70
Number of pixels to scroll for stepping operations.
VScrollBar
Property Detail
nextStepIsAnimatedproperty
public var nextStepIsAnimated:Boolean

Flag that the next changeValueByStep() call is animated.

The default value is false.

scrollStepSizeproperty 
public var scrollStepSize:Number = 70

Number of pixels to scroll for stepping operations.

If set to 0, the scroll delta will be retrieved from the viewport.

The default value is 70.