From 1563a4fb0ef51ca96680b78ced76cdf6d2aee320 Mon Sep 17 00:00:00 2001 From: tibbi Date: Wed, 3 Apr 2019 18:26:04 +0200 Subject: [PATCH] show an Upgraded From Free version dialog with some explanation when appropriate --- .gitignore | 1 - app/build.gradle | 2 +- .../calendar/pro/activities/MainActivity.kt | 6 ++++++ 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index 660f31f5d..4cd1c5eed 100644 --- a/.gitignore +++ b/.gitignore @@ -2,7 +2,6 @@ *.aab .gradle /local.properties -/gradle.properties /.idea/ .DS_Store /build diff --git a/app/build.gradle b/app/build.gradle index c9e771d68..ced4c0b69 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -57,7 +57,7 @@ android { } dependencies { - implementation 'com.simplemobiletools:commons:5.10.15' + implementation 'com.simplemobiletools:commons:5.11.0' implementation 'joda-time:joda-time:2.10.1' implementation 'androidx.multidex:multidex:2.0.1' implementation 'androidx.constraintlayout:constraintlayout:2.0.0-alpha3' diff --git a/app/src/main/kotlin/com/simplemobiletools/calendar/pro/activities/MainActivity.kt b/app/src/main/kotlin/com/simplemobiletools/calendar/pro/activities/MainActivity.kt index d592a2a7d..8130d6dd7 100644 --- a/app/src/main/kotlin/com/simplemobiletools/calendar/pro/activities/MainActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/calendar/pro/activities/MainActivity.kt @@ -35,6 +35,7 @@ import com.simplemobiletools.calendar.pro.jobs.CalDAVUpdateListener import com.simplemobiletools.calendar.pro.models.Event import com.simplemobiletools.calendar.pro.models.EventType import com.simplemobiletools.calendar.pro.models.ListEvent +import com.simplemobiletools.commons.dialogs.ConfirmationDialog import com.simplemobiletools.commons.dialogs.FilePickerDialog import com.simplemobiletools.commons.dialogs.RadioGroupDialog import com.simplemobiletools.commons.extensions.* @@ -107,6 +108,11 @@ class MainActivity : SimpleActivity(), RefreshRecyclerViewListener { if (savedInstanceState == null) { checkCalDAVUpdateListener() } + + if (!config.wasUpgradedFromFreeShown && isPackageInstalled("com.simplemobiletools.calendar")) { + ConfirmationDialog(this, "", R.string.upgraded_from_free, R.string.ok, 0) {} + config.wasUpgradedFromFreeShown = true + } } override fun onResume() {