From f1dd47c0e2ca6c0702cf01d4f1b1b6597a1446df Mon Sep 17 00:00:00 2001 From: max-klaus Date: Wed, 13 Jan 2021 13:07:18 +0300 Subject: [PATCH] Drop location in tracker service (temp) 4' --- .../src/net/osmand/telegram/TelegramLocationProvider.kt | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/OsmAnd-telegram/src/net/osmand/telegram/TelegramLocationProvider.kt b/OsmAnd-telegram/src/net/osmand/telegram/TelegramLocationProvider.kt index 1b22fb1e36..dec07b1d43 100644 --- a/OsmAnd-telegram/src/net/osmand/telegram/TelegramLocationProvider.kt +++ b/OsmAnd-telegram/src/net/osmand/telegram/TelegramLocationProvider.kt @@ -87,6 +87,7 @@ class TelegramLocationProvider(private val app: TelegramApplication) : SensorEve @SuppressLint("MissingPermission") fun resumeAllUpdates() { + /* val service = app.getSystemService(Context.LOCATION_SERVICE) as LocationManager if (app.isInternetConnectionAvailable) { if (System.currentTimeMillis() - agpsDataLastTimeDownloaded > AGPS_TO_REDOWNLOAD) { @@ -134,7 +135,7 @@ class TelegramLocationProvider(private val app: TelegramApplication) : SensorEve } } - + */ registerOrUnregisterCompassListener(true) } @@ -391,12 +392,14 @@ class TelegramLocationProvider(private val app: TelegramApplication) : SensorEve } private fun stopLocationRequests() { + /* val service = app.getSystemService(Context.LOCATION_SERVICE) as LocationManager service.removeGpsStatusListener(gpsStatusListener) service.removeUpdates(gpsListener) while (!networkListeners.isEmpty()) { service.removeUpdates(networkListeners.poll()) } + */ } fun pauseAllUpdates() {