aboutsummaryrefslogtreecommitdiffstats
path: root/main/src/cgeo/geocaching/cgCache.java
diff options
context:
space:
mode:
Diffstat (limited to 'main/src/cgeo/geocaching/cgCache.java')
-rw-r--r--main/src/cgeo/geocaching/cgCache.java19
1 files changed, 17 insertions, 2 deletions
diff --git a/main/src/cgeo/geocaching/cgCache.java b/main/src/cgeo/geocaching/cgCache.java
index 220f2fa..fe15c41 100644
--- a/main/src/cgeo/geocaching/cgCache.java
+++ b/main/src/cgeo/geocaching/cgCache.java
@@ -55,7 +55,7 @@ public class cgCache implements ICache {
private String ownerReal = "";
private Date hidden = null;
private String hint = "";
- private CacheSize size = null;
+ private CacheSize size = CacheSize.UNKNOWN;
private float difficulty = 0;
private float terrain = 0;
private Float direction = null;
@@ -87,6 +87,7 @@ public class cgCache implements ICache {
private List<cgTrackable> inventory = null;
private Map<LogType, Integer> logCounts = new HashMap<LogType, Integer>();
private boolean logOffline = false;
+ private boolean userModifiedCoords = false;
// temporary values
private boolean statusChecked = false;
private boolean statusCheckedView = false;
@@ -166,7 +167,7 @@ public class cgCache implements ICache {
if (StringUtils.isBlank(hint)) {
hint = other.hint;
}
- if (size == null) {
+ if (size == null || CacheSize.UNKNOWN == size) {
size = other.size;
}
if (difficulty == 0) {
@@ -240,6 +241,12 @@ public class cgCache implements ICache {
if (logCounts.size() == 0) {
logCounts = other.logCounts;
}
+ if (userModifiedCoords == false) {
+ userModifiedCoords = other.userModifiedCoords;
+ }
+ if (reliableLatLon == false) {
+ reliableLatLon = other.reliableLatLon;
+ }
return isEqualTo(other);
}
@@ -1082,6 +1089,14 @@ public class cgCache implements ICache {
return CollectionUtils.isNotEmpty(waypoints);
}
+ public boolean hasUserModifiedCoords() {
+ return userModifiedCoords;
+ }
+
+ public void setUserModifiedCoords(boolean coordsChanged) {
+ this.userModifiedCoords = coordsChanged;
+ }
+
/**
* @param index
* @return <code>true</code>, if the waypoint was duplicated