forked from upstream-mirrors/OpenTracks
fix eclipse warnings
This commit is contained in:
@@ -93,7 +93,7 @@ limitations under the License.
|
|||||||
<uses-permission android:name="com.google.android.maps.mytracks.permission.MAPS_RECEIVE" />
|
<uses-permission android:name="com.google.android.maps.mytracks.permission.MAPS_RECEIVE" />
|
||||||
<uses-sdk
|
<uses-sdk
|
||||||
android:minSdkVersion="8"
|
android:minSdkVersion="8"
|
||||||
android:targetSdkVersion="16" />
|
android:targetSdkVersion="17" />
|
||||||
<!-- Required features -->
|
<!-- Required features -->
|
||||||
<uses-feature
|
<uses-feature
|
||||||
android:glEsVersion="0x00020000"
|
android:glEsVersion="0x00020000"
|
||||||
@@ -136,6 +136,7 @@ limitations under the License.
|
|||||||
android:smallScreens="true"
|
android:smallScreens="true"
|
||||||
android:xlargeScreens="true" />
|
android:xlargeScreens="true" />
|
||||||
<application
|
<application
|
||||||
|
android:allowBackup="true"
|
||||||
android:backupAgent="com.google.android.apps.mytracks.io.backup.MyTracksBackupAgent"
|
android:backupAgent="com.google.android.apps.mytracks.io.backup.MyTracksBackupAgent"
|
||||||
android:hardwareAccelerated="true"
|
android:hardwareAccelerated="true"
|
||||||
android:icon="@drawable/my_tracks_icon"
|
android:icon="@drawable/my_tracks_icon"
|
||||||
|
|||||||
-3
@@ -32,9 +32,6 @@ import java.util.Locale;
|
|||||||
*/
|
*/
|
||||||
public class SendFusionTablesUtils {
|
public class SendFusionTablesUtils {
|
||||||
|
|
||||||
public static final String SERVICE = "fusiontables";
|
|
||||||
private static final String UTF8 = "UTF8";
|
|
||||||
private static final String TABLE_ID = "tableid";
|
|
||||||
private static final String MAP_URL = "https://www.google.com/fusiontables/embedviz?"
|
private static final String MAP_URL = "https://www.google.com/fusiontables/embedviz?"
|
||||||
+ "viz=MAP&q=select+col0,+col1,+col2,+col3+from+%s+&h=false&lat=%f&lng=%f&z=%d&t=1&l=col2";
|
+ "viz=MAP&q=select+col0,+col1,+col2,+col3+from+%s+&h=false&lat=%f&lng=%f&z=%d&t=1&l=col2";
|
||||||
private static final String TAG = SendFusionTablesUtils.class.getSimpleName();
|
private static final String TAG = SendFusionTablesUtils.class.getSimpleName();
|
||||||
|
|||||||
@@ -75,6 +75,7 @@ public class MapSettingsActivity extends AbstractSettingsActivity {
|
|||||||
/**
|
/**
|
||||||
* Configures the track color mode preference.
|
* Configures the track color mode preference.
|
||||||
*/
|
*/
|
||||||
|
@SuppressWarnings("deprecation")
|
||||||
private void configTrackColorModePerference() {
|
private void configTrackColorModePerference() {
|
||||||
ListPreference preference = (ListPreference) findPreference(
|
ListPreference preference = (ListPreference) findPreference(
|
||||||
getString(R.string.track_color_mode_key));
|
getString(R.string.track_color_mode_key));
|
||||||
|
|||||||
@@ -64,6 +64,7 @@ public class RecordingSettingsActivity extends AbstractSettingsActivity {
|
|||||||
R.array.auto_resume_track_timeout_values, metricUnits);
|
R.array.auto_resume_track_timeout_values, metricUnits);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@SuppressWarnings("deprecation")
|
||||||
private void configFrequencyPreference(
|
private void configFrequencyPreference(
|
||||||
int key, int defaultValue, int valueArray, boolean metricUnits) {
|
int key, int defaultValue, int valueArray, boolean metricUnits) {
|
||||||
ListPreference preference = (ListPreference) findPreference(getString(key));
|
ListPreference preference = (ListPreference) findPreference(getString(key));
|
||||||
@@ -73,6 +74,7 @@ public class RecordingSettingsActivity extends AbstractSettingsActivity {
|
|||||||
configureListPreference(preference, options, options, values, String.valueOf(value), null);
|
configureListPreference(preference, options, options, values, String.valueOf(value), null);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@SuppressWarnings("deprecation")
|
||||||
private void configTrackName() {
|
private void configTrackName() {
|
||||||
ListPreference preference = (ListPreference) findPreference(getString(R.string.track_name_key));
|
ListPreference preference = (ListPreference) findPreference(getString(R.string.track_name_key));
|
||||||
String value = PreferencesUtils.getString(
|
String value = PreferencesUtils.getString(
|
||||||
@@ -82,6 +84,7 @@ public class RecordingSettingsActivity extends AbstractSettingsActivity {
|
|||||||
configureListPreference(preference, options, options, values, value, null);
|
configureListPreference(preference, options, options, values, value, null);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@SuppressWarnings("deprecation")
|
||||||
private void configDefaultActivity() {
|
private void configDefaultActivity() {
|
||||||
Preference preference = findPreference(getString(R.string.default_activity_key));
|
Preference preference = findPreference(getString(R.string.default_activity_key));
|
||||||
String value = PreferencesUtils.getString(
|
String value = PreferencesUtils.getString(
|
||||||
@@ -101,6 +104,7 @@ public class RecordingSettingsActivity extends AbstractSettingsActivity {
|
|||||||
: getString(R.string.value_unknown));
|
: getString(R.string.value_unknown));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@SuppressWarnings("deprecation")
|
||||||
private void configListPreference(
|
private void configListPreference(
|
||||||
int key, int defaultValue, int valueArray, boolean metricUnits) {
|
int key, int defaultValue, int valueArray, boolean metricUnits) {
|
||||||
ListPreference preference = (ListPreference) findPreference(getString(key));
|
ListPreference preference = (ListPreference) findPreference(getString(key));
|
||||||
|
|||||||
@@ -69,6 +69,7 @@ public class SensorSettingsActivity extends AbstractSettingsActivity {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@SuppressWarnings("deprecation")
|
||||||
private void configSensorType(boolean hasAntSupport) {
|
private void configSensorType(boolean hasAntSupport) {
|
||||||
ListPreference preference = (ListPreference) findPreference(
|
ListPreference preference = (ListPreference) findPreference(
|
||||||
getString(R.string.sensor_type_key));
|
getString(R.string.sensor_type_key));
|
||||||
|
|||||||
@@ -54,6 +54,7 @@ public class SettingsActivity extends AbstractSettingsActivity {
|
|||||||
* @param key the preference key
|
* @param key the preference key
|
||||||
* @param cl the class to start the new activity
|
* @param cl the class to start the new activity
|
||||||
*/
|
*/
|
||||||
|
@SuppressWarnings("deprecation")
|
||||||
private void configPreference(int key, final Class<?> cl) {
|
private void configPreference(int key, final Class<?> cl) {
|
||||||
Preference preference = findPreference(getString(key));
|
Preference preference = findPreference(getString(key));
|
||||||
preference.setOnPreferenceClickListener(new OnPreferenceClickListener() {
|
preference.setOnPreferenceClickListener(new OnPreferenceClickListener() {
|
||||||
|
|||||||
@@ -16,7 +16,6 @@
|
|||||||
package com.google.android.apps.mytracks.endtoendtest;
|
package com.google.android.apps.mytracks.endtoendtest;
|
||||||
|
|
||||||
import com.google.android.apps.mytracks.Constants;
|
import com.google.android.apps.mytracks.Constants;
|
||||||
import com.google.android.apps.mytracks.io.fusiontables.SendFusionTablesUtils;
|
|
||||||
import com.google.android.apps.mytracks.io.gdata.GDataClientFactory;
|
import com.google.android.apps.mytracks.io.gdata.GDataClientFactory;
|
||||||
import com.google.android.apps.mytracks.io.gdata.maps.MapFeatureEntry;
|
import com.google.android.apps.mytracks.io.gdata.maps.MapFeatureEntry;
|
||||||
import com.google.android.apps.mytracks.io.gdata.maps.MapsClient;
|
import com.google.android.apps.mytracks.io.gdata.maps.MapsClient;
|
||||||
@@ -81,6 +80,7 @@ public class GoogleUtils {
|
|||||||
|
|
||||||
private static final String APP_NAME_PREFIX = "Google-MyTracks-";
|
private static final String APP_NAME_PREFIX = "Google-MyTracks-";
|
||||||
private static final String CONTENT_TYPE = "application/x-www-form-urlencoded";
|
private static final String CONTENT_TYPE = "application/x-www-form-urlencoded";
|
||||||
|
private static final String FUSION_TABLES_SERVICE = "fusiontables";
|
||||||
private static final String FUSION_TABLES_BASE_URL = "https://www.google.com/fusiontables/api/query";
|
private static final String FUSION_TABLES_BASE_URL = "https://www.google.com/fusiontables/api/query";
|
||||||
private static final String GDATA_VERSION = "2";
|
private static final String GDATA_VERSION = "2";
|
||||||
private static final String WORK_SHEET_NAME = "Log";
|
private static final String WORK_SHEET_NAME = "Log";
|
||||||
@@ -409,7 +409,7 @@ public class GoogleUtils {
|
|||||||
private static HttpResponse sendFusionTableQuery(String query, Context context) {
|
private static HttpResponse sendFusionTableQuery(String query, Context context) {
|
||||||
try {
|
try {
|
||||||
String fusionTableAuthToken = AccountManager.get(context).blockingGetAuthToken(
|
String fusionTableAuthToken = AccountManager.get(context).blockingGetAuthToken(
|
||||||
getAccount(context), SendFusionTablesUtils.SERVICE, false);
|
getAccount(context), FUSION_TABLES_SERVICE, false);
|
||||||
|
|
||||||
GenericUrl url = new GenericUrl(FUSION_TABLES_BASE_URL);
|
GenericUrl url = new GenericUrl(FUSION_TABLES_BASE_URL);
|
||||||
String sql = "sql=" + query;
|
String sql = "sql=" + query;
|
||||||
|
|||||||
Reference in New Issue
Block a user