ActiveDen

Touch ScrollPane

Description:

Touch ScrollPane extends the default Flash ScrollPane component by adding support for the touch and throw scroll effect and thumbnail view and navigation.

You can now have a ScrollPane component with scrolling effects similar to those on mobile devices.(Please note that those components were not designed for touch Devices (iPhone, Android etc) but for computer with touch Screens (where touch functionality is similar to mouse functionality)). Simply each time you want to use the ScrollPane component instead of importing the default component import the touchScrollPane Component. All the properties remains the same except from the additional properties which control the touch and throw effect, the custom ScrollBars and the thumbnail.

As you can see from the preview file you can edit sensitivity, direction (normal or reversed) restricted or extended(listening movement in the whole stage), which ScrollBars will appear, customize the Scrollbars size, color and offset, set thumb’s size and use thumb’s navigation.

How to use:
First of all add the default ScrollPane Component from Flash’s components list to your library. Then import Touch ScrollPane’s class to your project: import.com.cyprog.touchInterface.TouchScrollPane;

and then instead of using:
myScrollPane:ScrollPane=new ScrollPane()

use:
var myScrollPane:TouchScrollPane=new TouchScrollPane();

then you can set the properties you want:
myScrollPane.sesnistivity=5;
myScrollPane.restricted=true;
myScrollPane.reversed=true;
myScrollPane.horizontalTouchScrollBar.size=4;
myScrollPane.verticalTouchScrollBar.lineColor=0x000000

Supported properties:
myScrollPane.sesnistivity - uint
myScrollPane.restricted - Boolean
myScrollPane.reversed - Boolean
myScrollPane.throwing - Boolean
myScrollPane.delay - Boolean
myScrollPane.horizontalScrollPolicy - ScrollPolicy
myScrollPane.verticalScrollPolicy - ScrollPolicy
myScrollPane.verticalTouchScrollBar.size - uint
myScrollPane.verticalTouchScrollBar.offset - uint
myScrollPane.verticalTouchScrollBar.scrollerColor - uint
myScrollPane.verticalTouchScrollBar.lineColor - uint 
myScrollPane.horizontalTouchScrollBar.size - uint
myScrollPane.horizontalTouchScrollBar.offset - uint
myScrollPane.horizontalTouchScrollBar.scrollerColor - uint
myScrollPane.horizontalTouchScrollBar.lineColor - uint
myScrollPane.thumbSize-uint
myScrollPane.thumb-MovieClip (only used to return the thumb)
myScrollPane.thumbRectBorderColor-uint
myScrollPane.thumbRectBackgroundColor-uint

TouchComponents owners:
In order to avoid using multiple files, you can override your TouchScrollBar.as class which is located at com.cyprog.utilities in TouchComponent’s directory with the class TouchScrollBar.as which you can find in TouchScrollPane’s directory (com.cyprog.utilities.TouchComponentsScrollBar). Then you can move TouchScrollPane.as from TouchScrollPane’s directory to TouchComponent’s directory and use them all together.

Other applications for Touch Devices:

by
by
by
by
by