diff options
| author | 2024-01-10 13:09:21 -0500 | |
|---|---|---|
| committer | 2024-01-10 23:14:04 -0500 | |
| commit | 9e974d4c7e44b1067a5c71c56b172eb15c75e43f (patch) | |
| tree | 1bdfe649f8a861b6ce75aa35d8789be34cc779eb | |
| parent | android: Rework driver fragment (diff) | |
| download | yuzu-9e974d4c7e44b1067a5c71c56b172eb15c75e43f.tar.gz yuzu-9e974d4c7e44b1067a5c71c56b172eb15c75e43f.tar.xz yuzu-9e974d4c7e44b1067a5c71c56b172eb15c75e43f.zip | |
android: Reload driver data on importing user data
| -rw-r--r-- | src/android/app/src/main/java/org/yuzu/yuzu_emu/ui/main/MainActivity.kt | 3 |
1 files changed, 3 insertions, 0 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 622ae996e..644289e25 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 | |||
| @@ -41,6 +41,7 @@ import org.yuzu.yuzu_emu.fragments.AddGameFolderDialogFragment | |||
| 41 | import org.yuzu.yuzu_emu.fragments.IndeterminateProgressDialogFragment | 41 | import org.yuzu.yuzu_emu.fragments.IndeterminateProgressDialogFragment |
| 42 | import org.yuzu.yuzu_emu.fragments.MessageDialogFragment | 42 | import org.yuzu.yuzu_emu.fragments.MessageDialogFragment |
| 43 | import org.yuzu.yuzu_emu.model.AddonViewModel | 43 | import org.yuzu.yuzu_emu.model.AddonViewModel |
| 44 | import org.yuzu.yuzu_emu.model.DriverViewModel | ||
| 44 | import org.yuzu.yuzu_emu.model.GamesViewModel | 45 | import org.yuzu.yuzu_emu.model.GamesViewModel |
| 45 | import org.yuzu.yuzu_emu.model.HomeViewModel | 46 | import org.yuzu.yuzu_emu.model.HomeViewModel |
| 46 | import org.yuzu.yuzu_emu.model.TaskState | 47 | import org.yuzu.yuzu_emu.model.TaskState |
| @@ -58,6 +59,7 @@ class MainActivity : AppCompatActivity(), ThemeProvider { | |||
| 58 | private val gamesViewModel: GamesViewModel by viewModels() | 59 | private val gamesViewModel: GamesViewModel by viewModels() |
| 59 | private val taskViewModel: TaskViewModel by viewModels() | 60 | private val taskViewModel: TaskViewModel by viewModels() |
| 60 | private val addonViewModel: AddonViewModel by viewModels() | 61 | private val addonViewModel: AddonViewModel by viewModels() |
| 62 | private val driverViewModel: DriverViewModel by viewModels() | ||
| 61 | 63 | ||
| 62 | override var themeId: Int = 0 | 64 | override var themeId: Int = 0 |
| 63 | 65 | ||
| @@ -689,6 +691,7 @@ class MainActivity : AppCompatActivity(), ThemeProvider { | |||
| 689 | NativeLibrary.initializeSystem(true) | 691 | NativeLibrary.initializeSystem(true) |
| 690 | NativeConfig.initializeGlobalConfig() | 692 | NativeConfig.initializeGlobalConfig() |
| 691 | gamesViewModel.reloadGames(false) | 693 | gamesViewModel.reloadGames(false) |
| 694 | driverViewModel.reloadDriverData() | ||
| 692 | 695 | ||
| 693 | return@newInstance getString(R.string.user_data_import_success) | 696 | return@newInstance getString(R.string.user_data_import_success) |
| 694 | }.show(supportFragmentManager, IndeterminateProgressDialogFragment.TAG) | 697 | }.show(supportFragmentManager, IndeterminateProgressDialogFragment.TAG) |