java android osm showInfoWindow when a marker changed possition -
i display show info window when click on marker , when update possition marker possion infowindow doesn't changed
i try :
mpin.setposition(activeitemizediconoverlay.getitem(index).getpoint());
but doen't work. :
mpin.hideinfowindow(); mapview.getoverlays().remove(mpin); mpin.setposition(activeitemizediconoverlay.getitem(0).getpoint()); mpin.showinfowindow(); mapview.getoverlays().add(mpin);
but show infowindow don't need click
try use method isinfowindowshown()
marker. , can check if infowindow show , when method return true can :
if(mpin.isinfowindowshown()){ mpin.hideinfowindow(); mapview.getoverlays().remove(mpin); mpin.setposition(activeitemizediconoverlay.getitem(0).getpoint()); mpin.showinfowindow(); mapview.getoverlays().add(mpin); }
Comments
Post a Comment