Hide markers with favorites
This commit is contained in:
parent
8defa928b2
commit
7ab38e525f
2 changed files with 8 additions and 1 deletions
|
@ -605,6 +605,7 @@ public class FavouritesDbHelper {
|
|||
for (FavouritePoint p : gr.points) {
|
||||
p.setVisible(visible);
|
||||
}
|
||||
markersHelper.syncGroup(new MarkersSyncGroup(gr.name, gr.name, MarkersSyncGroup.FAVORITES_TYPE));
|
||||
}
|
||||
if (!group.name.equals(newName)) {
|
||||
FavoriteGroup gr = flatGroups.remove(group.name);
|
||||
|
|
|
@ -301,7 +301,12 @@ public class MapMarkersHelper {
|
|||
List<MapMarker> dbMarkers = markersDbHelper.getMarkersFromGroup(group);
|
||||
|
||||
if (group.getType() == MarkersSyncGroup.FAVORITES_TYPE) {
|
||||
List<FavouritePoint> favPoints = ctx.getFavorites().getGroup(group.name).points;
|
||||
FavouritesDbHelper.FavoriteGroup favGroup = ctx.getFavorites().getGroup(group.name);
|
||||
if (!favGroup.visible) {
|
||||
removeActiveMarkersFromSyncGroup(group.id);
|
||||
return;
|
||||
}
|
||||
List<FavouritePoint> favPoints = favGroup.points;
|
||||
for (FavouritePoint fp : favPoints) {
|
||||
LatLon fpLatLon = new LatLon(fp.getLatitude(), fp.getLongitude());
|
||||
boolean exists = false;
|
||||
|
@ -498,6 +503,7 @@ public class MapMarkersHelper {
|
|||
}
|
||||
}
|
||||
checkAndFixActiveMarkersOrderIfNeeded();
|
||||
refresh();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue