javascript - YANDEX API Open a geopoint which is not shown -
i'm trying open balloon of geopoint not shown. official api docs says
if point show open or it's cluster balloon
but how open if it's not shown? tried scroll map it's position , open it, i'm still getting error typeerror: this._hh.getmap(...) null when opening balloon.
function bymshowpoint(pid) { var point = bymgetpoint(pid); var pstate = bymclusterer.getobjectstate(point); if (!pstate.isshown) { bymscrolltopoint(pid); } if (pstate.isclustered) { pstate.cluster.state.set('activeobject',point); pstate.cluster.balloon.open(); } else { point.balloon.open(); } }
the api doesn't allow open non-visible point's balloon if point in cluster. way i've solved (with help of yandex community) is:
open map's balloon @ point's position point's data remove point clusterer (to hide icon) on map's eventballoonclose add together removed point clusterer javascript maps yandex yandex-api
No comments:
Post a Comment