Package org.oscim.layers
Class MapEventLayer2
java.lang.Object
org.oscim.layers.Layer
org.oscim.layers.AbstractMapEventLayer
org.oscim.layers.MapEventLayer2
- All Implemented Interfaces:
EventListener,Map.InputListener
Changes Viewport by handling move, fling, scale, rotation and tilt gestures.
TODO rewrite using gesture primitives to build more complex gestures:
maybe something similar to this https://github.com/ucbvislab/Proton
-
Nested Class Summary
Nested classes/interfaces inherited from class org.oscim.layers.Layer
Layer.EnableHandler -
Field Summary
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidenableMove(boolean enable) voidenableRotation(boolean enable) voidenableTilt(boolean enable) voidenableZoom(boolean enable) booleanvoidonInputEvent(Event e, MotionEvent motionEvent) booleanvoidsetFixOnCenter(boolean enable) When enabled zoom- and rotation-gestures will not move the viewport.booleanbooleanMethods inherited from class org.oscim.layers.Layer
getRenderer, isEnabled, map, onDetach, setEnabled, setEnableHandler
-
Constructor Details
-
MapEventLayer2
-
-
Method Details
-
onInputEvent
- Specified by:
onInputEventin interfaceMap.InputListener
-
enableRotation
public void enableRotation(boolean enable) - Specified by:
enableRotationin classAbstractMapEventLayer
-
rotationEnabled
public boolean rotationEnabled()- Specified by:
rotationEnabledin classAbstractMapEventLayer
-
enableTilt
public void enableTilt(boolean enable) - Specified by:
enableTiltin classAbstractMapEventLayer
-
tiltEnabled
public boolean tiltEnabled()- Specified by:
tiltEnabledin classAbstractMapEventLayer
-
enableMove
public void enableMove(boolean enable) - Specified by:
enableMovein classAbstractMapEventLayer
-
moveEnabled
public boolean moveEnabled()- Specified by:
moveEnabledin classAbstractMapEventLayer
-
enableZoom
public void enableZoom(boolean enable) - Specified by:
enableZoomin classAbstractMapEventLayer
-
zoomEnabled
public boolean zoomEnabled()- Specified by:
zoomEnabledin classAbstractMapEventLayer
-
setFixOnCenter
public void setFixOnCenter(boolean enable) When enabled zoom- and rotation-gestures will not move the viewport.- Specified by:
setFixOnCenterin classAbstractMapEventLayer
-