Packagecom.gestureworks.cml.elements
Classpublic class ScrollBar
InheritanceScrollBar Inheritance TouchContainer Inheritance com.gestureworks.core.TouchSprite

The ScrollBar creates an interactive scroll bar. Given a corresponding content measurement, the scroll bar shows a thumb scaled to the difference between the content and actual scroll size. The ScrollBar then dispatches position events when moved. See also: ScrollPane



Public Properties
 PropertyDefined By
 InheritedautoShuffle : Boolean
autoshuffles
TouchContainer
  buttonAlpha : Number
The color of the button's background.
ScrollBar
  buttonFill : uint
The color of the button's background.
ScrollBar
  buttonVisible : Boolean
The color of the button's background.
ScrollBar
 InheritedchildList : ChildList
Returns the object's childList.
TouchContainer
 InheritedclassName : String
sets the class name of displayobject
TouchContainer
 InheritedcloneExclusions : Vector.<String>
[read-only] Returns a list of properties to exclude when cloning this object
TouchContainer
 InheritedcmlIndex : int
Returns the index created by the CML parser.
TouchContainer
  contentHeight : Number
The height of the content that needs to be scrolled.
ScrollBar
  contentWidth : Number
The width of the content that needs to be scrolled;
ScrollBar
  cornerHeight : Number
Sets part of the corner radius for the ellipse used to round the rectangle of the thumb.
ScrollBar
  cornerWidth : Number
Sets part of the corner radius for the ellipse used to round the rectangle of the thumb.
ScrollBar
 InheriteddimensionsTo : Object
Sets the dimensions of TouchContainer to given object
TouchContainer
 InheriteddropShadow : Boolean
Sets the drop shadow effect
TouchContainer
  fill : uint
The scrollbar fill (background color).
ScrollBar
 Inheritedgroup : String
TouchContainer
  height : Number
[override]
ScrollBar
 InheritedheightPercent : Number
sets the height of the container
TouchContainer
 Inheritedid : String
Returns the object's id.
TouchContainer
  invertDrag : Boolean = false
ScrollBar
 Inheritedlayout : *
specifies the type of layout
TouchContainer
 InheritedlayoutList : Dictionary
TouchContainer
  loaded : Boolean
[read-only] Checks to see if the element is loaded.
ScrollBar
 InheritedmouseChildren : Boolean
[override] sets the mousechildren value to true or false.
TouchContainer
  movementRail : Number
ScrollBar
  orientation : String
Designates the orientation of the scrollbar, "horizontal" or "vertical"
ScrollBar
 InheritedpaddingBottom : Number
Sets the number of pixels between the container's bottom border and the bottom of its content area.
TouchContainer
 InheritedpaddingLeft : Number
Sets the number of pixels between the component's left border and the left edge of its content area.
TouchContainer
 InheritedpaddingRight : Number
Sets the number of pixels between the component's right border and the right edge of its content area.
TouchContainer
 InheritedpaddingTop : Number
Sets the number of pixels between the container's top border and the top of its content area.
TouchContainer
 Inheritedposition : *
Sets the position
TouchContainer
  railGraphic : Graphic
ScrollBar
  railShape : String
Sets the shape of the rail grpahic, either "rectangle" or "roundRectangle".
ScrollBar
  railTouch : TouchContainer
ScrollBar
 InheritedrelativeX : Boolean
When set true this containers children's x position will be laid out relatively to each other.
TouchContainer
 InheritedrelativeY : Boolean
When set true this containers children's y position will be laid out relatively to each other.
TouchContainer
  scrollBtn1 : Graphic
ScrollBar
  scrollBtn2 : Graphic
ScrollBar
  scrollPosition : Number
The position of the scroll thumb on the rail.
ScrollBar
  shape : String
Sets the shape of the thumb, either "rectangle", or "roundRectangle".
ScrollBar
 Inheritedsound : String
TouchContainer
 Inheritedstate : Dictionary
TouchContainer
 InheritedstateId : *
Returns the current state id.
TouchContainer
  thumb : Graphic
ScrollBar
  thumbFill : uint
The color of the central thumb that slides up and down the scrollbar.
ScrollBar
  thumbMin : Number
The minimum size the thumb of the scroll bar can reach.
ScrollBar
  thumbPosition : Number
[write-only] This sets the thumbPosition, this is not to be accessed externally in CML or used in Actionscript, it is solely here for the ScrollPane class to reach when content is dragged.
ScrollBar
  thumbTouch : TouchContainer
ScrollBar
 InheritedtoBitmap : Boolean
TouchContainer
  touchBtn1 : TouchContainer
ScrollBar
  touchBtn2 : TouchContainer
ScrollBar
  width : Number
[override]
ScrollBar
 InheritedwidthPercent : Number
sets the width of the container
TouchContainer
Protected Properties
 PropertyDefined By
 InheritedcmlGestureList : Object
TouchContainer
Public Methods
 MethodDefined By
  
Constructor
ScrollBar
 Inherited
TouchContainer
 Inherited
method searches the child and adds to the list
TouchContainer
 Inherited
addChild(child:DisplayObject):DisplayObject
[override] Adds child to display list and, if not already added, the child list
TouchContainer
 Inherited
addChildAt(child:DisplayObject, index:int):DisplayObject
[override] Adds child to display list and, if not already added, the child list
TouchContainer
 Inherited
applyLayout(value:* = null):void
Apply the containers layout
TouchContainer
 Inherited
childToList(id:String, child:*):void
child appended to the childlist
TouchContainer
  
clone():*
[override]
ScrollBar
  
ScrollBar
  
dispose():void
[override] Destructor
ScrollBar
 Inherited
getElementById(id:String):*
Searches CML childList by id.
TouchContainer
 Inherited
getElementsByClassName(className:String):Array
Searches the CML childList by className.
TouchContainer
 Inherited
getElementsByTagName(tagName:Class):Array
Searches the CML childList by tagName as Class.
TouchContainer
  
init():void
[override] Initialisation method
ScrollBar
 Inherited
loadState(sId:* = null, recursion:Boolean = false):void
Loads state by index number.
TouchContainer
 Inherited
makeGestureList(value:XMLList):Object
Creates gestureList object from XML
TouchContainer
  
onDrag(e:GWGestureEvent):void
ScrollBar
 Inherited
parseCML(cml:XMLList):XMLList
Parse cml for local layouts.
TouchContainer
 Inherited
postparseCML(cml:XMLList):void
Abstract method allows the setting of a postparse CML routine.
TouchContainer
 Inherited
querySelector(selector:String):*
Searches the CML childList by selector.
TouchContainer
 Inherited
querySelectorAll(selector:*):Array
Search the CML childList by selector.
TouchContainer
 Inherited
removeChild(child:DisplayObject):DisplayObject
[override] Removes child from display list and, if not already removed, the child list
TouchContainer
 Inherited
removeChildAt(index:int):DisplayObject
[override] Removes child from display list and, if not already removed, the child list
TouchContainer
 Inherited
removeChildren(beginIndex:int = 0, endIndex:int = 2147483647):void
[override] Removes children from display list and, if not already removed, the child list
TouchContainer
  
reset():void
ScrollBar
  
resize(newDimension:Number):void
Used by the ScrollPane class to resize the scrollbar when scrollable content is scaled larger or smaller.
ScrollBar
 Inherited
saveState(sId:* = null, recursion:Boolean = false):void
Save state by index number.
TouchContainer
 Inherited
searchChildren(value:*, returnType:Class = null):*
This method does a depth first search of childLists.
TouchContainer
 Inherited
method sets the dimensions of each child
TouchContainer
 Inherited
tweenState(sId:* = null, tweenTime:Number = 1):void
Tween state by stateIndex from current to given state index.
TouchContainer
 Inherited
Updates child padding within this container
TouchContainer
 Inherited
Updates child percent dimensions within this container
TouchContainer
 Inherited
updateProperties(state:* = 0):void
Updates properties from state.
TouchContainer
 Inherited
Updates child relative positions within this container
TouchContainer
Property Detail
buttonAlphaproperty
buttonAlpha:Number

The color of the button's background.


Implementation
    public function get buttonAlpha():Number
    public function set buttonAlpha(value:Number):void
buttonFillproperty 
buttonFill:uint

The color of the button's background.


Implementation
    public function get buttonFill():uint
    public function set buttonFill(value:uint):void
buttonVisibleproperty 
buttonVisible:Boolean

The color of the button's background.


Implementation
    public function get buttonVisible():Boolean
    public function set buttonVisible(value:Boolean):void
contentHeightproperty 
contentHeight:Number

The height of the content that needs to be scrolled.


Implementation
    public function get contentHeight():Number
    public function set contentHeight(value:Number):void
contentWidthproperty 
contentWidth:Number

The width of the content that needs to be scrolled;


Implementation
    public function get contentWidth():Number
    public function set contentWidth(value:Number):void
cornerHeightproperty 
cornerHeight:Number

Sets part of the corner radius for the ellipse used to round the rectangle of the thumb. Shape must be "roundRectangle" for this to be used.

The default value is 10.


Implementation
    public function get cornerHeight():Number
    public function set cornerHeight(value:Number):void
cornerWidthproperty 
cornerWidth:Number

Sets part of the corner radius for the ellipse used to round the rectangle of the thumb. Shape must be "roundRectangle" for this to be used.

The default value is 10.


Implementation
    public function get cornerWidth():Number
    public function set cornerWidth(value:Number):void
fillproperty 
fill:uint

The scrollbar fill (background color).


Implementation
    public function get fill():uint
    public function set fill(value:uint):void
heightproperty 
height:Number[override]


Implementation
    public function get height():Number
    public function set height(value:Number):void
invertDragproperty 
public var invertDrag:Boolean = false

loadedproperty 
loaded:Boolean  [read-only]

Checks to see if the element is loaded. Setter is only for cloning to be available to set a scrollbar is loaded, do not set this variable.


Implementation
    public function get loaded():Boolean
movementRailproperty 
public var movementRail:Number

orientationproperty 
orientation:String

Designates the orientation of the scrollbar, "horizontal" or "vertical"

The default value is vertical.


Implementation
    public function get orientation():String
    public function set orientation(value:String):void
railGraphicproperty 
public var railGraphic:Graphic

railShapeproperty 
railShape:String

Sets the shape of the rail grpahic, either "rectangle" or "roundRectangle".


Implementation
    public function get railShape():String
    public function set railShape(value:String):void
railTouchproperty 
public var railTouch:TouchContainer

scrollBtn1property 
public var scrollBtn1:Graphic

scrollBtn2property 
public var scrollBtn2:Graphic

scrollPositionproperty 
scrollPosition:Number

The position of the scroll thumb on the rail. This is to dispatch events to the ScrollPane class to set the position of the content, it should not be accessed externally.


Implementation
    public function get scrollPosition():Number
    public function set scrollPosition(value:Number):void
shapeproperty 
shape:String

Sets the shape of the thumb, either "rectangle", or "roundRectangle".

The default value is roundRectangle.


Implementation
    public function get shape():String
    public function set shape(value:String):void
thumbproperty 
public var thumb:Graphic

thumbFillproperty 
thumbFill:uint

The color of the central thumb that slides up and down the scrollbar. If no color is set, it will default to match the button styles.


Implementation
    public function get thumbFill():uint
    public function set thumbFill(value:uint):void
thumbMinproperty 
thumbMin:Number

The minimum size the thumb of the scroll bar can reach.

The default value is 30.


Implementation
    public function get thumbMin():Number
    public function set thumbMin(value:Number):void
thumbPositionproperty 
thumbPosition:Number  [write-only]

This sets the thumbPosition, this is not to be accessed externally in CML or used in Actionscript, it is solely here for the ScrollPane class to reach when content is dragged.


Implementation
    public function set thumbPosition(value:Number):void
thumbTouchproperty 
public var thumbTouch:TouchContainer

touchBtn1property 
public var touchBtn1:TouchContainer

touchBtn2property 
public var touchBtn2:TouchContainer

widthproperty 
width:Number[override]


Implementation
    public function get width():Number
    public function set width(value:Number):void
Constructor Detail
ScrollBar()Constructor
public function ScrollBar()

Constructor

Method Detail
clone()method
override public function clone():*

Returns
*
createEvents()method 
public function createEvents():void

dispose()method 
override public function dispose():void

Destructor

init()method 
override public function init():void

Initialisation method

onDrag()method 
public function onDrag(e:GWGestureEvent):void

Parameters

e:GWGestureEvent

reset()method 
public function reset():void

resize()method 
public function resize(newDimension:Number):void

Used by the ScrollPane class to resize the scrollbar when scrollable content is scaled larger or smaller.

Parameters

newDimension:Number