Fix gpx track values

This commit is contained in:
Victor Shcherb 2012-09-11 23:57:09 +02:00
parent 5fccc507e9
commit f67410f89e
2 changed files with 15 additions and 15 deletions

View file

@ -125,7 +125,7 @@ public class OsmandMonitoringPlugin extends OsmandPlugin implements LockInfoCont
cat.addPreference(activity.createCheckBoxPreference(settings.SAVE_TRACK_TO_GPX, R.string.save_track_to_gpx,
R.string.save_track_to_gpx_descrp));
cat.addPreference(activity.createTimeListPreference(settings.SAVE_TRACK_INTERVAL, SECONDS,
MINUTES, 1, R.string.save_track_interval, R.string.save_track_interval_descr));
MINUTES, 1000, R.string.save_track_interval, R.string.save_track_interval_descr));
cat = new PreferenceCategory(activity);
cat.setTitle(R.string.live_monitoring);
@ -134,7 +134,7 @@ public class OsmandMonitoringPlugin extends OsmandPlugin implements LockInfoCont
cat.addPreference(activity.createCheckBoxPreference(settings.LIVE_MONITORING, R.string.live_monitoring,
R.string.live_monitoring_descr));
cat.addPreference(activity.createTimeListPreference(settings.LIVE_MONITORING_INTERVAL, SECONDS,
MINUTES, 1, R.string.live_monitoring_interval, R.string.live_monitoring_interval_descr));
MINUTES, 1000, R.string.live_monitoring_interval, R.string.live_monitoring_interval_descr));
cat = new PreferenceCategory(activity);
cat.setTitle(R.string.monitor_preferences);

View file

@ -187,19 +187,19 @@ public class LockInfoControl {
}
});
for(int i=0; i<secondsLength +minutesLength - 1; i++) {
if(i < secondsLength) {
if(v.value <= seconds[i] * 1000) {
sp.setProgress(i);
break;
}
} else {
if(v.value <= minutes[i - secondsLength] * 1000 * 60) {
sp.setProgress(i);
break;
}
}
}
for (int i = 0; i < secondsLength + minutesLength - 1; i++) {
if (i < secondsLength) {
if (v.value <= seconds[i] * 1000) {
sp.setProgress(i);
break;
}
} else {
if (v.value <= minutes[i - secondsLength] * 1000 * 60) {
sp.setProgress(i);
break;
}
}
}
ll.setOrientation(LinearLayout.VERTICAL);
ll.addView(tv);