From b7453581a401fb57eb52edddcb27ea048a9c7389 Mon Sep 17 00:00:00 2001 From: Leonard Kugis Date: Thu, 4 Jan 2024 02:40:18 +0100 Subject: Removed unused code --- .../domain/usecases/FakeLocationStateUseCase.kt | 24 ---------------------- 1 file changed, 24 deletions(-) (limited to 'app/src/main') diff --git a/app/src/main/java/foundation/e/advancedprivacy/domain/usecases/FakeLocationStateUseCase.kt b/app/src/main/java/foundation/e/advancedprivacy/domain/usecases/FakeLocationStateUseCase.kt index 1f92554..49b9317 100644 --- a/app/src/main/java/foundation/e/advancedprivacy/domain/usecases/FakeLocationStateUseCase.kt +++ b/app/src/main/java/foundation/e/advancedprivacy/domain/usecases/FakeLocationStateUseCase.kt @@ -82,30 +82,6 @@ class FakeLocationStateUseCase( permissionsModule.toggleDangerousPermission(appDesc, android.Manifest.permission.ACCESS_FINE_LOCATION, true) } - // private fun applySettings(isEnabled: Boolean, isSpecificLocation: Boolean = false) { - // _configuredLocationMode.value = computeLocationMode(isEnabled, - // localStateRepository.locationMode, - // localStateRepository.fakeAltitude, - // localStateRepository.fakeSpeed, - // localStateRepository.fakeJitter, - // localStateRepository.fakeLocation, - // localStateRepository.routeLoopEnabled, - // isSpecificLocation) - - // if (isEnabled && hasAcquireMockLocationPermission()) { - // fakeLocationModule.startFakeLocation() - // localStateRepository.setLocationMode(configuredLocationMode.value.mode) - // fakeLocationModule.setFakeLocation(localStateRepository.fakeAltitude.toDouble(), - // localStateRepository.fakeSpeed, - // localStateRepository.fakeJitter, - // localStateRepository.fakeLocation.first.toDouble(), - // localStateRepository.fakeLocation.second.toDouble()) - // } else { - // fakeLocationModule.stopFakeLocation() - // localStateRepository.setLocationMode(LocationMode.REAL_LOCATION) - // } - // } - private fun hasAcquireMockLocationPermission(): Boolean { return (permissionsModule.getAppOpMode(appDesc, AppOpsManager.OPSTR_MOCK_LOCATION) == AppOpModes.ALLOWED) || permissionsModule.setAppOpMode(appDesc, AppOpsManager.OPSTR_MOCK_LOCATION, AppOpModes.ALLOWED) -- cgit v1.2.1