Packageorg.apache.flex.events
Classpublic class DragEvent
InheritanceDragEvent Inheritance DragEventBase Inheritance MouseEvent Inheritance flash.events.MouseEvent

Language Version : ActionScript 3.0
Product Version : FlexJS 0.0
Runtime Versions : Flash Player 10.2, AIR 2.6

Drag and Drop Events.



Public Properties
 PropertyDefined By
 InheritedclientX : Number
MouseEvent
 InheritedclientY : Number
MouseEvent
  dragInitiator : IDragInitiator
[static] The object that wants to know if a drop is accepted
DragEvent
  dragSource : Object
[static] The data being dragged.
DragEvent
 InheritedscreenX : Number
[read-only]
MouseEvent
 InheritedscreenY : Number
[read-only]
MouseEvent
Public Methods
 MethodDefined By
  
DragEvent(type:String, bubbles:Boolean = false, cancelable:Boolean = false)
Constructor.
DragEvent
  
[static] Factory for DragEvents.
DragEvent
  
[static] Dispatch a DragEvent
DragEvent
Public Constants
 ConstantDefined By
 InheritedCLICK : String = click
[static]
MouseEvent
 InheritedDOUBLE_CLICK : String = doubleClick
[static]
MouseEvent
  DRAG_DROP : String = dragDrop
[static] The DragEvent.DRAG_DROP constant defines the value of the event object's type property for a dragDrop event.
DragEvent
  DRAG_END : String = dragEnd
[static] The DragEvent.DRAG_END constant defines the value of the event object's type property for a dragEnd event.
DragEvent
  DRAG_ENTER : String = dragEnter
[static] The DragEvent.DRAG_ENTER constant defines the value of the event object's type property for a dragEnter event.
DragEvent
  DRAG_EXIT : String = dragExit
[static] The DragEvent.DRAG_EXIT constant defines the value of the event object's type property for a dragExit event.
DragEvent
  DRAG_MOVE : String = dragMove
[static] The DragEvent.DRAG_MOVE constant defines the value of the event object's type property for a dragMove event.
DragEvent
  DRAG_OVER : String = dragOver
[static] The DragEvent.DRAG_OVER constant defines the value of the event object's type property for a dragOver event.
DragEvent
  DRAG_START : String = dragStart
[static] The DragEvent.DRAG_START constant defines the value of the event object's type property for a dragStart event.
DragEvent
 InheritedMOUSE_DOWN : String
[static]
MouseEvent
 InheritedMOUSE_MOVE : String
[static]
MouseEvent
 InheritedMOUSE_OUT : String
[static]
MouseEvent
 InheritedMOUSE_OVER : String
[static]
MouseEvent
 InheritedMOUSE_UP : String
[static]
MouseEvent
 InheritedROLL_OUT : String
[static]
MouseEvent
 InheritedROLL_OVER : String
[static]
MouseEvent
Property Detail
dragInitiatorproperty
public static var dragInitiator:IDragInitiator

Language Version : ActionScript 3.0
Product Version : FlexJS 0.0
Runtime Versions : Flash Player 10.2, AIR 2.6

The object that wants to know if a drop is accepted

dragSourceproperty 
public static var dragSource:Object

Language Version : ActionScript 3.0
Product Version : FlexJS 0.0
Runtime Versions : Flash Player 10.2, AIR 2.6

The data being dragged. Or an instance of an object describing the data.

Constructor Detail
DragEvent()Constructor
public function DragEvent(type:String, bubbles:Boolean = false, cancelable:Boolean = false)

Language Version : ActionScript 3.0
Product Version : FlexJS 0.0
Runtime Versions : Flash Player 10.2, AIR 2.6

Constructor. Do not call 'new DragEvent', use the createDragEvent method instead.

Parameters
type:String — The name of the event.
 
bubbles:Boolean (default = false) — Whether the event bubbles.
 
cancelable:Boolean (default = false) — Whether the event can be canceled.
Method Detail
createDragEvent()method
public static function createDragEvent(type:String, event:MouseEvent):DragEvent

Language Version : ActionScript 3.0
Product Version : FlexJS 0.0
Runtime Versions : Flash Player 10.2, AIR 2.6

Factory for DragEvents.

Parameters

type:String — The name of the event.
 
event:MouseEvent — The MouseEvent properties to copy into the DragEvent.

Returns
DragEvent — The new DragEvent.
dispatchDragEvent()method 
public static function dispatchDragEvent(event:DragEvent, target:IEventDispatcher):void

Language Version : ActionScript 3.0
Product Version : FlexJS 0.0
Runtime Versions : Flash Player 10.2, AIR 2.6

Dispatch a DragEvent

Parameters

event:DragEvent — The DragEvent to dispatch.
 
target:IEventDispatcher — The target to dispatch the event from.

Constant Detail
DRAG_DROPConstant
public static const DRAG_DROP:String = dragDrop

Language Version : ActionScript 3.0
Product Version : Flex 3
Runtime Versions : Flash Player 9, AIR 1.1

The DragEvent.DRAG_DROP constant defines the value of the event object's type property for a dragDrop event.

The properties of the event object have the following values:

PropertyValue
bubblesfalse
cancelablefalse
currentTargetThe Object that defines the event listener that handles the event. For example, if you use myButton.addEventListener() to register an event listener, myButton is the value of the currentTarget.
targetThe Object that dispatched the event; it is not always the Object listening for the event. Use the currentTarget property to always access the Object listening for the event.

DRAG_ENDConstant 
public static const DRAG_END:String = dragEnd

Language Version : ActionScript 3.0
Product Version : Flex 3
Runtime Versions : Flash Player 9, AIR 1.1

The DragEvent.DRAG_END constant defines the value of the event object's type property for a dragEnd event.

The properties of the event object have the following values:

PropertyValue
bubblesfalse
cancelablefalse
currentTargetThe Object that defines the event listener that handles the event. For example, if you use myButton.addEventListener() to register an event listener, myButton is the value of the currentTarget.
targetThe Object that dispatched the event; it is not always the Object listening for the event. Use the currentTarget property to always access the Object listening for the event.

DRAG_ENTERConstant 
public static const DRAG_ENTER:String = dragEnter

Language Version : ActionScript 3.0
Product Version : Flex 3
Runtime Versions : Flash Player 9, AIR 1.1

The DragEvent.DRAG_ENTER constant defines the value of the event object's type property for a dragEnter event.

The properties of the event object have the following values:

PropertyValue
bubblesfalse
cancelablefalse
currentTargetThe Object that defines the event listener that handles the event. For example, if you use myButton.addEventListener() to register an event listener, myButton is the value of the currentTarget.
targetThe Object that dispatched the event; it is not always the Object listening for the event. Use the currentTarget property to always access the Object listening for the event.

DRAG_EXITConstant 
public static const DRAG_EXIT:String = dragExit

Language Version : ActionScript 3.0
Product Version : Flex 3
Runtime Versions : Flash Player 9, AIR 1.1

The DragEvent.DRAG_EXIT constant defines the value of the event object's type property for a dragExit event.

The properties of the event object have the following values:

PropertyValue
bubblesfalse
cancelablefalse
currentTargetThe Object that defines the event listener that handles the event. For example, if you use myButton.addEventListener() to register an event listener, myButton is the value of the currentTarget.
targetThe Object that dispatched the event; it is not always the Object listening for the event. Use the currentTarget property to always access the Object listening for the event.

DRAG_MOVEConstant 
public static const DRAG_MOVE:String = dragMove

Language Version : ActionScript 3.0
Product Version : Flex 3
Runtime Versions : Flash Player 9, AIR 1.1

The DragEvent.DRAG_MOVE constant defines the value of the event object's type property for a dragMove event.

The properties of the event object have the following values:

PropertyValue
bubblesfalse
cancelablefalse
currentTargetThe Object that defines the event listener that handles the event. For example, if you use myButton.addEventListener() to register an event listener, myButton is the value of the currentTarget.
targetThe Object that dispatched the event; it is not always the Object listening for the event. Use the currentTarget property to always access the Object listening for the event.

DRAG_OVERConstant 
public static const DRAG_OVER:String = dragOver

Language Version : ActionScript 3.0
Product Version : Flex 3
Runtime Versions : Flash Player 9, AIR 1.1

The DragEvent.DRAG_OVER constant defines the value of the event object's type property for a dragOver event.

The properties of the event object have the following values:

PropertyValue
bubblesfalse
cancelablefalse
currentTargetThe Object that defines the event listener that handles the event. For example, if you use myButton.addEventListener() to register an event listener, myButton is the value of the currentTarget.
targetThe Object that dispatched the event; it is not always the Object listening for the event. Use the currentTarget property to always access the Object listening for the event.

DRAG_STARTConstant 
public static const DRAG_START:String = dragStart

Language Version : ActionScript 3.0
Product Version : Flex 3
Runtime Versions : Flash Player 9, AIR 1.1

The DragEvent.DRAG_START constant defines the value of the event object's type property for a dragStart event.

The properties of the event object have the following values:

PropertyValue
bubblesfalse
cancelablefalse
currentTargetThe Object that defines the event listener that handles the event. For example, if you use myButton.addEventListener() to register an event listener, myButton is the value of the currentTarget.
targetThe Object that dispatched the event; it is not always the Object listening for the event. Use the currentTarget property to always access the Object listening for the event.