mirror of
https://codeberg.org/comaps/comaps
synced 2025-12-23 06:33:42 +00:00
[android-auto] Fix RouteSimulationProvider
Signed-off-by: Andrei Shkrob <andrei@shkrob.dev>
This commit is contained in:
committed by
Konstantin Pastbin
parent
0c4694a2cf
commit
8badd445db
@@ -2,6 +2,7 @@ package app.organicmaps.location;
|
||||
|
||||
import android.content.Context;
|
||||
import android.location.Location;
|
||||
import android.os.SystemClock;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
|
||||
@@ -57,6 +58,7 @@ class RouteSimulationProvider extends BaseLocationProvider
|
||||
location.setLatitude(mPoints[mCurrentPoint].mLat);
|
||||
location.setLongitude(mPoints[mCurrentPoint].mLon);
|
||||
location.setAccuracy(1.0f);
|
||||
location.setElapsedRealtimeNanos(SystemClock.elapsedRealtimeNanos());
|
||||
mListener.onLocationChanged(location);
|
||||
mCurrentPoint += 1;
|
||||
UiThread.runLater(this::nextPoint, INTERVAL_MS);
|
||||
|
||||
Reference in New Issue
Block a user