flexlib :: library Documentation | All Packages | All Classes | Index | Frames No Frames |
ExtendedSlider

Package | flexlib.controls.sliderClasses
Class | public class ExtendedSlider
Inheritance | ExtendedSlider SliderBase mx.core.UIComponent
Subclasses | HSlider, VSlider

An extension of the base Slider class that adds a draggable region between the thumbs. <p>The user can drag the highlight space between the thumbs and it will drag each of the thumbs all at once. It also displays dataTips for all the thumbs at the same time.</p>

See also

mx.controls.sliderClasses.Slider

Public Properties
Hide Inherited Public Properties
Show Inherited Public Properties

| Property | Defined By
--- | --- | ---
|  | allowThumbOverlap : Boolean = false If set to false, then each thumb can only be moved to the edge of the adjacent thumb. | SliderBase
|  | allowTrackClick : Boolean = true Specifies whether clicking on the track will move the slider thumb. | SliderBase
|  | dataTipFormatFunction : Function Callback function that formats the data tip text. | SliderBase
|  | direction : String The orientation of the slider control. | SliderBase
|  | dragHitArea : UIComponent [read-only] | ExtendedSlider
|  | labels : Array An array of strings used for the slider labels. | SliderBase
|  | liveDragging : Boolean = false Specifies whether live dragging is enabled for the slider. | SliderBase
|  | lockRegionsWhileDragging : Boolean = false If this prperty is true then when you drag the draggable region between two thumbs the thumbs will always keep their same distance between each other, even when you drag the region to the left or right edges of the track. | ExtendedSlider
|  | maximum : Number The maximum allowed value on the slider. | SliderBase
|  | minimum : Number The minimum allowed value on the slider control. | SliderBase
|  | showDataTip : Boolean = true If set to true, show a data tip during user interaction containing the current value of the slider. | SliderBase
|  | sliderDataTipClass : Class A reference to the class to use for the data tip. | SliderBase
|  | sliderThumbClass : Class A reference to the class to use for each thumb. | SliderBase
|  | snapInterval : Number Specifies the increment value of the slider thumb as the user moves the thumb. | SliderBase
|  | thumbCount : int The number of thumbs allowed on the slider. | SliderBase
|  | tickInterval : Number The spacing of the tick marks relative to the maximum value of the control. | SliderBase
|  | tickValues : Array The positions of the tick marks on the slider. | SliderBase
|  | value : Number Contains the position of the thumb, and is a number between the minimum and maximum properties. | SliderBase
|  | values : Array An array of values for each thumb when thumbCount is greater than 1. | SliderBase

Protected Properties
Hide Inherited Protected Properties
Show Inherited Protected Properties

| Property | Defined By
--- | --- | ---
|  | highlightHitArea : UIComponent | ExtendedSlider
|  | thumbStyleFilters : Object [read-only] Set of styles to pass from the Slider to the thumbs. | SliderBase

Public Methods
Hide Inherited Public Methods
Show Inherited Public Methods

| Method | Defined By
--- | --- | ---
|  | ExtendedSlider() Constructor | ExtendedSlider
|  | getThumbAt(index:int):SliderThumb Returns the thumb object at the given index. | SliderBase
|  | setThumbValueAt(index:int, value:Number):void This method sets the value of a slider thumb, and updates the display. | SliderBase

Protected Methods
Show Inherited Protected Methods
Show Inherited Protected Methods

| Method | Defined By
--- | --- | ---
|  | createChildren():void [override] Overridden to create the draggable region and perform some initialization tasks. | ExtendedSlider
|  | measure():void [override] Calculates the amount of space that the component takes up. | SliderBase
|  | positionDataTip(thumb:Object):void [override] Overridden to allow for multiple dataTips. | ExtendedSlider
|  | updateDisplayList(unscaledWidth:Number, unscaledHeight:Number):void [override] Positions the elements of the control. | SliderBase

Events
Hide Inherited Events
Show Inherited Events

| Event | Summary | Defined By
--- | --- | --- | ---
|  | change | Dispatched when the slider changes value due to mouse or keyboard interaction. | SliderBase
|  | thumbDrag | Dispatched when the slider's thumb is pressed and then moved by the mouse. | SliderBase
|  | thumbPress | Dispatched when the slider's thumb is pressed, meaning the user presses the mouse button over the thumb. | SliderBase
|  | thumbRelease | Dispatched when the slider's thumb is released, meaning the user releases the mouse button after a thumbPress event. | SliderBase

Styles
Hide Inherited Styles
Show Inherited Styles

| Style | Description | Defined By
--- | --- | --- | ---
|  | borderColor | Type: uint Format: Color CSS Inheritance: no The color of the black section of the border. | SliderBase
|  | dataTipOffset | Type: Number Format: Length CSS Inheritance: no The offset, in pixels, of the data tip relative to the thumb. | SliderBase
|  | dataTipPrecision | Type: int CSS Inheritance: no Number of decimal places to use for the data tip text. | SliderBase
|  | dataTipStyleName | Type: String CSS Inheritance: no The name of the style declaration to use for the data tip. | SliderBase
|  | invertThumbDirection | Type: Boolean CSS Inheritance: no Invert the direction of the thumbs. | SliderBase
|  | labelOffset | Type: Number Format: Length CSS Inheritance: no The y-position offset (if direction is horizontal) or x-position offset (if direction is vertical) of the labels relative to the track. | SliderBase
|  | labelStyleName | Type: String CSS Inheritance: no The name of the style to use for the slider label. | SliderBase
|  | showTrackHighlight | Type: Boolean CSS Inheritance: no Specifies whether to enable track highlighting between thumbs (or a single thumb and the beginning of the track). | SliderBase
|  | slideDuration | Type: Number Format: Time CSS Inheritance: no Duration in milliseconds for the sliding animation when you click on the track to move a thumb. | SliderBase
|  | slideEasingFunction | Type: Function CSS Inheritance: no Tweening function used by the sliding animation when you click on the track to move a thumb. | SliderBase
|  | thumbDisabledSkin | Type: Class CSS Inheritance: no The skin for the slider thumb disabled state. | SliderBase
|  | thumbDownSkin | Type: Class CSS Inheritance: no The skin for the slider thumb down state. | SliderBase
|  | thumbOffset | Type: Number Format: Length CSS Inheritance: no The y-position offset (if direction is horizontal) or x-position offset (if direction is vertical) of the thumb relative to the track. | SliderBase
|  | thumbOverSkin | Type: Class CSS Inheritance: no The skin for the slider thumb over state. | SliderBase
|  | thumbSkin | Type: Class CSS Inheritance: no The default skin for the slider thumb. | SliderBase
|  | thumbUpSkin | Type: Class CSS Inheritance: no The skin for the slider thumb up state. | SliderBase
|  | tickColor | Type: uint Format: Color CSS Inheritance: no The color of the tick marks. | SliderBase
|  | tickLength | Type: Number Format: Length CSS Inheritance: no The length in pixels of the tick marks. | SliderBase
|  | tickOffset | Type: Number Format: Length CSS Inheritance: no The y-position offset (if direction is horizontal) or x-position offset (if direction is vertical) of the tick marks relative to the track. | SliderBase
|  | tickThickness | Type: Number Format: Length CSS Inheritance: no The thickness in pixels of the tick marks. | SliderBase
|  | trackColors | Type: Array Format: Color CSS Inheritance: no The colors of the track, as an array of two colors. | SliderBase
|  | trackHighlightSkin | Type: Class CSS Inheritance: no The skin for the slider track when it is selected. | SliderBase
|  | trackMargin | Type: Number Format: Length CSS Inheritance: no The size of the track margins, in pixels. | SliderBase
|  | trackSkin | Type: Class CSS Inheritance: no The skin for the slider track. | SliderBase

Property Detail

dragHitArea | property

`dragHitArea:UIComponent` [read-only]

Implementation
`public function get dragHitArea():UIComponent`

highlightHitArea | property |

`protected var highlightHitArea:UIComponent`

lockRegionsWhileDragging | property |

`public var lockRegionsWhileDragging:Boolean = false`

If this prperty is true then when you drag the draggable region between two thumbs the thumbs will always keep their same distance between each other, even when you drag the region to the left or right edges of the track. If set to false then when you drag the region to the edges of the track the region itself will begin to resize. It's a little hard to explain, just try it out.

Constructor Detail

ExtendedSlider | () | Constructor

`public function ExtendedSlider()`

Constructor

Method Detail

createChildren | () | method

`override protected function createChildren():void`

Overridden to create the draggable region and perform some initialization tasks.

positionDataTip | () | method |

`override protected function positionDataTip(thumb:Object):void`

Overridden to allow for multiple dataTips.

Parameters

| `thumb:Object`

Mercredi Juillet 6 2011, 09:45 PM +02:00