mirror of
https://github.com/GoldenCheetah/GoldenCheetah.git
synced 2026-02-13 08:08:42 +00:00
Fix but with prefence update and screen.
This commit is contained in:
@@ -11,7 +11,7 @@
|
||||
# used if you are only targeting Android 2.0 or later.) Make sure you
|
||||
# test thoroughly if you go this route.
|
||||
-optimizations code/simplification/arithmetic,code/simplification/cast,field/*,class/merging/*
|
||||
-optimizationpasses 6
|
||||
-optimizationpasses 24
|
||||
-allowaccessmodification
|
||||
-dontpreverify
|
||||
|
||||
|
||||
@@ -18,11 +18,12 @@ import android.widget.TextView;
|
||||
public class CurrentValuesAdapter extends BaseAdapter {
|
||||
private StartActivity context;
|
||||
|
||||
private int[] keys;
|
||||
private String[] values = new String[RideService.KEYS.length];
|
||||
private String[] keyLabels = new String[RideService.KEYS.length];
|
||||
private int size = 20;
|
||||
private boolean imperial = false;
|
||||
private int[] keys;
|
||||
private String[] values = new String[RideService.KEYS.length];
|
||||
private String[] keyLabels = new String[RideService.KEYS.length];
|
||||
private int size = 20;
|
||||
private boolean imperial = false;
|
||||
private SharedPreferences settings = null;
|
||||
|
||||
private GridView layout;
|
||||
|
||||
@@ -34,10 +35,11 @@ public class CurrentValuesAdapter extends BaseAdapter {
|
||||
layout.setVerticalSpacing(4);
|
||||
layout.setHorizontalSpacing(4);
|
||||
|
||||
SharedPreferences settings = PreferenceManager.getDefaultSharedPreferences(context);
|
||||
Set<String> sensors = settings.getStringSet(context.getString(R.string.PREF_TRACKING_SENSORS), null);
|
||||
size = Integer.valueOf(settings.getString(context.getString(R.string.PREF_TRACKING_SIZE), "20"));
|
||||
imperial = settings.getBoolean(context.getString(R.string.PREF_TRACKING_IMPERIAL_UNITS), false);
|
||||
settings = PreferenceManager.getDefaultSharedPreferences(context);
|
||||
Set<String> sensors = settings.getStringSet(context.getString(R.string.PREF_TRACKING_SENSORS), null);
|
||||
|
||||
size = Integer.valueOf(settings.getString(context.getString(R.string.PREF_TRACKING_SIZE), "20"));
|
||||
imperial = settings.getBoolean(context.getString(R.string.PREF_TRACKING_IMPERIAL_UNITS), false);
|
||||
|
||||
|
||||
if(sensors != null && sensors.size() > 0) {
|
||||
|
||||
@@ -8,6 +8,7 @@ import java.util.Timer;
|
||||
import java.util.TimerTask;
|
||||
|
||||
import com.dsi.ant.plugins.antplus.pcc.defines.DeviceType;
|
||||
import com.dsi.ant.plugins.utility.log.LogAnt;
|
||||
import com.ridelogger.formats.BaseFormat;
|
||||
import com.ridelogger.formats.JsonFormat;
|
||||
import com.ridelogger.listners.Base;
|
||||
@@ -223,6 +224,8 @@ public class RideService extends Service
|
||||
fileFormat.createFile();
|
||||
fileFormat.writeHeader();
|
||||
|
||||
LogAnt.setDebugLevel(LogAnt.DebugLevel.NONE, this);
|
||||
|
||||
final Set<String> pairedAnts = settings.getStringSet(getString(R.string.PREF_PAIRED_ANTS), null);
|
||||
|
||||
if(pairedAnts != null && !pairedAnts.isEmpty()){
|
||||
|
||||
@@ -11,6 +11,7 @@ import com.dsi.ant.plugins.antplus.pcc.defines.DeviceType;
|
||||
import com.dsi.ant.plugins.antplus.pcc.defines.RequestAccessResult;
|
||||
import com.dsi.ant.plugins.antplus.pccbase.MultiDeviceSearch;
|
||||
import com.dsi.ant.plugins.antplus.pccbase.MultiDeviceSearch.MultiDeviceSearchResult;
|
||||
import com.dsi.ant.plugins.utility.log.LogAnt;
|
||||
|
||||
import android.app.ActivityManager;
|
||||
import android.app.ActivityManager.RunningServiceInfo;
|
||||
@@ -168,6 +169,8 @@ public class SettingsActivity extends PreferenceActivity {
|
||||
|
||||
updateList(foundDevices);
|
||||
|
||||
LogAnt.setDebugLevel(LogAnt.DebugLevel.NONE, this.getActivity());
|
||||
|
||||
mCallback = new MultiDeviceSearch.SearchCallbacks(){
|
||||
public void onDeviceFound(final MultiDeviceSearchResult deviceFound)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user