Maps SDK for Web

tt.TouchZoomRotateHandler

The TouchZoomRotateHandler allows the user to zoom and rotate the map by pinching on a touchscreen.

Methods

disable( )

Disables the 'pinch to rotate and zoom' interaction.

disableRotation( )

Disables the 'pinch to rotate' interaction, leaving the 'pinch to zoom' interaction enabled.

enable([options])

Enables the 'pinch to rotate and zoom' interaction.

Example
map.touchZoomRotate.enable();
map.touchZoomRotate.enable({ around: 'center' });
Parameters
Name Description
options
Object
default:None
Object with options
options.around
String
default:None
If 'center' is passed, map will zoom around center of map

enableRotation( )

Enables the 'pinch to rotate' interaction.

isEnabled( ): Boolean

Returns a Boolean indicating whether the 'pinch to rotate and zoom' interaction is enabled.

Returns

true if the 'pinch to rotate and zoom' interaction is enabled.