DragEventArgs Class Reference

Drag event argument. More...

Inheritance diagram for DragEventArgs:
GestureEventArgs

List of all members.

Public Member Functions

 DragEventArgs (Widget source, Vector2 worldPosition, Vector2 localPosition, Vector2 distance)
 Constructor.

Properties

Vector2 WorldPosition [get, set]
 Obtains the position in the world (screen) coordinate system.
Vector2 LocalPosition [get, set]
 Obtains the position in the local coordinate system.
Vector2 Distance [get, set]
 Obtains the travel distance (vector) from the previous event.

Detailed Description

Drag event argument.


Constructor & Destructor Documentation

DragEventArgs ( Widget  source,
Vector2  worldPosition,
Vector2  localPosition,
Vector2  distance 
)

Constructor.

Parameters:
sourceEvent source widget
worldPositionPosition in the world (screen) coordinate system
localPositionPosition in the local coordinate system
distanceTravel distance

Property Documentation

Vector2 Distance [get, set]

Obtains the travel distance (vector) from the previous event.

This value is the travel distance in the horizontal and vertical directions and is not related to the DragGestureDetector.DetectDirection value. At DragStartDetected events, it is the distance from the touch-down position, and at DragDetected events, it is the distance from the touch position one frame earlier.