From ad7473c2d365b1b64afeb2632bebc41ac084f74a Mon Sep 17 00:00:00 2001 From: Sanjay Prajapati <82382452+sanjay-mi@users.noreply.github.com> Date: Thu, 3 Mar 2022 14:51:56 +0530 Subject: [PATCH] Develop (#51) * fix map inflate. * update version to 0.2.1 * feedback changes Co-authored-by: Nkgohil --- vanillaplacepicker/build.gradle | 2 +- .../presentation/map/VanillaMapActivity.kt | 7 ++++++- .../src/main/res/layout/activity_vanilla_map.xml | 5 +++-- vanillaplacepicker/src/main/res/layout/custom_toolbar.xml | 2 +- vanillaplacepicker/src/main/res/values-ar/strings.xml | 1 - vanillaplacepicker/src/main/res/values-es/strings.xml | 1 + vanillaplacepicker/src/main/res/values-hi/strings.xml | 1 + vanillaplacepicker/src/main/res/values/strings.xml | 1 - 8 files changed, 13 insertions(+), 7 deletions(-) diff --git a/vanillaplacepicker/build.gradle b/vanillaplacepicker/build.gradle index 4c4a670..bcf1434 100644 --- a/vanillaplacepicker/build.gradle +++ b/vanillaplacepicker/build.gradle @@ -11,7 +11,7 @@ android { minSdkVersion 19 targetSdkVersion 32 versionCode 14 - versionName "0.2.0" + versionName "0.2.1" testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner" vectorDrawables.useSupportLibrary = true } diff --git a/vanillaplacepicker/src/main/java/com/vanillaplacepicker/presentation/map/VanillaMapActivity.kt b/vanillaplacepicker/src/main/java/com/vanillaplacepicker/presentation/map/VanillaMapActivity.kt index 4c48c27..a1f76ad 100644 --- a/vanillaplacepicker/src/main/java/com/vanillaplacepicker/presentation/map/VanillaMapActivity.kt +++ b/vanillaplacepicker/src/main/java/com/vanillaplacepicker/presentation/map/VanillaMapActivity.kt @@ -397,7 +397,12 @@ class VanillaMapActivity : VanillaBaseViewModelActivity(), // If user interaction was interrupted, the permission request is cancelled and you receive empty arrays. Log.d(TAG, resources.getString(R.string.user_interaction_was_cancelled)) } - grantResults[0] == PackageManager.PERMISSION_GRANTED -> startLocationUpdates() + grantResults[0] == PackageManager.PERMISSION_GRANTED -> { + if (!isRequestedWithLocation) { + startLocationUpdates() + } + + } else -> showAlertDialog( R.string.missing_permission_message, R.string.missing_permission_title, diff --git a/vanillaplacepicker/src/main/res/layout/activity_vanilla_map.xml b/vanillaplacepicker/src/main/res/layout/activity_vanilla_map.xml index 305b8a2..9648a63 100644 --- a/vanillaplacepicker/src/main/res/layout/activity_vanilla_map.xml +++ b/vanillaplacepicker/src/main/res/layout/activity_vanilla_map.xml @@ -2,9 +2,10 @@ + android:layout_height="match_parent" + android:theme="@style/Theme.MaterialComponents.DayNight.DarkActionBar"> - - حسنا إلغاء الإذن - الإذن… diff --git a/vanillaplacepicker/src/main/res/values-es/strings.xml b/vanillaplacepicker/src/main/res/values-es/strings.xml index 4ea3da6..b143397 100644 --- a/vanillaplacepicker/src/main/res/values-es/strings.xml +++ b/vanillaplacepicker/src/main/res/values-es/strings.xml @@ -22,6 +22,7 @@ Cancelar Permiso + Buscando… diff --git a/vanillaplacepicker/src/main/res/values-hi/strings.xml b/vanillaplacepicker/src/main/res/values-hi/strings.xml index b8c2b39..ccb86bd 100644 --- a/vanillaplacepicker/src/main/res/values-hi/strings.xml +++ b/vanillaplacepicker/src/main/res/values-hi/strings.xml @@ -22,6 +22,7 @@ रद्द करना अनुमति + खोज कर… diff --git a/vanillaplacepicker/src/main/res/values/strings.xml b/vanillaplacepicker/src/main/res/values/strings.xml index ad515c9..3567d3e 100644 --- a/vanillaplacepicker/src/main/res/values/strings.xml +++ b/vanillaplacepicker/src/main/res/values/strings.xml @@ -19,7 +19,6 @@ OK Cancel Permission - Searching…