Bugfix: importing files without speed resulted in moving time 0s and max speed of 0.

Fixes #982.
This commit is contained in:
Dennis Guse
2021-10-16 23:33:46 +02:00
parent d8988663cb
commit 2f7a56bb17
3 changed files with 78 additions and 2 deletions
@@ -144,6 +144,8 @@ public class TrackImporter {
return 0;
});
adjustTrackPoints();
TrackStatisticsUpdater updater = new TrackStatisticsUpdater();
updater.addTrackPoints(trackPoints, recordingDistanceInterval);
track.setTrackStatistics(updater.getTrackStatistics());
@@ -151,7 +153,6 @@ public class TrackImporter {
Track.Id trackId = contentProviderUtils.insertTrack(track);
// Store TrackPoints
adjustTrackPoints();
contentProviderUtils.bulkInsertTrackPoint(trackPoints, trackId);
// Store Markers