From 32a458a690e2e5bdedfb632e1f8ba74ed1ff4e70 Mon Sep 17 00:00:00 2001
From: rhunk <101876869+rhunk@users.noreply.github.com>
Date: Wed, 11 Oct 2023 16:53:53 +0200
Subject: [PATCH] refactor: location spoofer
---
app/src/main/AndroidManifest.xml | 4 -
.../me/rhunk/snapenhance/ui/MapActivity.kt | 98 ----------
.../sections/features/FeaturesSection.kt | 23 ++-
.../rhunk/snapenhance/ui/util/AlertDialogs.kt | 174 +++++++++++++++++-
app/src/main/res/layout/map.xml | 44 -----
.../res/layout/precise_location_dialog.xml | 28 ---
common/src/main/assets/lang/en_US.json | 24 +--
.../snapenhance/common/action/EnumAction.kt | 3 +-
.../common/config/ConfigContainer.kt | 6 +
.../common/config/DataProcessors.kt | 15 ++
.../snapenhance/common/config/impl/Global.kt | 4 +
.../snapenhance/common/config/impl/Spoof.kt | 6 -
.../snapenhance/core/action/impl/OpenMap.kt | 21 ---
.../features/impl/global/LocationSpoofer.kt | 43 ++---
.../core/manager/impl/ActionManager.kt | 2 -
15 files changed, 238 insertions(+), 257 deletions(-)
delete mode 100644 app/src/main/kotlin/me/rhunk/snapenhance/ui/MapActivity.kt
delete mode 100644 app/src/main/res/layout/map.xml
delete mode 100644 app/src/main/res/layout/precise_location_dialog.xml
delete mode 100644 core/src/main/kotlin/me/rhunk/snapenhance/core/action/impl/OpenMap.kt
diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml
index f5cdc94a..91ed83d4 100644
--- a/app/src/main/AndroidManifest.xml
+++ b/app/src/main/AndroidManifest.xml
@@ -52,10 +52,6 @@
android:exported="true"
android:theme="@style/AppTheme"
android:excludeFromRecents="true" />
-
(R.id.apply_location_button)
- applyButton.setOnClickListener {
- val bundle = Bundle()
- bundle.putFloat("latitude", marker.position.latitude.toFloat())
- bundle.putFloat("longitude", marker.position.longitude.toFloat())
- setResult(RESULT_OK, intent.putExtra("location", bundle))
- finish()
- }
-
- val setPreciseLocationButton = findViewById