PXTouchEvent Class Reference
| Inherits from | PXEvent : NSObject |
| Conforms to | NSCopying PXPooledObject |
| Declared in | PXTouchEvent.h PXTouchEvent.m |
Overview
Dispatched by subclasses of PXInteractiveObject an associated touch begins, ends, moves, or cancels. The event has information needed by the user to handle the touch correctly.
Tasks
-
nativeTouchThe touch object used for keeping track of what finger started the touch.
property -
capturedIndicates if the touch which triggered this event has been captured by the target. The object which captured the event will usually be a PXInteractiveObject for which the [PXInteractiveObject captureTouches] property has been set to
propertyYES. If captured equalsYES, the [PXTouchEvent target] property will represent the object which captured this touch. -
insideTargetReturns
propertyYESif the touch is contained within the bounds of the target. -
stageXThe horizontal location in global (stage) coordinates where the touch occured.
property -
stageYThe vertical location in global (stage) coordinates where the touch occured.
property -
localXThe horizontal location in local (target) coordinates where the touch occured.
property -
localYThe vertical location in local (target) coordinates where the touch occured.
property -
stagePositionThe location in global (stage) coordinates where the touch occured.
property -
localPositionThe location in local (target) coordinates where the touch occured.
property -
tapCountThe number of touches that have been repeated in the same place without moving.
property -
– initWithType:nativeTouch:stageX:stageY:tapCount:Creates a touch event.
Properties
captured
Indicates if the touch which triggered this event has been captured by the
target. The object which captured the event will usually be a
PXInteractiveObject for which the [PXInteractiveObject captureTouches]
property has been set to YES. If captured equals
YES, the [PXTouchEvent target] property will represent the
object which captured this touch.
@property (nonatomic, readonly) BOOL capturedDeclared In
PXTouchEvent.hinsideTarget
Returns YES if the touch is contained within the bounds of the
target.
@property (nonatomic, readonly) BOOL insideTargetDeclared In
PXTouchEvent.hlocalPosition
The location in local (target) coordinates where the touch occured.
@property (nonatomic, readonly) PXPoint *localPositionDeclared In
PXTouchEvent.hlocalX
The horizontal location in local (target) coordinates where the touch occured.
@property (nonatomic, readonly) float localXDeclared In
PXTouchEvent.hlocalY
The vertical location in local (target) coordinates where the touch occured.
@property (nonatomic, readonly) float localYDeclared In
PXTouchEvent.hnativeTouch
The touch object used for keeping track of what finger started the touch.
@property (nonatomic, readonly) UITouch *nativeTouchDeclared In
PXTouchEvent.hstagePosition
The location in global (stage) coordinates where the touch occured.
@property (nonatomic, readonly) PXPoint *stagePositionDeclared In
PXTouchEvent.hstageX
The horizontal location in global (stage) coordinates where the touch occured.
@property (nonatomic, readonly) float stageXDeclared In
PXTouchEvent.hInstance Methods
initWithType:nativeTouch:stageX:stageY:tapCount:
Creates a touch event.
- (id)initWithType:(NSString *)type nativeTouch:(UITouch *)touch stageX:(float)stageX stageY:(float)stageY tapCount:(unsigned)tapCountParameters
- type
A string representing the type of the event.
- stageX
The horizontal location in global (stage) coordinates where the touch occured.
- stageY
The vertical location in global (stage) coordinates where the touch occured.
- tapCount
The number of touches that have been repeated in the same place without moving.
- nativeTouch
The touch object used for keeping track of what finger started the touch.
Declared In
PXTouchEvent.m