Difference between revisions of "Event.TOUCHES CANCEL"

From GiderosMobile
Line 3: Line 3:
 
'''Value:''' touchesCancel<br/>
 
'''Value:''' touchesCancel<br/>
 
=== Description ===
 
=== Description ===
This event is dispatched when touch is interrupted, for example, by a phone call, or any sort of modal dialog.
+
<translate>This event is dispatched when touch is interrupted, for example, by a phone call, or any sort of modal dialog.
 
This event is dispatched only on devices.
 
This event is dispatched only on devices.
  
 
Modifiers can have values of:
 
Modifiers can have values of:
`KeyCode.MODIFIER_NONE`
+
[[[KeyCode.MODIFIER_NONE]]]
`KeyCode.MODIFIER_SHIFT`
+
[[[KeyCode.MODIFIER_SHIFT]]]
`KeyCode.MODIFIER_CTRL`
+
[[[KeyCode.MODIFIER_CTRL]]]
`KeyCode.MODIFIER_ALT`
+
[[[KeyCode.MODIFIER_ALT]]]
`KeyCode.MODIFIER_META`
+
[[[KeyCode.MODIFIER_META]]]</translate>
 
=== Parameters ===
 
=== Parameters ===
'''touch.x''': (number) x coordinate of the current touch<br/>
+
'''touch.x''': (number) <translate>x coordinate of the current touch</translate><br/>
'''touch.y''': (number) y coordinate of the current touch<br/>
+
'''touch.y''': (number) <translate>y coordinate of the current touch</translate><br/>
'''touch.rx''': (number) unrounded x coordinate of the touch<br/>
+
'''touch.rx''': (number) <translate>unrounded x coordinate of the touch</translate><br/>
'''touch.ry''': (number) unrounded y coordinate of the touch<br/>
+
'''touch.ry''': (number) <translate>unrounded y coordinate of the touch</translate><br/>
'''touch.id''': (number) the id of current touch. This number is 1 if this is a first touch, 2 if it is a second, etc.<br/>
+
'''touch.id''': (number) <translate>the id of current touch. This number is 1 if this is a first touch, 2 if it is a second, etc.</translate><br/>
'''touch.type''': (string) Input type, possible values: finger, pen, mouse, penTablet<br/>
+
'''touch.type''': (string) <translate>Input type, possible values: finger, pen, mouse, penTablet</translate><br/>
'''touch.pressure''': (number) Pressure on screen, 0 if not able to detect<br/>
+
'''touch.pressure''': (number) <translate>Pressure on screen, 0 if not able to detect</translate><br/>
'''touch.mouseButton''': (number) Mouse button which triggered this event, if any<br/>
+
'''touch.mouseButton''': (number) <translate>Mouse button which triggered this event, if any</translate><br/>
'''touch.modifiers''': (number) Modifiers present<br/>
+
'''touch.modifiers''': (number) <translate>Modifiers present</translate><br/>
'''allTouches''': (table) lua table containing previously described touch table with x, y, rx, ry and id properties for all touches that are currently on device.<br/>
+
'''allTouches''': (table) <translate>lua table containing previously described touch table with x, y, rx, ry and id properties for all touches that are currently on device.</translate><br/>

Revision as of 14:34, 23 August 2018

Available since: Gideros 2011.6
Value: touchesCancel

Description

This event is dispatched when touch is interrupted, for example, by a phone call, or any sort of modal dialog. This event is dispatched only on devices.

Modifiers can have values of: [[[KeyCode.MODIFIER_NONE]]] [[[KeyCode.MODIFIER_SHIFT]]] [[[KeyCode.MODIFIER_CTRL]]] [[[KeyCode.MODIFIER_ALT]]] [[[KeyCode.MODIFIER_META]]]

Parameters

touch.x: (number) x coordinate of the current touch
touch.y: (number) y coordinate of the current touch
touch.rx: (number) unrounded x coordinate of the touch
touch.ry: (number) unrounded y coordinate of the touch
touch.id: (number) the id of current touch. This number is 1 if this is a first touch, 2 if it is a second, etc.
touch.type: (string) Input type, possible values: finger, pen, mouse, penTablet
touch.pressure: (number) Pressure on screen, 0 if not able to detect
touch.mouseButton: (number) Mouse button which triggered this event, if any
touch.modifiers: (number) Modifiers present
allTouches: (table) lua table containing previously described touch table with x, y, rx, ry and id properties for all touches that are currently on device.