aboutsummaryrefslogtreecommitdiffstats
path: root/main
diff options
context:
space:
mode:
authorBananeweizen <bananeweizen@gmx.de>2013-04-24 09:27:52 +0200
committerBananeweizen <bananeweizen@gmx.de>2013-04-24 09:27:52 +0200
commit63cc0e3b6f1c7262fc6f8f0b6523d25b51716bec (patch)
treedd0b8bdda50f3ae093f5404badfdea4ae4c6b22e /main
parentf56ac826aab4fefb851f592c3e7db2a88a1b43f1 (diff)
parent2ce258172e1368a751ea27b11e3582ad4a72261c (diff)
downloadcgeo-63cc0e3b6f1c7262fc6f8f0b6523d25b51716bec.zip
cgeo-63cc0e3b6f1c7262fc6f8f0b6523d25b51716bec.tar.gz
cgeo-63cc0e3b6f1c7262fc6f8f0b6523d25b51716bec.tar.bz2
Merge remote-tracking branch 'origin/release'
Diffstat (limited to 'main')
-rw-r--r--main/src/cgeo/geocaching/ui/Formatter.java8
1 files changed, 6 insertions, 2 deletions
diff --git a/main/src/cgeo/geocaching/ui/Formatter.java b/main/src/cgeo/geocaching/ui/Formatter.java
index 412b993..92a0defc 100644
--- a/main/src/cgeo/geocaching/ui/Formatter.java
+++ b/main/src/cgeo/geocaching/ui/Formatter.java
@@ -115,7 +115,7 @@ public abstract class Formatter {
infos.add(cache.getGeocode());
}
- infos.add(Formatter.formatCacheInfoShort(cache));
+ addShortInfos(cache, infos);
if (cache.isPremiumMembersOnly()) {
infos.add(cgeoapplication.getInstance().getString(R.string.cache_premium));
@@ -128,6 +128,11 @@ public abstract class Formatter {
public static String formatCacheInfoShort(Geocache cache) {
final ArrayList<String> infos = new ArrayList<String>();
+ addShortInfos(cache, infos);
+ return StringUtils.join(infos, Formatter.SEPARATOR);
+ }
+
+ private static void addShortInfos(Geocache cache, final ArrayList<String> infos) {
if (cache.hasDifficulty()) {
infos.add("D " + String.format("%.1f", cache.getDifficulty()));
}
@@ -141,7 +146,6 @@ public abstract class Formatter {
} else if (cache.isEventCache() && cache.getHiddenDate() != null) {
infos.add(Formatter.formatShortDate(cache.getHiddenDate().getTime()));
}
- return StringUtils.join(infos, Formatter.SEPARATOR);
}
public static String formatCacheInfoHistory(Geocache cache) {