aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorkoem <koem@petoria.de>2013-04-30 16:50:25 -0500
committerkoem <koem@petoria.de>2013-05-01 18:26:32 -0500
commit9eae0750719e94dab9dae6540095e19fa7b11ff9 (patch)
tree6d9d661b734b55bd64f73032d2454a060f93f65c
parent2f938427afe4b6c5c77f67e78955a53a468c7ceb (diff)
downloadcgeo-9eae0750719e94dab9dae6540095e19fa7b11ff9.zip
cgeo-9eae0750719e94dab9dae6540095e19fa7b11ff9.tar.gz
cgeo-9eae0750719e94dab9dae6540095e19fa7b11ff9.tar.bz2
issue2662 OC: leichtes Klettern
-rw-r--r--.gitignore5
-rw-r--r--main/project/attributes/iconlist.txt3
-rw-r--r--main/project/attributes/svgs/easy_climbing.svg84
-rw-r--r--main/res/drawable-mdpi/attribute_easy_climbing.pngbin0 -> 1236 bytes
-rw-r--r--main/res/values-de/strings.xml2
-rw-r--r--main/res/values/strings.xml2
-rw-r--r--main/src/cgeo/geocaching/cgData.java12
-rw-r--r--main/src/cgeo/geocaching/enumerations/CacheAttribute.java27
8 files changed, 113 insertions, 22 deletions
diff --git a/.gitignore b/.gitignore
index 854175d..2a6ccbd 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,14 +1,15 @@
bin/
gen/
/main/project/localization/*.missing
-/main/project/attributes/drawable/*
+/main/project/attributes/drawable-mdpi/
/main/project/attributes/iconlist1res.html
/main/local.properties
/main/private.properties
/main/res/values/mapsapikey.xml
/tests/local.properties
/tests/private.properties
+/tests/hs_err_pid*.log
/cgeo-calendar/local.properties
/cgeo-calendar/private.properties
.directory
-org.moreunit.prefs \ No newline at end of file
+org.moreunit.prefs
diff --git a/main/project/attributes/iconlist.txt b/main/project/attributes/iconlist.txt
index 046add1..8b75ab6 100644
--- a/main/project/attributes/iconlist.txt
+++ b/main/project/attributes/iconlist.txt
@@ -27,7 +27,7 @@ kids | 6 | 59 | x | PD | | ht
onehour | 7 | | x | CC0 | The Noun Project | http://thenounproject.com/noun/clock/#icon-No2306
scenic | 8 | | | PD | USA National Park Service | http://thenounproject.com/noun/binoculars/#icon-No112
hiking | 9 | 25 | | PD | USA National Park Service | http://thenounproject.com/noun/hiker/#icon-No562
-climbing | 10 | 28 | | PD | USA National Park Service | http://thenounproject.com/noun/climbing/#icon-No526
+climbing | 10 | | | PD | USA National Park Service | http://thenounproject.com/noun/climbing/#icon-No526
wading | 11 | | x | PD | USA National Park Service | http://thenounproject.com/noun/wading/#icon-No581
swimming | 12 | 29 | | PD | USA National Park Service | http://thenounproject.com/noun/swimming/#icon-No226
available | 13 | 38 | x | PD | koem | selfmade
@@ -86,6 +86,7 @@ railway | | 10 | | CC0 | | ht
syringe | | 23 | | CC0 | Betovarg Jabib | http://thenounproject.com/noun/syringe/#icon-No1508
swamp | | 26 | x | CC0 | Megan Strickland | http://thenounproject.com/noun/hand/#icon-No1477
hills | | 27 | x | PD | koem | selfmade
+easy_climbing | | 28 | x | PD | USA National Park Service | http://thenounproject.com/noun/climbing/#icon-No526
poi | | 30 | | PD | | http://thenounproject.com/noun/point-of-interest/#icon-No522
moving_target | | 31 | x | PD | | http://thenounproject.com/noun/running/#icon-No246
webcam | | 32 | | PD | | http://thenounproject.com/noun/video-camera/#icon-No637
diff --git a/main/project/attributes/svgs/easy_climbing.svg b/main/project/attributes/svgs/easy_climbing.svg
new file mode 100644
index 0000000..682b053
--- /dev/null
+++ b/main/project/attributes/svgs/easy_climbing.svg
@@ -0,0 +1,84 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Generator: Adobe Illustrator 14.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 43363) -->
+
+<svg
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
+ xmlns:cc="http://creativecommons.org/ns#"
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+ xmlns:svg="http://www.w3.org/2000/svg"
+ xmlns="http://www.w3.org/2000/svg"
+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+ version="1.0"
+ id="Layer_1"
+ x="0px"
+ y="0px"
+ width="96.114998"
+ height="94.002548"
+ viewBox="0 0 96.114999 94.002552"
+ enable-background="new 0 0 99.572 99.993"
+ xml:space="preserve"
+ inkscape:version="0.48.3.1 r9886"
+ sodipodi:docname="easy_climbing.svg"><metadata
+ id="metadata2876"><rdf:RDF><cc:Work
+ rdf:about=""><dc:format>image/svg+xml</dc:format><dc:type
+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" /></cc:Work></rdf:RDF></metadata><defs
+ id="defs2874"><inkscape:perspective
+ sodipodi:type="inkscape:persp3d"
+ inkscape:vp_x="0 : 49.996498 : 1"
+ inkscape:vp_y="0 : 1000 : 0"
+ inkscape:vp_z="99.571999 : 49.996498 : 1"
+ inkscape:persp3d-origin="49.785999 : 33.330999 : 1"
+ id="perspective2878" /></defs><sodipodi:namedview
+ pagecolor="#009674"
+ bordercolor="#666666"
+ borderopacity="1"
+ objecttolerance="10"
+ gridtolerance="10"
+ guidetolerance="10"
+ inkscape:pageopacity="1"
+ inkscape:pageshadow="2"
+ inkscape:window-width="1317"
+ inkscape:window-height="744"
+ id="namedview2872"
+ showgrid="false"
+ inkscape:zoom="3.3377778"
+ inkscape:cx="46.452495"
+ inkscape:cy="45.214888"
+ inkscape:window-x="49"
+ inkscape:window-y="24"
+ inkscape:window-maximized="1"
+ inkscape:current-layer="Layer_1"
+ fit-margin-top="0"
+ fit-margin-left="0"
+ fit-margin-right="0"
+ fit-margin-bottom="0" />
+
+<path
+ d="m 77.215999,51.217552 7.57,-1.002 6.642,-27.295 4.687,0.25 0,66.571 c 0,2.356 -1.904,4.261003 -4.26,4.261003 L 2.1299988,93.927555 -1.1822193e-6,84.804552 23.584999,79.566552 l 3.685,-8.748 21.756,-7.77 16.636,7.369 6.392,-2.081 5.162,-17.119 z"
+ id="path2866"
+ style="fill:#ffffff"
+ inkscape:connector-curvature="0" />
+<g
+ id="g2986"
+ transform="matrix(0.74143286,0,0,0.74143286,0.25199462,0)"><path
+ style="fill:#ffffff"
+ id="path2864"
+ d="m 11.271,42.81 c -0.451,0.927 -0.777,1.955 -0.952,3.058 -0.075,0.552 -0.126,1.103 -0.126,1.654 l 0.401,25.259 -8.723,18.798 c -0.301,0.552 -0.526,1.203 -0.626,1.88 -0.477,3.107 1.654,5.99 4.762,6.467 2.406,0.376 4.712,-0.853 5.815,-2.883 l 9.6,-20.553 c 0.2,-0.477 0.376,-0.978 0.451,-1.529 0.024,-0.25 0.05,-0.525 0.05,-0.776 l -0.075,-15.608 14.738,6.435 2.381,15.265 c 0.477,2.23 2.306,4.01 4.688,4.386 3.107,0.451 5.99,-1.679 6.466,-4.763 0.075,-0.525 0.075,-1.053 0.025,-1.553 L 47.238,59.93 c -0.352,-1.78 -1.529,-3.309 -3.184,-4.086 l -13.184,-5.865 8.396,-14.613 4.161,5.289 c 0.426,0.477 0.977,0.877 1.604,1.128 l 15.866,4.637 c 2.105,0.451 4.261,-0.652 5.088,-2.682 0.928,-2.306 -0.176,-4.913 -2.456,-5.84 -0.075,-0.025 -0.15,-0.05 -0.226,-0.075 L 49.517,33.762 39.143,21.305 C 37.588,19.651 35.508,18.473 33.102,18.097 28.891,17.47 24.906,19.475 22.8,22.884 L 11.271,42.81 z"
+ inkscape:connector-curvature="0" /><path
+ style="fill:#ffffff"
+ id="path2868"
+ d="m 38.24,16.994 c 4.687,0 8.496,-3.81 8.496,-8.497 C 46.736,3.81 42.927,0 38.24,0 c -4.688,0 -8.497,3.81 -8.497,8.497 0,4.687 3.81,8.497 8.497,8.497 z"
+ inkscape:connector-curvature="0" /></g>
+
+<g
+ transform="matrix(0.44375412,0,0,0.44375412,51.851618,11.258457)"
+ id="g2986-6"><path
+ inkscape:connector-curvature="0"
+ style="fill:#ffffff"
+ id="path2864-9"
+ d="m 11.271,42.81 c -0.451,0.927 -0.777,1.955 -0.952,3.058 -0.075,0.552 -0.126,1.103 -0.126,1.654 l 0.401,25.259 -8.723,18.798 c -0.301,0.552 -0.526,1.203 -0.626,1.88 -0.477,3.107 1.654,5.99 4.762,6.467 2.406,0.376 4.712,-0.853 5.815,-2.883 l 9.6,-20.553 c 0.2,-0.477 0.376,-0.978 0.451,-1.529 0.024,-0.25 0.05,-0.525 0.05,-0.776 l -0.075,-15.608 14.738,6.435 2.381,15.265 c 0.477,2.23 2.306,4.01 4.688,4.386 3.107,0.451 5.99,-1.679 6.466,-4.763 0.075,-0.525 0.075,-1.053 0.025,-1.553 L 47.238,59.93 c -0.352,-1.78 -1.529,-3.309 -3.184,-4.086 l -13.184,-5.865 8.396,-14.613 4.161,5.289 c 0.426,0.477 0.977,0.877 1.604,1.128 l 15.866,4.637 c 2.105,0.451 4.261,-0.652 5.088,-2.682 0.928,-2.306 -0.176,-4.913 -2.456,-5.84 -0.075,-0.025 -0.15,-0.05 -0.226,-0.075 L 49.517,33.762 39.143,21.305 C 37.588,19.651 35.508,18.473 33.102,18.097 28.891,17.47 24.906,19.475 22.8,22.884 L 11.271,42.81 z" /><path
+ inkscape:connector-curvature="0"
+ style="fill:#ffffff"
+ id="path2868-3"
+ d="m 38.24,16.994 c 4.687,0 8.496,-3.81 8.496,-8.497 C 46.736,3.81 42.927,0 38.24,0 c -4.688,0 -8.497,3.81 -8.497,8.497 0,4.687 3.81,8.497 8.497,8.497 z" /></g></svg> \ No newline at end of file
diff --git a/main/res/drawable-mdpi/attribute_easy_climbing.png b/main/res/drawable-mdpi/attribute_easy_climbing.png
new file mode 100644
index 0000000..ecf10b8
--- /dev/null
+++ b/main/res/drawable-mdpi/attribute_easy_climbing.png
Binary files differ
diff --git a/main/res/values-de/strings.xml b/main/res/values-de/strings.xml
index ab0b11e..37aa5aa 100644
--- a/main/res/values-de/strings.xml
+++ b/main/res/values-de/strings.xml
@@ -991,6 +991,8 @@
<string name="attribute_swamp_no">Nicht sumpfig / kein matschiges Gelände</string>
<string name="attribute_hills_yes">Hügeliges Gelände</string>
<string name="attribute_hills_no">Kein hügeliges Gelände</string>
+ <string name="attribute_easy_climbing_yes">Einfaches Klettern</string>
+ <string name="attribute_easy_climbing_no">Kein einfaches Klettern</string>
<string name="attribute_poi_yes">Interessanter Ort</string>
<string name="attribute_poi_no">Uninteressanter Ort</string>
<string name="attribute_moving_target_yes">Bewegliches Ziel</string>
diff --git a/main/res/values/strings.xml b/main/res/values/strings.xml
index 28a57e0..b08ad5a 100644
--- a/main/res/values/strings.xml
+++ b/main/res/values/strings.xml
@@ -1005,6 +1005,8 @@
<string name="attribute_swamp_no">No swamp or marsh</string>
<string name="attribute_hills_yes">Hilly area</string>
<string name="attribute_hills_no">No hilly area</string>
+ <string name="attribute_easy_climbing_yes">Easy climbing</string>
+ <string name="attribute_easy_climbing_no">No easy climbing</string>
<string name="attribute_poi_yes">Point of interest</string>
<string name="attribute_poi_no">No point of interest</string>
<string name="attribute_moving_target_yes">Moving target</string>
diff --git a/main/src/cgeo/geocaching/cgData.java b/main/src/cgeo/geocaching/cgData.java
index 86821fb..8a6d718 100644
--- a/main/src/cgeo/geocaching/cgData.java
+++ b/main/src/cgeo/geocaching/cgData.java
@@ -86,7 +86,7 @@ public class cgData {
private static int[] cacheColumnIndex;
private static CacheCache cacheCache = new CacheCache();
private static SQLiteDatabase database = null;
- private static final int dbVersion = 66;
+ private static final int dbVersion = 67;
public static final int customListIdOffset = 10;
private static final String dbName = "data";
private static final String dbTableCaches = "cg_caches";
@@ -675,6 +675,16 @@ public class cgData {
}
}
+ // issue2662 OC: Leichtes Klettern / Easy climbing
+ if (oldVersion < 67) {
+ try {
+ db.execSQL("update " + dbTableAttributes + " set attribute = 'easy_climbing_yes' where geocode like 'O%' and attribute = 'climbing_yes'");
+ db.execSQL("update " + dbTableAttributes + " set attribute = 'easy_climbing_no' where geocode like 'O%' and attribute = 'climbing_no'");
+ } catch (Exception e) {
+ Log.e("Failed to upgrade to ver. 67", e);
+
+ }
+ }
}
db.setTransactionSuccessful();
diff --git a/main/src/cgeo/geocaching/enumerations/CacheAttribute.java b/main/src/cgeo/geocaching/enumerations/CacheAttribute.java
index 530869f..339516b 100644
--- a/main/src/cgeo/geocaching/enumerations/CacheAttribute.java
+++ b/main/src/cgeo/geocaching/enumerations/CacheAttribute.java
@@ -12,8 +12,8 @@ import java.util.HashMap;
import java.util.Map;
public enum CacheAttribute {
- // THIS LIST IS GENERATED: don't change anything here but in
- // project/attributes/makeEnum.sh
+ // THIS LIST IS GENERATED: don't change anything here but read
+ // project/attributes/readme.txt
DOGS(1, -1, "dogs", R.drawable.attribute_dogs, R.string.attribute_dogs_yes, R.string.attribute_dogs_no),
BICYCLES(32, -1, "bicycles", R.drawable.attribute_bicycles, R.string.attribute_bicycles_yes, R.string.attribute_bicycles_no),
MOTORCYCLES(33, -1, "motorcycles", R.drawable.attribute_motorcycles, R.string.attribute_motorcycles_yes, R.string.attribute_motorcycles_no),
@@ -27,7 +27,7 @@ public enum CacheAttribute {
ONEHOUR(7, -1, "onehour", R.drawable.attribute_onehour, R.string.attribute_onehour_yes, R.string.attribute_onehour_no),
SCENIC(8, -1, "scenic", R.drawable.attribute_scenic, R.string.attribute_scenic_yes, R.string.attribute_scenic_no),
HIKING(9, 25, "hiking", R.drawable.attribute_hiking, R.string.attribute_hiking_yes, R.string.attribute_hiking_no),
- CLIMBING(10, 28, "climbing", R.drawable.attribute_climbing, R.string.attribute_climbing_yes, R.string.attribute_climbing_no),
+ CLIMBING(10, -1, "climbing", R.drawable.attribute_climbing, R.string.attribute_climbing_yes, R.string.attribute_climbing_no),
WADING(11, -1, "wading", R.drawable.attribute_wading, R.string.attribute_wading_yes, R.string.attribute_wading_no),
SWIMMING(12, 29, "swimming", R.drawable.attribute_swimming, R.string.attribute_swimming_yes, R.string.attribute_swimming_no),
AVAILABLE(13, 38, "available", R.drawable.attribute_available, R.string.attribute_available_yes, R.string.attribute_available_no),
@@ -86,6 +86,7 @@ public enum CacheAttribute {
SYRINGE(-1, 23, "syringe", R.drawable.attribute_syringe, R.string.attribute_syringe_yes, R.string.attribute_syringe_no),
SWAMP(-1, 26, "swamp", R.drawable.attribute_swamp, R.string.attribute_swamp_yes, R.string.attribute_swamp_no),
HILLS(-1, 27, "hills", R.drawable.attribute_hills, R.string.attribute_hills_yes, R.string.attribute_hills_no),
+ EASY_CLIMBING(-1, 28, "easy_climbing", R.drawable.attribute_easy_climbing, R.string.attribute_easy_climbing_yes, R.string.attribute_easy_climbing_no),
POI(-1, 30, "poi", R.drawable.attribute_poi, R.string.attribute_poi_yes, R.string.attribute_poi_no),
MOVING_TARGET(-1, 31, "moving_target", R.drawable.attribute_moving_target, R.string.attribute_moving_target_yes, R.string.attribute_moving_target_no),
WEBCAM(-1, 32, "webcam", R.drawable.attribute_webcam, R.string.attribute_webcam_yes, R.string.attribute_webcam_no),
@@ -108,8 +109,8 @@ public enum CacheAttribute {
OTHER_CACHE(-1, 57, "other_cache", R.drawable.attribute_other_cache, R.string.attribute_other_cache_yes, R.string.attribute_other_cache_no),
ASK_OWNER(-1, 58, "ask_owner", R.drawable.attribute_ask_owner, R.string.attribute_ask_owner_yes, R.string.attribute_ask_owner_no),
UNKNOWN(-1, -1, "unknown", R.drawable.attribute_unknown, R.string.attribute_unknown_yes, R.string.attribute_unknown_no);
- // THIS LIST IS GENERATED: don't change anything here but in
- // project/attributes/makeEnum.sh
+ // THIS LIST IS GENERATED: don't change anything here but read
+ // project/attributes/readme.txt
private static final String INTERNAL_YES = "_yes";
private static final String INTERNAL_NO = "_no";
@@ -146,30 +147,20 @@ public enum CacheAttribute {
}
private final static Map<String, CacheAttribute> FIND_BY_GCRAWNAME;
+ private final static SparseArray<CacheAttribute> FIND_BY_GCID = new SparseArray<CacheAttribute>();
+ private final static SparseArray<CacheAttribute> FIND_BY_OCID = new SparseArray<CacheAttribute>();
static {
final HashMap<String, CacheAttribute> mapGcRawNames = new HashMap<String, CacheAttribute>();
for (CacheAttribute attr : values()) {
mapGcRawNames.put(attr.rawName, attr);
- }
- FIND_BY_GCRAWNAME = Collections.unmodifiableMap(mapGcRawNames);
- }
-
- private final static SparseArray<CacheAttribute> FIND_BY_GCID = new SparseArray<CacheAttribute>();
- static {
- for (CacheAttribute attr : values()) {
if (attr.gcid != NO_ID) {
FIND_BY_GCID.put(attr.gcid, attr);
}
- }
- }
-
- private final static SparseArray<CacheAttribute> FIND_BY_OCID = new SparseArray<CacheAttribute>();
- static {
- for (CacheAttribute attr : values()) {
if (attr.ocid != NO_ID) {
FIND_BY_OCID.put(attr.ocid, attr);
}
}
+ FIND_BY_GCRAWNAME = Collections.unmodifiableMap(mapGcRawNames);
}
public static CacheAttribute getByRawName(final String rawName) {