Skip to content

Commit

Permalink
Preserve animations when marker goes off screen, and restore if it co…
Browse files Browse the repository at this point in the history
…mes back on screen (PokemonGoF#2399)
  • Loading branch information
jjbott authored and 6iz committed Aug 3, 2016
1 parent afca7fb commit aa684ac
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions static/js/map.js
Original file line number Diff line number Diff line change
Expand Up @@ -772,7 +772,9 @@ function showInBoundsMarkers(markers) {

if (show && !markers[key].marker.getMap()) {
markers[key].marker.setMap(map);
markers[key].marker.setAnimation(markers[key].marker.oldAnimation);
} else if (!show && markers[key].marker.getMap()) {
markers[key].marker.oldAnimation = markers[key].marker.getAnimation();
markers[key].marker.setMap(null);
}
});
Expand Down

0 comments on commit aa684ac

Please sign in to comment.