From cf44be1de6bbfcbd92e765621bece91d2391714e Mon Sep 17 00:00:00 2001 From: Charles Lombardo Date: Tue, 26 Sep 2023 13:55:17 -0400 Subject: [PATCH] android: Adjust failure dialogs for user data and firmware installers --- .../java/org/yuzu/yuzu_emu/ui/main/MainActivity.kt | 12 ++++++++++-- src/android/app/src/main/res/values/strings.xml | 4 +++- 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/src/android/app/src/main/java/org/yuzu/yuzu_emu/ui/main/MainActivity.kt b/src/android/app/src/main/java/org/yuzu/yuzu_emu/ui/main/MainActivity.kt index 0cb701476..0cef6072b 100644 --- a/src/android/app/src/main/java/org/yuzu/yuzu_emu/ui/main/MainActivity.kt +++ b/src/android/app/src/main/java/org/yuzu/yuzu_emu/ui/main/MainActivity.kt @@ -676,7 +676,11 @@ class MainActivity : AppCompatActivity(), ThemeProvider { } } if (!isYuzuBackup) { - return@newInstance getString(R.string.invalid_yuzu_backup) + return@newInstance MessageDialogFragment.newInstance( + this, + titleId = R.string.invalid_yuzu_backup, + descriptionId = R.string.user_data_import_failed_description + ) } // Clear existing user data @@ -689,7 +693,11 @@ class MainActivity : AppCompatActivity(), ThemeProvider { File(DirectoryInitialization.userDirectory!!) ) } catch (e: Exception) { - return@newInstance getString(R.string.invalid_yuzu_backup) + return@newInstance MessageDialogFragment.newInstance( + this, + titleId = R.string.import_failed, + descriptionId = R.string.user_data_import_failed_description + ) } // Reinitialize relevant data diff --git a/src/android/app/src/main/res/values/strings.xml b/src/android/app/src/main/res/values/strings.xml index 485d4c1dd..44845bfbf 100644 --- a/src/android/app/src/main/res/values/strings.xml +++ b/src/android/app/src/main/res/values/strings.xml @@ -100,7 +100,7 @@ Installing firmware Firmware installed successfully Firmware installation failed - Verify that the ZIP contains valid firmware and try again. + Make sure the firmware nca files are at the root of the zip and try again. Share debug logs Share yuzu\'s log file to debug issues No log file found @@ -140,6 +140,7 @@ User data exported successfully User data imported successfully Export cancelled + Make sure the user data folders are at the root of the zip folder and contain a config file at config/config.ini and try again. https://discord.gg/u77vRWY https://yuzu-emu.org/ https://github.com/yuzu-emu @@ -230,6 +231,7 @@ Import Export Export failed + Import failed Cancelling