| Package | feathers.events |
| Class | public class ExclusiveTouch |
| Inheritance | ExclusiveTouch starling.events.EventDispatcher |
| Product Version : | Feathers 1.2.0 |
Due to the way that Starling's touch behavior is implemented, when objects are nested, the inner object will always have precedence. However, from a usability perspective, this is generally the expected behavior, so this restriction isn't expected to cause any issues.
| Method | Defined By | ||
|---|---|---|---|
ExclusiveTouch(stage:Stage)
Constructor. | ExclusiveTouch | ||
claimTouch(touchID:int, target:DisplayObject):Boolean
Allows a display object to claim a touch by its ID. | ExclusiveTouch | ||
disposeForStage(stage:Stage):void [static]
Disposes the exclusive touch manager for the specified stage. | ExclusiveTouch | ||
forStage(stage:Stage):ExclusiveTouch [static]
Retrieves the exclusive touch manager for the specified stage. | ExclusiveTouch | ||
getClaim(touchID:int):DisplayObject
Gets the display object that has claimed a touch with the specified
ID. | ExclusiveTouch | ||
removeClaim(touchID:int):void
Removes a claim to the touch with the specified ID. | ExclusiveTouch | ||
| Event | Summary | Defined By | ||
|---|---|---|---|---|
| Dispatched when a touch ID is claimed or a claim is removed. | ExclusiveTouch | |||
| ExclusiveTouch | () | Constructor |
public function ExclusiveTouch(stage:Stage)Constructor.
Parametersstage:Stage |
| claimTouch | () | method |
public function claimTouch(touchID:int, target:DisplayObject):Boolean
Allows a display object to claim a touch by its ID. Returns
true if the touch is claimed. Returns false
if the touch was previously claimed by another display object.
Parameters
touchID:int | |
target:DisplayObject |
Boolean |
| disposeForStage | () | method |
public static function disposeForStage(stage:Stage):voidDisposes the exclusive touch manager for the specified stage.
Parameters
stage:Stage |
| forStage | () | method |
public static function forStage(stage:Stage):ExclusiveTouchRetrieves the exclusive touch manager for the specified stage.
Parameters
stage:Stage |
ExclusiveTouch |
| getClaim | () | method |
public function getClaim(touchID:int):DisplayObject
Gets the display object that has claimed a touch with the specified
ID. If no touch claims the touch with the specified ID, returns
null.
Parameters
touchID:int |
DisplayObject |
| removeClaim | () | method |
public function removeClaim(touchID:int):voidRemoves a claim to the touch with the specified ID.
Parameters
touchID:int |
| change | Event |
starling.events.Eventstarling.events.Event.CHANGE
Dispatched when a touch ID is claimed or a claim is removed. The
data property is the touch ID.