Packagefl.events
Classpublic class SliderEvent
InheritanceSliderEvent Inheritance flash.events.Event

The SliderEvent class defines events that are associated with the Slider component. These include the following:

See also

SliderEventClickTarget


Public Properties
 PropertyDefined by
  clickTarget : String
[read-only] Gets a string that indicates whether the slider thumb or a slider track was pressed.
SliderEvent
  keyCode : Number
[read-only] Gets the key code for the key that was pressed to trigger the event.
SliderEvent
  triggerEvent : String
[read-only] Gets the type of device that was used to send the input.
SliderEvent
  value : Number
[read-only] Gets the new value of the slider, based on its position.
SliderEvent
Public Methods
 MethodDefined by
  
SliderEvent(type:String, value:Number, clickTarget:String, triggerEvent:String, keyCode:int = 0)
Creates a new SliderEvent object with the specified parameters.
SliderEvent
  
clone():Event
Creates a copy of the SliderEvent object and sets the value of each parameter to match the original.
SliderEvent
  
toString():String
Returns a string that contains all the properties of the SliderEvent object.
SliderEvent
Public Constants
 ConstantDefined by
  CHANGE : String = "change"
[static] Defines the value of the type property of a change event object.
SliderEvent
  THUMB_DRAG : String = "thumbDrag"
[static] Defines the value of the type property of a thumbDrag event object.
SliderEvent
  THUMB_PRESS : String = "thumbPress"
[static] Defines the value of the type property of a thumbPress event object.
SliderEvent
  THUMB_RELEASE : String = "thumbRelease"
[static] Defines the value of the type property of a thumbRelease event object.
SliderEvent
Property detail
clickTargetproperty
clickTarget:String  [read-only]

Gets a string that indicates whether the slider thumb or a slider track was pressed. A value of SliderEventClickTarget.THUMB indicates that the slider thumb was pressed; a value of SliderEventClickTarget.TRACK indicates that the slider track was pressed.

Implementation
    public function get clickTarget():String

See also

SliderEventClickTarget
keyCodeproperty 
keyCode:Number  [read-only]

Gets the key code for the key that was pressed to trigger the event. A key code is a numeric value that identifies the key that was pressed.

Implementation
    public function get keyCode():Number

See also

flash.events.KeyboardEvent.keyCode
triggerEventproperty 
triggerEvent:String  [read-only]

Gets the type of device that was used to send the input. A value of InteractionInputType.MOUSE indicates that a mouse was the source of the input; a value of InteractionInputType.KEYBOARD indicates that a keyboard was the source of the input.

Implementation
    public function get triggerEvent():String

See also

SliderEventClickTarget
valueproperty 
value:Number  [read-only]

Gets the new value of the slider, based on its position.

Implementation
    public function get value():Number
Constructor detail
SliderEvent()constructor
public function SliderEvent(type:String, value:Number, clickTarget:String, triggerEvent:String, keyCode:int = 0)

Creates a new SliderEvent object with the specified parameters.

Parameters
type:String — The event type; this value identifies the action that triggered the event.
 
value:Number — The new value of the slider.
 
clickTarget:String — Indicates whether a slider thumb or the slider track was pressed. A value of SliderEventClickTarget.THUMB indicates that the slider thumb was pressed; a value of SliderEventClickTarget.TRACK indicates that the slider track was pressed.
 
triggerEvent:String — A String that indicates the source of the input. A value of InteractionInputType.MOUSE indicates that the mouse was the source of input; a value of InteractionInputType.KEYBOARD indicates that the keyboard was the source of input.
 
keyCode:int (default = 0) — If the event was triggered by a key press, this value is the key code that identifies that key.
Method detail
clone()method
public override function clone():Event

Creates a copy of the SliderEvent object and sets the value of each parameter to match the original.

Returns
Event — A copy of the current SliderEvent instance.
toString()method 
public override function toString():String

Returns a string that contains all the properties of the SliderEvent object. The string is in the following format:

[SliderEvent type=value value=value bubbles=value cancelable=value keycode=value triggerEvent=value clickTarget=value]

Returns
String — A string representation of the SliderEvent object.
Constant detail
CHANGEconstant
public static const CHANGE:String = "change"

Defines the value of the type property of a change event object.

This event has the following properties:

PropertyValue
bubblesfalse
cancelablefalse; there is no default behavior to cancel.
clickTargetIdentifies whether the slider track or a slider thumb was pressed.
currentTargetThe object that is actively processing the event object with an event listener.
keyCodeIf the event was triggered by a key press, the code for the key that was pressed.
targetThe object that dispatched the event. The target is not always the object listening for the event. Use the currentTarget property to access the object that is listening for the event.
triggerEventThe type of device that triggered the event. A value of InteractionInputType.MOUSE indicates that a mouse was the source of input; a value of InteractionInputType.KEYBOARD indicates that a keyboard was the source of input.
valueThe value of the slider after the event.
THUMB_DRAGconstant 
public static const THUMB_DRAG:String = "thumbDrag"

Defines the value of the type property of a thumbDrag event object.

This event has the following properties:

PropertyValue
bubblesfalse
cancelablefalse; there is no default behavior to cancel.
clickTargetIdentifies whether the slider track or a slider thumb was pressed.
currentTargetThe object that is actively processing the event object with an event listener.
keyCodeIf the event was triggered by a key press, the code for the key that was pressed.
targetThe object that dispatched the event. The target is not always the object listening for the event. Use the currentTarget property to access the object that is listening for the event.
triggerEventThe type of device that triggered the event. A value of InteractionInputType.MOUSE indicates that a mouse was the source of the input; a value of InteractionInputType.KEYBOARD indicates that a keyboard was the source of the input.
valueThe value of the slider after the event.

See also

THUMB_PRESSconstant 
public static const THUMB_PRESS:String = "thumbPress"

Defines the value of the type property of a thumbPress event object.

This event has the following properties:

PropertyValue
bubblesfalse
cancelablefalse; there is no default behavior to cancel.
clickTargetIdentifies whether the slider track or a slider thumb was pressed.
currentTargetThe object that is actively processing the event object with an event listener.
keyCodeIf the event was triggered by a key press, the code for the key that was pressed.
targetThe object that dispatched the event. The target is not always the object listening for the event. Use the currentTarget property to access the object that is listening for the event.
triggerEventThe type of device that triggered the event. A value of InteractionInputType.MOUSE indicates that a mouse was the source of the input; a value of InteractionInputType.KEYBOARD indicates that a keyboard was the source of the input.
valueThe value of the slider after the event.

See also

THUMB_RELEASEconstant 
public static const THUMB_RELEASE:String = "thumbRelease"

Defines the value of the type property of a thumbRelease event object.

This event has the following properties:

PropertyValue
bubblesfalse
cancelablefalse; there is no default behavior to cancel.
clickTargetIdentifies whether the slider track or a slider thumb was pressed.
currentTargetThe object that is actively processing the event object with an event listener.
keyCodeIf the event was triggered by a key press, the code for the key that was pressed.
targetThe object that dispatched the event. The target is not always the object listening for the event. Use the currentTarget property to access the object that is listening for the event.
triggerEventThe type of device that triggered the event. A value of InteractionInputType.MOUSE indicates that a mouse was the source of the input; a value of InteractionInputType.KEYBOARD indicates that a keyboard was the source of the input.
valueThe value of the slider after the event.

See also