diff options
| -rw-r--r-- | main/res/values-sv/strings.xml | 22 | ||||
| -rw-r--r-- | main/src/cgeo/geocaching/cgeoimages.java | 33 | ||||
| -rw-r--r-- | main/src/cgeo/geocaching/files/FileList.java | 20 | ||||
| -rw-r--r-- | main/src/cgeo/geocaching/files/GPXParser.java | 8 | ||||
| -rw-r--r-- | tests/res/raw/geotoad.gpx | 199 | ||||
| -rw-r--r-- | tests/src/cgeo/geocaching/files/GPXParserTest.java | 10 |
6 files changed, 268 insertions, 24 deletions
diff --git a/main/res/values-sv/strings.xml b/main/res/values-sv/strings.xml index b997e90..37fe1c7 100644 --- a/main/res/values-sv/strings.xml +++ b/main/res/values-sv/strings.xml @@ -114,6 +114,8 @@ <string name="log_new_log">Logga</string> <string name="log_new_log_text">Loggtext</string> <string name="log_announcement">Kungörelse</string> + <string name="log_today">Idag</string> + <string name="log_yesterday">Igår</string> <!-- translation --> <string name="translate_to_sys_lang">Översätt till %s</string> @@ -282,7 +284,8 @@ <string name="caches_sort_rating">Betyg (GC-vote)</string> <string name="caches_sort_vote">Betyg (eget)</string> <string name="caches_sort_inventory">Antal trackable</string> - <string name="caches_sort_date_hidden">Datum</string> + <string name="caches_sort_date_hidden">Datum för utplacering</string> + <string name="caches_sort_date_logged">Datum för senaste log</string> <string name="caches_sort_finds">Antal som hittat</string> <string name="caches_sort_state">Status</string> <string name="caches_sort_storage">Tid för sparandet i enheten</string> @@ -344,6 +347,7 @@ <string name="list_dialog_rename">Byt namn</string> <!-- about --> + <string name="about_version">Version</string> <string name="about_changelog">Historik</string> <string name="about_donate">Stöd c:geo</string> <string name="about_detail">Detaljer</string> @@ -360,9 +364,9 @@ <string name="init_passvote">Lösenord</string> <string name="init_login">Testa och spara inloggning</string> <string name="init_login_popup">Inloggning</string> - <string name="init_login_popup_working">Testar inloggning mot Geocaching.com…</string> - <string name="init_login_popup_ok">Inloggning ok.</string> - <string name="init_login_popup_failed">Inloggning misslyckades.</string> + <string name="init_login_popup_working">Testar inloggning mot gc.com…</string> + <string name="init_login_popup_ok">Inloggning OK</string> + <string name="init_login_popup_failed">Inloggning misslyckades</string> <string name="init_login_popup_failed_reason">Inloggning misslyckades pga </string> <string name="init_go4cache_connect">Anslut till Go 4 Cache</string> <string name="init_twitter_authorize">Inställningar för Twitter</string> @@ -422,6 +426,7 @@ <string name="init_mapsource_select">Välj kartkälla</string> <string name="init_select_mapfile">…</string> <string name="init_maptrail">Visa spår på kartan</string> + <string name="init_share_after_export">Visa meny för att dela efter slutförd exportering</string> <string name="init_trackautovisit">Sätt trackable automatiskt till \"besök\" vid loggning av en cache</string> <string name="init_sigautoinsert">Infoga signatur automatiskt i loggar</string> <string name="init_loaddirectionimg">Ladda riktningsbild om det behövs (enbart Basic Member)</string> @@ -793,6 +798,8 @@ <string name="export_fieldnotes_onlynew">Bara sedan senaste exporteringen</string> <string name="export_fieldnotes_creating">Skapar Field Notes…</string> <string name="export_gpx">GPX</string> + <string name="export_gpx_info">GPX filen kommer att exporteras till /sdcard/gpx med datum och tid i filnamnet.</string> + <string name="export_gpx_to">Skicka exporterad GPX till</string> <!-- next things --> <string name="legal_note">För att använda tjänster hos Geocaching.com, måste regler och villkor i <a href="http://www.geocaching.com/about/termsofuse.aspx">Groundspeaks avtal</a> godkännas.</string> @@ -805,6 +812,13 @@ <string name="about_auth_1">Nedan tillåter du <b>c:geo</b> att ansluta till Twitter.</string> <string name="about_auth_2">Klicka på \"Påbörja koppling mot Twitter\" om du vill koppla ihop <b>c:geo</b> med Twitter. Twitters hemsida kommer att öppnas i en webbläsare. Logga in på den sidan och tillåt <b>c:geo</b> att ansluta till ditt konto. När du godkänt så kommer Twitter att visa en PIN kod. Kom ihåg denna PIN kod, stäng webbläsaren och skriv in PIN koden i <b>c:geo</b> och bekräfta.</string> + <!-- status --> + <string name="status_new_release">Ny officiell version finns tillgänglig.\nKlicka för att installera.</string> + <string name="status_new_nightly">Nytt nattligt bygge finns tillgängligt.\nKlicka för att installera.</string> + <string name="status_new_rc">Ny kandidat till officiellt bygge finns tillgängligt.\nKlicka för att installera.</string> + <string name="status_geocaching_change">Ändringar som gjorts på geocaching.com har gjort så att c:geo inte fungerar.\nVi jobbar för att lösa problemen, försök igen om en stund.</string> + <string name="status_geocaching_livemap">Ändringar som gjorts på geocaching.com har gjort så att Live kartan inte fungerar.\nVi jobbar för att lösa problemen, försök igen om en stund.</string> + <!-- go4cache --> <string name="go4cache_looking_around">Tittar omkring</string> <string name="go4cache_tweeting">Tweeting</string> diff --git a/main/src/cgeo/geocaching/cgeoimages.java b/main/src/cgeo/geocaching/cgeoimages.java index b2f7ad6..6de6444 100644 --- a/main/src/cgeo/geocaching/cgeoimages.java +++ b/main/src/cgeo/geocaching/cgeoimages.java @@ -34,7 +34,7 @@ import java.io.File; import java.io.FileOutputStream; import java.util.ArrayList; import java.util.Collection; -import java.util.Collections; +import java.util.LinkedList; import java.util.List; public class cgeoimages extends AbstractActivity { @@ -55,7 +55,11 @@ public class cgeoimages extends AbstractActivity { private BitmapDrawable currentDrawable; private cgImage currentImage; - static private final Collection<Bitmap> bitmaps = Collections.synchronizedCollection(new ArrayList<Bitmap>()); + // We could use a Set here, but we will insert no duplicates, so there is no need to check for uniqueness. + private final Collection<Bitmap> bitmaps = new LinkedList<Bitmap>(); + private int message; + private boolean offline; + private ArrayList<cgImage> imageNames; private void loadImages(final List<cgImage> images, final int progressMessage, final boolean offline) { @@ -175,31 +179,34 @@ public class cgeoimages extends AbstractActivity { setTitle(res.getString(img_type == SPOILER_IMAGES ? R.string.cache_spoiler_images_title : R.string.cache_log_images_title)); inflater = getLayoutInflater(); - if (imagesView == null) { - imagesView = (LinearLayout) findViewById(R.id.spoiler_list); - } + imagesView = (LinearLayout) findViewById(R.id.spoiler_list); - final ArrayList<cgImage> images = extras.getParcelableArrayList("images"); - if (CollectionUtils.isEmpty(images)) { + imageNames = extras.getParcelableArrayList("images"); + if (CollectionUtils.isEmpty(imageNames)) { showToast(res.getString(R.string.warn_load_images)); finish(); return; } - final int message = img_type == SPOILER_IMAGES ? R.string.cache_spoiler_images_loading : R.string.cache_log_images_loading; - final boolean offline = app.isOffline(geocode, null) && (img_type == SPOILER_IMAGES || Settings.isStoreLogImages()); + message = img_type == SPOILER_IMAGES ? R.string.cache_spoiler_images_loading : R.string.cache_log_images_loading; + offline = app.isOffline(geocode, null) && (img_type == SPOILER_IMAGES || Settings.isStoreLogImages()); + } - loadImages(images, message, offline); + @Override + public void onStart() { + super.onStart(); + loadImages(imageNames, message, offline); } @Override - public void onDestroy() { + public void onStop() { // Reclaim native memory faster than the finalizers would - for (Bitmap b : bitmaps) { + imagesView.removeAllViews(); + for (final Bitmap b : bitmaps) { b.recycle(); } bitmaps.clear(); - super.onDestroy(); + super.onStop(); } private void viewImageInStandardApp(final BitmapDrawable image) { diff --git a/main/src/cgeo/geocaching/files/FileList.java b/main/src/cgeo/geocaching/files/FileList.java index 431fe3b..08c1940 100644 --- a/main/src/cgeo/geocaching/files/FileList.java +++ b/main/src/cgeo/geocaching/files/FileList.java @@ -19,15 +19,17 @@ import android.widget.ArrayAdapter; import java.io.File; import java.util.ArrayList; +import java.util.Collections; +import java.util.Comparator; import java.util.List; public abstract class FileList<T extends ArrayAdapter<File>> extends AbstractListActivity { private static final int MSG_SEARCH_WHOLE_SD_CARD = 1; - private List<File> files = new ArrayList<File>(); + private final List<File> files = new ArrayList<File>(); private T adapter = null; private ProgressDialog waitDialog = null; - private loadFiles searchingThread = null; + private SearchFilesThread searchingThread = null; private boolean endSearching = false; private int listId = StoredList.STANDARD_LIST_ID; final private Handler changeWaitDialogHandler = new Handler() { @@ -114,7 +116,7 @@ public abstract class FileList<T extends ArrayAdapter<File>> extends AbstractLis ); endSearching = false; - searchingThread = new loadFiles(); + searchingThread = new SearchFilesThread(); searchingThread.start(); } @@ -145,14 +147,14 @@ public abstract class FileList<T extends ArrayAdapter<File>> extends AbstractLis */ protected abstract void setTitle(); - private class loadFiles extends Thread { + private class SearchFilesThread extends Thread { public void notifyEnd() { endSearching = true; } @Override public void run() { - List<File> list = new ArrayList<File>(); + final List<File> list = new ArrayList<File>(); try { if (Environment.getExternalStorageState().equals(Environment.MEDIA_MOUNTED)) { @@ -181,7 +183,13 @@ public abstract class FileList<T extends ArrayAdapter<File>> extends AbstractLis changeWaitDialogHandler.sendMessage(Message.obtain(changeWaitDialogHandler, 0, "loaded directories")); files.addAll(list); - list.clear(); + Collections.sort(files, new Comparator<File>() { + + @Override + public int compare(File lhs, File rhs) { + return lhs.getName().compareToIgnoreCase(rhs.getName()); + } + }); loadFilesHandler.sendMessage(Message.obtain(loadFilesHandler)); } diff --git a/main/src/cgeo/geocaching/files/GPXParser.java b/main/src/cgeo/geocaching/files/GPXParser.java index 76ca111..fbe1b65 100644 --- a/main/src/cgeo/geocaching/files/GPXParser.java +++ b/main/src/cgeo/geocaching/files/GPXParser.java @@ -51,6 +51,7 @@ public abstract class GPXParser extends FileParser { */ private static final Pattern patternGeocode = Pattern.compile("([A-Z][0-9A-Z]+)"); private static final Pattern patternGuid = Pattern.compile(".*" + Pattern.quote("guid=") + "([0-9a-z\\-]+)", Pattern.CASE_INSENSITIVE); + private static final Pattern patternUrlGeocode = Pattern.compile(".*" + Pattern.quote("wp=") + "([A-Z][0-9A-Z]+)", Pattern.CASE_INSENSITIVE); /** * supported groundspeak extensions of the GPX format */ @@ -228,7 +229,7 @@ public abstract class GPXParser extends FileParser { static Date parseDate(String inputUntrimmed) throws ParseException { String input = inputUntrimmed.trim(); - // remove milli seconds to reduce number of needed patterns + // remove milliseconds to reduce number of needed patterns final Matcher matcher = PATTERN_MILLISECONDS.matcher(input); input = matcher.replaceFirst(""); if (input.contains("Z")) { @@ -422,6 +423,11 @@ public abstract class GPXParser extends FileParser { cache.setGuid(guid); } } + final Matcher matcherCode = patternUrlGeocode.matcher(url); + if (matcherCode.matches()) { + String geocode = matcherCode.group(1); + cache.setGeocode(geocode); + } } }); diff --git a/tests/res/raw/geotoad.gpx b/tests/res/raw/geotoad.gpx new file mode 100644 index 0000000..a83217d --- /dev/null +++ b/tests/res/raw/geotoad.gpx @@ -0,0 +1,199 @@ +<?xml version="1.0" encoding="utf-8"?>
+<gpx xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1.0" creator="GeoToad" xsi:schemaLocation="http://www.topografix.com/GPX/1/0 http://www.topografix.com/GPX/1/0/gpx.xsd http://www.groundspeak.com/cache/1/0/1 http://www.groundspeak.com/cache/1/0/1/cache.xsd" xmlns="http://www.topografix.com/GPX/1/0">
+<name>20120621T221044</name>
+<desc>GeoToad: wid = GC1T3MK:GC2KN6K (22Jun12 00:33)</desc>
+<author>GeoToad 3.16.0</author>
+<email>geotoad@googlegroups.com</email>
+<time>2012-06-21T22:10:44.000Z</time>
+<keywords>cache, geocache, groundspeak, geotoad</keywords>
+<wpt lat="51.949683" lon="8.603733">
+ <time>2009-06-07T07:00:00.000Z</time>
+ <name>"Wunnibert"</name>
+ <desc>"Wunnibert" by Jo44, traditional (1/1.5)</desc>
+ <url>http://www.geocaching.com/seek/cache_details.aspx?wp=GC1T3MK</url>
+ <urlname>"Wunnibert"</urlname>
+ <sym>Geocache</sym>
+ <type>Geocache|Traditional Cache</type>
+ <groundspeak:cache id="1260698" available="True" archived="False" xmlns:groundspeak="http://www.groundspeak.com/cache/1/0/1">
+ <groundspeak:name>"Wunnibert"</groundspeak:name>
+ <groundspeak:placed_by>Jo44</groundspeak:placed_by>
+ <groundspeak:owner id="217639962">Jo44</groundspeak:owner>
+ <groundspeak:type>Traditional Cache</groundspeak:type>
+ <groundspeak:container>small</groundspeak:container>
+ <groundspeak:difficulty>1</groundspeak:difficulty>
+ <groundspeak:terrain>1.5</groundspeak:terrain>
+ <groundspeak:country>Germany</groundspeak:country>
+ <groundspeak:state>Nordrhein-Westfalen</groundspeak:state>
+ <groundspeak:attributes>
+ <groundspeak:attribute id="32" inc="1">Bikes allowed</groundspeak:attribute>
+ <groundspeak:attribute id="41" inc="1">Stroller accessible</groundspeak:attribute>
+ <groundspeak:attribute id="7" inc="1">Takes less than 1 hour</groundspeak:attribute>
+ <groundspeak:attribute id="6" inc="1">Kid friendly</groundspeak:attribute>
+ <groundspeak:attribute id="15" inc="1">Available in winter</groundspeak:attribute>
+ <groundspeak:attribute id="13" inc="1">Available 24-7</groundspeak:attribute>
+ <groundspeak:attribute id="1" inc="1">Dogs allowed</groundspeak:attribute>
+ </groundspeak:attributes>
+ <groundspeak:short_description html="True"><br />[Bikes allowed, stroller accessible, takes less than 1 hour, kid friendly, available in winter, available 24-7, dogs allowed]<br />Geschützter Tradi in einem lichten Fichtenwald.</groundspeak:short_description>
+ <groundspeak:long_description html="True">Ein neuer Stern ist am Cacherhimmel aufgegangen!<br /> Am 31.05.2009 ist "Wunnibert" geboren!<br /> Reichlich Cachergene hat er mitbekommen: Von Papa, Großpapa, Omi, Tante, Onkel und Cousine.<br /> Gebt "Wunnibert" doch einen guten Rat oder einen heißen Tipp mit auf seinen ( Cacher - ) Lebensweg. <p>Inhalt: Logbuch, Stift und Schnuller.</p> <p>"Wunnibert" hat am 26.07.2010 eine Cousine bekommen: <a href= "http://coord.info/GC2CDA8">"Tummyseed" (GC2CDA8)</a></p></groundspeak:long_description>
+ <groundspeak:encoded_hints>piekst</groundspeak:encoded_hints>
+ <groundspeak:logs>
+ <groundspeak:log id="976171115">
+ <groundspeak:date>2012-06-16T07:00:00.000Z</groundspeak:date>
+ <groundspeak:type>Found it</groundspeak:type>
+ <groundspeak:finder id="4235994636">randyandy21</groundspeak:finder>
+ <groundspeak:text encoded="False">TFTC auf netter Runde gefunden. Nun wieder auf in die Heimat.</groundspeak:text>
+ </groundspeak:log>
+ <groundspeak:log id="2879926257">
+ <groundspeak:date>2012-06-13T07:00:00.000Z</groundspeak:date>
+ <groundspeak:type>Found it</groundspeak:type>
+ <groundspeak:finder id="1912797330">earlysun</groundspeak:finder>
+ <groundspeak:text encoded="False">Auf einem kurzbesuch in Bielefeld auch diesen Cache gut gefunden. TFTC!<br />TB: IN</groundspeak:text>
+ </groundspeak:log>
+ <groundspeak:log id="1225655337">
+ <groundspeak:date>2012-06-07T07:00:00.000Z</groundspeak:date>
+ <groundspeak:type>Found it</groundspeak:type>
+ <groundspeak:finder id="3223130690">White Werewolf</groundspeak:finder>
+ <groundspeak:text encoded="False">Mit Sali09 wurde heute einen kleine Runde gestartet und einige Ecken besichtigt die ich bisher von Sennestadt noch nicht kannte. Dieser hier gehörte mit dazu. Vielen Dank fürs Zeigen an den Owner.</groundspeak:text>
+ </groundspeak:log>
+ <groundspeak:log id="848543352">
+ <groundspeak:date>2012-06-07T07:00:00.000Z</groundspeak:date>
+ <groundspeak:type>Found it</groundspeak:type>
+ <groundspeak:finder id="2299342038">SaLi09</groundspeak:finder>
+ <groundspeak:text encoded="False">Hier war die Dose schnell gefunden! DFDC SaLi09</groundspeak:text>
+ </groundspeak:log>
+ <groundspeak:log id="121081409">
+ <groundspeak:date>2012-05-21T07:00:00.000Z</groundspeak:date>
+ <groundspeak:type>Found it</groundspeak:type>
+ <groundspeak:finder id="3782225719">DZElsoff</groundspeak:finder>
+ <groundspeak:text encoded="False">Schnell noch mal einen kleinen Spaziergang durch den Wald, ein wenig stechen lassen und dann war er mir.</groundspeak:text>
+ </groundspeak:log>
+ <groundspeak:log id="1258700408">
+ <groundspeak:date>2012-05-12T07:00:00.000Z</groundspeak:date>
+ <groundspeak:type>Found it</groundspeak:type>
+ <groundspeak:finder id="1700209325">Columbus.</groundspeak:finder>
+ <groundspeak:text encoded="False">Nach Tummyseed mussten wir natürlich auch bei Wunnibert vorbeischauen. Wir haben die Dose nach dem Loggen wieder in ihr Versteck zurückgelegt.<br />Danke und Gruß.<br />1195</groundspeak:text>
+ </groundspeak:log>
+ <groundspeak:log id="2815497952">
+ <groundspeak:date>2012-05-12T07:00:00.000Z</groundspeak:date>
+ <groundspeak:type>Found it</groundspeak:type>
+ <groundspeak:finder id="647739319">monanam</groundspeak:finder>
+ <groundspeak:text encoded="False">gefunfen! DFDC, MONANAM</groundspeak:text>
+ </groundspeak:log>
+ <groundspeak:log id="3699054691">
+ <groundspeak:date>2012-04-27T07:00:00.000Z</groundspeak:date>
+ <groundspeak:type>Found it</groundspeak:type>
+ <groundspeak:finder id="2222272664">Wurtzkoplento</groundspeak:finder>
+ <groundspeak:text encoded="False">Bingo;)</groundspeak:text>
+ </groundspeak:log>
+ <groundspeak:log id="1967583827">
+ <groundspeak:date>2012-04-23T07:00:00.000Z</groundspeak:date>
+ <groundspeak:type>Found it</groundspeak:type>
+ <groundspeak:finder id="691211936">-TeamChihuahua-</groundspeak:finder>
+ <groundspeak:text encoded="False">Nach einem Pflicht besuch in diesem Wald, die dornige Dose schnell in den Händen gehalten und signiert. <br />TFTC<br />Team Chihuahua<br /><br />23. April 2012 <br />Cache : 1512</groundspeak:text>
+ </groundspeak:log>
+ <groundspeak:log id="328214809">
+ <groundspeak:date>2012-04-14T07:00:00.000Z</groundspeak:date>
+ <groundspeak:type>Found it</groundspeak:type>
+ <groundspeak:finder id="217551773">zumsel9b</groundspeak:finder>
+ <groundspeak:text encoded="False">Bei einer Testfahrt für das neue Fahrrad meiner Tochter haben wir hier kurz halt gemacht.</groundspeak:text>
+ </groundspeak:log>
+ </groundspeak:logs>
+ <groundspeak:travelbugs></groundspeak:travelbugs>
+ </groundspeak:cache>
+</wpt>
+<wpt lat="51.909767" lon="8.615650">
+ <time>2010-12-26T07:00:00.000Z</time>
+ <name>Dem "Dings" zum Trotz 2</name>
+ <desc>Dem "Dings" zum Trotz 2 by Sonnentatzen, traditional (2/1.5)</desc>
+ <url>http://www.geocaching.com/seek/cache_details.aspx?wp=GC2KN6K</url>
+ <urlname>Dem "Dings" zum Trotz 2</urlname>
+ <sym>Geocache</sym>
+ <type>Geocache|Traditional Cache</type>
+ <groundspeak:cache id="2022337" available="True" archived="False" xmlns:groundspeak="http://www.groundspeak.com/cache/1/0/1">
+ <groundspeak:name>Dem "Dings" zum Trotz 2</groundspeak:name>
+ <groundspeak:placed_by>Sonnentatzen</groundspeak:placed_by>
+ <groundspeak:owner id="3494626085">Sonnentatzen</groundspeak:owner>
+ <groundspeak:type>Traditional Cache</groundspeak:type>
+ <groundspeak:container>micro</groundspeak:container>
+ <groundspeak:difficulty>2</groundspeak:difficulty>
+ <groundspeak:terrain>1.5</groundspeak:terrain>
+ <groundspeak:country>Germany</groundspeak:country>
+ <groundspeak:state>Nordrhein-Westfalen</groundspeak:state>
+ <groundspeak:attributes>
+ <groundspeak:attribute id="24" inc="0">Not wheelchair accessible</groundspeak:attribute>
+ <groundspeak:attribute id="15" inc="1">Available in winter</groundspeak:attribute>
+ <groundspeak:attribute id="13" inc="1">Available 24-7</groundspeak:attribute>
+ <groundspeak:attribute id="42" inc="1">Needs maintenance</groundspeak:attribute>
+ <groundspeak:attribute id="7" inc="1">Takes less than 1 hour</groundspeak:attribute>
+ <groundspeak:attribute id="6" inc="1">Kid friendly</groundspeak:attribute>
+ <groundspeak:attribute id="1" inc="1">Dogs allowed</groundspeak:attribute>
+ </groundspeak:attributes>
+ <groundspeak:short_description html="True"><br />[Not wheelchair accessible, available in winter, available 24-7, needs maintenance, takes less than 1 hour, kid friendly, dogs allowed]<br /></groundspeak:short_description>
+ <groundspeak:long_description html="True"><span style="font-weight: bold;"><span>Das Dings ( <span style= "color: rgb(204, 0, 23);">der Schnee</span>) ist überall und ärgert uns Cacher ein kleines Bisschen!<br /> <br /> Dies ist ein Tradi,<br /> der zu einer neuen Serie von Caches gehört,<br /> die trotz "Dings" gefunden werden können.<br /> <br /> <span style="color: rgb(178, 17, 98);">Nachahmung erwünscht!<br /> <br /> <span style="color: rgb(0, 0, 0);">Viel Spass beim Suchen und Finden ! <img align="right" src= "http://img525.imageshack.us/img525/4821/30679113.jpg" alt="" style="margin: 3px 0px 3px 10px; width: 179px; height: 128px;" /> <img align="" src="http://" alt="" style= "margin: 3px 0px; display: block;" /></span><br /></span></span></span> <div><a href="http://www.gcJoker.de"><img border="0" src= "http://www.gcJoker.de/img/banner/banner200x73.gif" alt= "banner" /></a> <div> </div> </div></groundspeak:long_description>
+ <groundspeak:encoded_hints>Ich bin zweckentfremdet, in mir steckt mehr als im ersten Moment zu sehen ist.</groundspeak:encoded_hints>
+ <groundspeak:logs>
+ <groundspeak:log id="1612244872">
+ <groundspeak:date>2012-06-11T07:00:00.000Z</groundspeak:date>
+ <groundspeak:type>Write note</groundspeak:type>
+ <groundspeak:finder id="865265718">Trouble18</groundspeak:finder>
+ <groundspeak:text encoded="False">Dies auf dem Rückweg gefunden. Es musste einfach noch dazu :)</groundspeak:text>
+ </groundspeak:log>
+ <groundspeak:log id="864079327">
+ <groundspeak:date>2012-06-11T07:00:00.000Z</groundspeak:date>
+ <groundspeak:type>Found it</groundspeak:type>
+ <groundspeak:finder id="865265718">Trouble18</groundspeak:finder>
+ <groundspeak:text encoded="False">Ständig dran vorbei gefahren, aber nie Lust gehabt zwischen den Bäumen her zu gehen. Heute endlich mal aufgerafft und ihn ohne größere Suche gefunden. Jedoch löst sich das Konstrukt langsam. Eventuell bleibt es demnächst ja unten drin.<br />Danke fürs zeigen dieses altbekannten Ortes. Das hat erinnerungen geweckt<br />Jetzt aber schnell weg bevor es regnet und der Bass des nahestehenden Autofahrers ist auch gruselig.<br />Tftc</groundspeak:text>
+ </groundspeak:log>
+ <groundspeak:log id="2652272802">
+ <groundspeak:date>2012-06-10T07:00:00.000Z</groundspeak:date>
+ <groundspeak:type>Found it</groundspeak:type>
+ <groundspeak:finder id="4021816271">TomTimpani</groundspeak:finder>
+ <groundspeak:text encoded="False">Heute meine Laufrunde nach Schloß Holte verlagert. Oh Wunder, es lagen tatsächlich ein paar Caches auf dem Weg. Auch diesen gerne geloggt.<br />TFTC<br />TomTimpani</groundspeak:text>
+ </groundspeak:log>
+ <groundspeak:log id="2702448538">
+ <groundspeak:date>2012-06-08T07:00:00.000Z</groundspeak:date>
+ <groundspeak:type>Found it</groundspeak:type>
+ <groundspeak:finder id="2580462969">Kantakor</groundspeak:finder>
+ <groundspeak:text encoded="False">Auch diesen kleinen Freund auf der heutigen Abend/Nachttour schnell<br />gesucht, gefunden und muggelfrei geloggt.<br /><br />Danke fürs Verstecken,<br /><br />Kantakor</groundspeak:text>
+ </groundspeak:log>
+ <groundspeak:log id="2003742312">
+ <groundspeak:date>2012-06-08T07:00:00.000Z</groundspeak:date>
+ <groundspeak:type>Found it</groundspeak:type>
+ <groundspeak:finder id="3594345313">andimitabei</groundspeak:finder>
+ <groundspeak:text encoded="False">Hier wurde ich gestern Abend mit dresinator und DerTobi91 fündig, auf unserer Tour durch Kaunitz richtung Oerlinghausen zu einem tollen Nachtcache :)</groundspeak:text>
+ </groundspeak:log>
+ <groundspeak:log id="1388327984">
+ <groundspeak:date>2012-06-07T07:00:00.000Z</groundspeak:date>
+ <groundspeak:type>Found it</groundspeak:type>
+ <groundspeak:finder id="1794171066">Dresinator</groundspeak:finder>
+ <groundspeak:text encoded="False">Netter Cache, gut gefunden :)</groundspeak:text>
+ </groundspeak:log>
+ <groundspeak:log id="1085751396">
+ <groundspeak:date>2012-06-07T07:00:00.000Z</groundspeak:date>
+ <groundspeak:type>Found it</groundspeak:type>
+ <groundspeak:finder id="2217329812">Dertobi91</groundspeak:finder>
+ <groundspeak:text encoded="False">Tricks<br /></groundspeak:text>
+ </groundspeak:log>
+ <groundspeak:log id="3812521635">
+ <groundspeak:date>2012-05-30T07:00:00.000Z</groundspeak:date>
+ <groundspeak:type>Found it</groundspeak:type>
+ <groundspeak:finder id="2730780912">worldsucks</groundspeak:finder>
+ <groundspeak:text encoded="False">Die Dose konnte sich zwar kurze Zeit vor uns verstecken, irgendwann hat mein Cacherkollege dann aber doch zugeschlagen. Vielen Dank für diese sehr schöne und kreativ gestaltete Dose!<br /><br />Viel Erfolg weiterhin im Kampf gegen das "Dings" :-)</groundspeak:text>
+ </groundspeak:log>
+ <groundspeak:log id="1688400223">
+ <groundspeak:date>2012-05-30T07:00:00.000Z</groundspeak:date>
+ <groundspeak:type>Found it</groundspeak:type>
+ <groundspeak:finder id="1356983771">merle & phoebe</groundspeak:finder>
+ <groundspeak:text encoded="False">Unser "Abschlusscache" der heutigen Runde in Schloß-Holte und Umgebung. Nach ein paar Minuten drum herum suchen, da das GPS durch die Bäume irritiert war, konnten wir letztlich doch noch den richtigen Griff machen. Sehr schön gemachter Cache und toll getarnt.<br /><br />Da kann der "Dings" sich warm anziehen.<br /><br />DfdC</groundspeak:text>
+ </groundspeak:log>
+ <groundspeak:log id="3560290342">
+ <groundspeak:date>2012-05-20T07:00:00.000Z</groundspeak:date>
+ <groundspeak:type>Found it</groundspeak:type>
+ <groundspeak:finder id="4235785866">knaex</groundspeak:finder>
+ <groundspeak:text encoded="False">Nach kurzer Orientierung problemlos gefunden ... TFTC</groundspeak:text>
+ </groundspeak:log>
+ </groundspeak:logs>
+ <groundspeak:travelbugs></groundspeak:travelbugs>
+ </groundspeak:cache>
+</wpt>
+</gpx>
diff --git a/tests/src/cgeo/geocaching/files/GPXParserTest.java b/tests/src/cgeo/geocaching/files/GPXParserTest.java index 53b6c33..8193fd8 100644 --- a/tests/src/cgeo/geocaching/files/GPXParserTest.java +++ b/tests/src/cgeo/geocaching/files/GPXParserTest.java @@ -231,4 +231,14 @@ public class GPXParserTest extends AbstractResourceInstrumentationTestCase { // previously these caches overwrote each other during parsing assertEquals(130, caches.size()); } + + public void testGeoToad() throws Exception { + final List<cgCache> caches = readGPX10(R.raw.geotoad); + assertEquals(2, caches.size()); + cgCache cache; + cache = caches.get(0); + assertEquals("GC2KN6K", cache.getGeocode()); + cache = caches.get(1); + assertEquals("GC1T3MK", cache.getGeocode()); + } } |
