android Programming Glossary: ispinch
How do I respond to a tap on an Android MapView, but ignore pinch-zoom? http://stackoverflow.com/questions/4806061/how-do-i-respond-to-a-tap-on-an-android-mapview-but-ignore-pinch-zoom this one is working well so far. The code follows the motion events. When we get an ACTION_DOWN event it marks the isPinch flag as false we don't know if it's a pinch or not yet but as soon as we get a touch event i.e. ACTION_MOVE involving two.. we don't know if it's a pinch or not yet but as soon as we get a touch event i.e. ACTION_MOVE involving two fingers isPinch is set to true and so when the onTap event fires it can see if there was a pinch or not. class MapOverlay extends com.google.android.maps.Overlay.. fires it can see if there was a pinch or not. class MapOverlay extends com.google.android.maps.Overlay private boolean isPinch false @Override public boolean onTap GeoPoint p MapView map if isPinch return false else Log.i TAG TAP if p null handleGeoPoint..
|