GMaps: clickable overlay markers?


Last Updated:

  1. speedracer

    speedracer Member This Topic's Starter

    Joined:
    Nov 13, 2009
    Messages:
    5
    Likes Received:
    0
    I am working on integrating gmaps in my app and I know how to add overlay with drawable markers. But does anyone know if I can have these markers be clickable within my app and when clicked bring up a specified activity within my app?
    a good example would be something like foursquare or loopt on the iphone that shows friend's avatar and when clicked it goes to their profile view within the app.

    thanks!
     

    Advertisement
  2. pmunoz

    pmunoz New Member

    Joined:
    Apr 30, 2010
    Messages:
    2
    Likes Received:
    0
    Hi speedracer,

    I'm working on the same, do you have some advance?
    Best regards,
     
  3. speedracer

    speedracer Member This Topic's Starter

    Joined:
    Nov 13, 2009
    Messages:
    5
    Likes Received:
    0

    yes, it turns out to be quite straight forward.
    Basically, what you need to do is extend ItemizedOverlay and override the onTap(int index) method to do whatever you need to do.


    ItemizedOverlay

    btw, after working with the map for while I've become pretty comfortable with it so if you have any other questions, feel free to ping me :)
     
  4. pmunoz

    pmunoz New Member

    Joined:
    Apr 30, 2010
    Messages:
    2
    Likes Received:
    0
    speedracer thanks,

    I found an example of ItemizedOverlay and it works for me.

    ;)
     

Share This Page

Loading...