An easy way to accomplish this is to use an Overlay. Something like this:
class MyOverlay extends Overlay {
public boolean onTap(GeoPoint point, MapView mapView) {
// do something with point
}
}
And elsewhere:
MyOverlay overlay = new MyOverlay();
myMapView.getOverlays().add(overlay);
You can override other methods on the Overlay, such as onTouchEvent(), to
detect other input.
Steve
On Mon, May 31, 2010 at 8:52 PM, zhou haitao <[email protected]> wrote:
> Hi!
> I want to get the point of the mapview throuth click the map.I have tried
> to use the onTouchlistener,but in this way,the map can not move,zoom.
> Please give me some idea or a sample! Thanks.
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to [email protected]
> To unsubscribe from this group, send email to
> [email protected]<android-developers%[email protected]>
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en