Issue
Is it possible to set an EventListener in a drawn Polygon in a osmdroid MapView Overlay ? I would like to print on a Overlay and after touching it I would like to change its color or handle data behind a Polygon.
For Example:
Poly1: ID = 1337, P1(0,0),P2(1,0),......,Pn(0,0)
Poly2: ID = 42 , P1(10,7),P2(18,39),......,Pn(10,7)
After touching in Poly1 I want to know aha ID 1337 is pressed. An want to change its color.
How could I implement such a behavior ?
Solution
Use this documentation to draw the polygons
Use this to listen for map clicks
Use this to determine if a touch is inside one of the polygons
I'm not sure that geometry library can run on android, so feel free to replace the third component.
EDIT:
Misread the question and associated it with google maps, sorry.
Answered By - Machinarius
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.