diff --git a/app/src/main/java/me/tsukanov/counter/activities/MainActivity.java b/app/src/main/java/me/tsukanov/counter/activities/MainActivity.java index f338b3b2..348eae15 100644 --- a/app/src/main/java/me/tsukanov/counter/activities/MainActivity.java +++ b/app/src/main/java/me/tsukanov/counter/activities/MainActivity.java @@ -244,29 +244,22 @@ private boolean isInstalledViaGooglePlay(@NonNull final Context context) { @SuppressWarnings("checkstyle:linelength") private void showGooglePlayDialog() { final SpannableString message = - new SpannableString( - """ - Apologies for the interruption. - - In January 2025 my developer account will most likely be suspended and this app will be delisted from the Google Play Store due to policy changes. I'm now required to list my home address, which I'm not willing to do. - - You can still get this app from F-Droid, GitHub and other sources. Go to https://counter.roman.zone for details. - - Thank you for using the app! You will only see this message once. - """); + new SpannableString(getResources().getString(R.string.dialog_playstore_content)); Linkify.addLinks(message, Linkify.ALL); final AlertDialog d = new AlertDialog.Builder(this) - .setTitle("A note from the developer") + .setTitle(R.string.dialog_playstore_title) .setMessage(message) .setPositiveButton( - "I understand", + R.string.dialog_playstore_button, (dialog, id) -> { - sharedPrefs.edit() - .putBoolean(SharedPrefKeys.GOOGLE_PLAY_WARNING.getName(), true) - .apply(); - Toast.makeText(getBaseContext(), "Thanks for using the app.", Toast.LENGTH_SHORT) + sharedPrefs + .edit() + .putBoolean(SharedPrefKeys.GOOGLE_PLAY_WARNING.getName(), true) + .apply(); + Toast.makeText( + getBaseContext(), R.string.dialog_playstore_toast, Toast.LENGTH_SHORT) .show(); }) .create(); diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index 77be9b25..264ebc29 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -27,6 +27,18 @@ Reset Delete Cancel + I understand + A note from the developer + + Apologies for the interruption. + \n\n + In January 2025 my developer account will most likely be suspended and this app will be delisted from the Google Play Store due to policy changes. I\'m now required to list my home address, which I\'m not willing to do. + \n\n + You can still get this app from F-Droid, GitHub and other sources. Go to https://counter.roman.zone for details. + \n\n + Thank you for using the app! You will only see this message once. + + Thanks for using the app! Settings