From b3f186680bcdb9a94f285f850a1372066a67d5f4 Mon Sep 17 00:00:00 2001 From: Brad Fitzpatrick Date: Sun, 1 Aug 2010 20:26:19 -0700 Subject: [PATCH] add MyTracks directories --- clients/android/uploader/src/com/danga/camli/Preferences.java | 1 + .../android/uploader/src/com/danga/camli/UploadService.java | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/clients/android/uploader/src/com/danga/camli/Preferences.java b/clients/android/uploader/src/com/danga/camli/Preferences.java index f3893feec..62e7ddc6e 100644 --- a/clients/android/uploader/src/com/danga/camli/Preferences.java +++ b/clients/android/uploader/src/com/danga/camli/Preferences.java @@ -12,6 +12,7 @@ public final class Preferences { public static final String AUTO_REQUIRE_WIFI = "camli.auto.require_wifi"; public static final String AUTO_DIR_PHOTOS = "camli.auto.photos"; + public static final String AUTO_DIR_MYTRACKS = "camli.auto.mytracks"; private Preferences() { } diff --git a/clients/android/uploader/src/com/danga/camli/UploadService.java b/clients/android/uploader/src/com/danga/camli/UploadService.java index ee93946f6..58dc9f2a5 100644 --- a/clients/android/uploader/src/com/danga/camli/UploadService.java +++ b/clients/android/uploader/src/com/danga/camli/UploadService.java @@ -202,6 +202,10 @@ public class UploadService extends Service { if (mPrefs.getBoolean(Preferences.AUTO_DIR_PHOTOS, true)) { dirs.add(Environment.getExternalStorageDirectory() + "/DCIM/Camera"); } + if (mPrefs.getBoolean(Preferences.AUTO_DIR_MYTRACKS, true)) { + dirs.add(Environment.getExternalStorageDirectory() + "/gpx"); + dirs.add(Environment.getExternalStorageDirectory() + "/kml"); + } return dirs; }