Skip to content
This repository has been archived by the owner on Nov 30, 2018. It is now read-only.

[r1-dev] markers directive will destroy all markers and reinsert all of them when models property change #108

Closed
fwitzke opened this issue Aug 20, 2013 · 3 comments

Comments

@fwitzke
Copy link
Contributor

fwitzke commented Aug 20, 2013

I'm using the markers directive with doCluster="true". The current handling for models change is deleting all the current markers and adding them again.

The problem is that if I have a marker with an open infoWindow, when I add another marker to the map (or remove an existing one), all markers will be deleted and re-inserted, meaning the infoWindow state will be lost and the window will be closed.

@nmccready
Copy link
Contributor

Are you using Windows or Window? I would suggest using Window and track an active marker, within an active markers array. This also allows for a much smaller memory foot print as you will only use windows that your need.

See here #83 and look 5 days back for the comment that starts with ( epiphany! ) .

@fwitzke
Copy link
Contributor Author

fwitzke commented Aug 20, 2013

I was using Windows directive.
Your suggestion works fine, I can close the issue if you think it's ok the way it is.

Thanks so much!

@nmccready
Copy link
Contributor

np Windows will probably be going away soon.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants