fix for future use when new track recording starts
This commit is contained in:
parent
fb3820f907
commit
162182a8ee
1 changed files with 6 additions and 3 deletions
|
@ -100,12 +100,15 @@ public class GpxBlockStatisticsBuilder {
|
|||
GPXFile gpxFile = getGPXFile();
|
||||
GpxDisplayItem gpxDisplayItem = null;
|
||||
GPXTrackAnalysis analysis = null;
|
||||
boolean withoutGaps = false;
|
||||
if (gpxFile.tracks.size() > 0) {
|
||||
gpxDisplayItem = getDisplayItem(gpxFile);
|
||||
analysis = gpxDisplayItem.analysis;
|
||||
}
|
||||
if (gpxDisplayItem != null && analysis != null) {
|
||||
boolean withoutGaps = !selectedGpxFile.isJoinSegments() && gpxDisplayItem.isGeneralTrack();
|
||||
if (gpxDisplayItem != null) {
|
||||
analysis = gpxDisplayItem.analysis;
|
||||
withoutGaps = !selectedGpxFile.isJoinSegments() && gpxDisplayItem.isGeneralTrack();
|
||||
}
|
||||
if (analysis != null) {
|
||||
float totalDistance = withoutGaps ? analysis.totalDistanceWithoutGaps : analysis.totalDistance;
|
||||
float timeSpan = withoutGaps ? analysis.timeSpanWithoutGaps : analysis.timeSpan;
|
||||
String asc = OsmAndFormatter.getFormattedAlt(analysis.diffElevationUp, app);
|
||||
|
|
Loading…
Reference in a new issue