Block itch updates while the game is being uninstalled

This commit is contained in:
FX192 committed 2026-10-28 02:13:48 +03:00
1 parent ab130c7754
commit 0e173ed05a
2 files changed
+2 -1

No files matched your search

@@ -160,6 +160,7 @@ internal object ItchUpdates {
fun start(context: Context, game: InstalledStoreGame, update: ItchUpdate) {
val app = context.applicationContext
if (StoresState.uninstalling.containsKey(game.key)) return
val root = game.folder.parentFile?.parentFile ?: return
val extra = game.sidecar.extra + ("uploadId" to update.uploadId)
val item = CatalogItem(
@@ -362,7 +362,7 @@ internal fun GameActions(
GameShortcutMenu(game, a)
EditArtButton(game)
}
if (store == Store.ITCH && installed != null) ItchUpdateButton(installed, download == null)
if (store == Store.ITCH && installed != null) ItchUpdateButton(installed, download == null && StoresState.uninstalling[installed.key] == null)
if (store == Store.XBOX && id != null) XboxInstalledStream(id, game?.name ?: item?.title.orEmpty(), item)
if (store == Store.XBOX && installed != null && id != null) {
SecondaryButton(stringResource(R.string.stores_xbox_update), enabled = download == null && !XboxRuntime.isActive(id)) {