Adding a pinch handler for multi-touch devices. Great patch from Bruno. p=bbinet, r=me (closes #3077)
git-svn-id: http://svn.openlayers.org/trunk/openlayers@11389 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
@@ -104,6 +104,20 @@ OpenLayers.Event = {
|
||||
return event.touches && event.touches.length == 1;
|
||||
},
|
||||
|
||||
/**
|
||||
* Method: isMultiTouch
|
||||
* Determine whether event was caused by a multi touch
|
||||
*
|
||||
* Parameters:
|
||||
* event - {Event}
|
||||
*
|
||||
* Returns:
|
||||
* {Boolean}
|
||||
*/
|
||||
isMultiTouch: function(event) {
|
||||
return event.touches && event.touches.length > 1;
|
||||
},
|
||||
|
||||
/**
|
||||
* Method: isLeftClick
|
||||
* Determine whether event was caused by a left click.
|
||||
|
||||
Reference in New Issue
Block a user