diff options
author | Abhishek Aggarwal <warabhishek@e.email> | 2022-05-25 07:00:48 +0000 |
---|---|---|
committer | Abhishek Aggarwal <warabhishek@e.email> | 2022-05-25 07:00:48 +0000 |
commit | c17c2b5b84d8ee7c627d95a17cbbc80b24f54958 (patch) | |
tree | a6dfb4895c93b00ddcf3d11fb4d0ae60a87e81f9 /app/src/main/java/foundation/e | |
parent | 8d39e10ba2613ac2583ec3c1a1f687c240e25550 (diff) | |
parent | 1b6b76879840955c5177125c94849ec0ff760c8b (diff) |
Merge branch '5444-main-lag' into 'main'
privacycentralapp: use io dispatcher for actors
See merge request e/privacy-central/privacycentralapp!62
Diffstat (limited to 'app/src/main/java/foundation/e')
-rw-r--r-- | app/src/main/java/foundation/e/privacycentralapp/domain/usecases/FakeLocationStateUseCase.kt | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/app/src/main/java/foundation/e/privacycentralapp/domain/usecases/FakeLocationStateUseCase.kt b/app/src/main/java/foundation/e/privacycentralapp/domain/usecases/FakeLocationStateUseCase.kt index a475aa2..c026275 100644 --- a/app/src/main/java/foundation/e/privacycentralapp/domain/usecases/FakeLocationStateUseCase.kt +++ b/app/src/main/java/foundation/e/privacycentralapp/domain/usecases/FakeLocationStateUseCase.kt @@ -23,6 +23,7 @@ import android.location.Location import android.location.LocationListener import android.location.LocationManager import android.os.Bundle +import android.os.Looper import android.util.Log import foundation.e.privacycentralapp.data.repositories.LocalStateRepository import foundation.e.privacycentralapp.domain.entities.LocationMode @@ -172,14 +173,9 @@ class FakeLocationStateUseCase( LocationManager.NETWORK_PROVIDER, // TODO: tight this with fakelocation module. 0L, 0f, - listener - ) - // locationManager.requestLocationUpdates( - // LocationManager.NETWORK_PROVIDER, // TODO: tight this with fakelocation module. - // 0L, - // 0f, - // listener - // ) + listener, + Looper.getMainLooper() + ) val location: Location? = locationManager.getLastKnownLocation(LocationManager.NETWORK_PROVIDER) location?.let { listener.onLocationChanged(it) } |