diff options
| -rw-r--r-- | main/res/values-fr/strings.xml | 1 | ||||
| -rw-r--r-- | main/res/values/strings.xml | 3 | ||||
| -rw-r--r-- | main/src/cgeo/geocaching/StatusFragment.java | 2 | ||||
| -rw-r--r-- | main/src/cgeo/geocaching/network/StatusUpdater.java | 9 |
4 files changed, 13 insertions, 2 deletions
diff --git a/main/res/values-fr/strings.xml b/main/res/values-fr/strings.xml index 6c58637..dc1d885 100644 --- a/main/res/values-fr/strings.xml +++ b/main/res/values-fr/strings.xml @@ -1063,6 +1063,7 @@ <string name="status_new_rc" tools:ignore="UnusedResources">Nouvelle version candidate disponible.\nCliquer pour installer.</string> <string name="status_geocaching_change" tools:ignore="UnusedResources">Des changements récents sur Geocaching.com ont cassé c:geo.\nNous sommes en train de nous en occuper.</string> <string name="status_geocaching_livemap" tools:ignore="UnusedResources">Des changements récents sur Geocaching.com ont cassé la carte active.\nNous sommes en train de nous en occuper.</string> + <string name="status_closeout_warning" tools:ignore="UnusedResources">Vous utilisez une version d\'Android inférieure à 2.1. Les futures versions de c:geo pourront ne pas être disponibles pour votre appareil.</string> <!-- text-to-speech for compass view --> <string name="tts_service">Boussole parlante</string> diff --git a/main/res/values/strings.xml b/main/res/values/strings.xml index 05cdb3d..19dbc60 100644 --- a/main/res/values/strings.xml +++ b/main/res/values/strings.xml @@ -1091,6 +1091,7 @@ <string name="status_new_rc" tools:ignore="UnusedResources">New release candidate available.\nClick to install.</string> <string name="status_geocaching_change" tools:ignore="UnusedResources">Recent changes on geocaching.com broke c:geo.\nWe are working on it, check again soon.</string> <string name="status_geocaching_livemap" tools:ignore="UnusedResources">Recent changes on geocaching.com broke the live map feature.\nWe are working on it, check again soon.</string> + <string name="status_closeout_warning" tools:ignore="UnusedResources">You appear to be using a version of Android older than 2.1. Future releases of c:geo might no longer be available for your device.</string> <!-- text-to-speech for compass view --> <string name="tts_service">Talking compass</string> @@ -1127,4 +1128,4 @@ <item quantity="other">%d days ago</item> </plurals> -</resources>
\ No newline at end of file +</resources> diff --git a/main/src/cgeo/geocaching/StatusFragment.java b/main/src/cgeo/geocaching/StatusFragment.java index 5a9a5b4..e0e714a 100644 --- a/main/src/cgeo/geocaching/StatusFragment.java +++ b/main/src/cgeo/geocaching/StatusFragment.java @@ -57,7 +57,7 @@ public class StatusFragment extends Fragment { @Override public void handleMessage(final Message msg) { final Status data = (Status) msg.obj; - updateDisplay(data != null && data.message != null ? data : null); + updateDisplay(data != null && data.message != null ? data : Status.defaultStatus()); } private void updateDisplay(final Status data) { diff --git a/main/src/cgeo/geocaching/network/StatusUpdater.java b/main/src/cgeo/geocaching/network/StatusUpdater.java index bfc77ba..d54f706 100644 --- a/main/src/cgeo/geocaching/network/StatusUpdater.java +++ b/main/src/cgeo/geocaching/network/StatusUpdater.java @@ -9,6 +9,8 @@ import cgeo.geocaching.utils.Version; import org.json.JSONException; import org.json.JSONObject; +import android.os.Build.VERSION; +import android.os.Build.VERSION_CODES; import android.os.Looper; import java.util.Locale; @@ -27,6 +29,13 @@ public class StatusUpdater extends MemorySubject<StatusUpdater.Status> implement this.icon = icon; this.url = url; } + + final static public Status closeoutStatus = + new Status("", "status_closeout_warning", "attribute_abandonedbuilding", "http://www.cgeo.org/closeout/"); + + final static public Status defaultStatus() { + return VERSION.SDK_INT < VERSION_CODES.ECLAIR_MR1 ? closeoutStatus : null; + } } @Override |
