very important button

This commit is contained in:
qimiko committed 2024-06-16 04:39:18 -07:00
1 parent 0c551c8276
commit f801993d0e
1 file changed
+15 -2
@@ -310,14 +310,26 @@ fun LaunchProgressCard(
inProgress = uiState.inProgress inProgress = uiState.inProgress
) )
Row(horizontalArrangement = Arrangement.spacedBy(8.dp)) { if (uiState.reason == LaunchViewModel.LaunchCancelReason.GAME_OUTDATED) {
val context = LocalContext.current
// game should be downloaded if this message is showing
val showDownload = remember {
!GamePackageUtils.identifyGameLegitimacy(context.packageManager)
}
if (showDownload) {
GooglePlayBadge(modifier = Modifier.align(Alignment.CenterHorizontally))
}
}
if (uiState.reason.allowsRetry()) { if (uiState.reason.allowsRetry()) {
Row(horizontalArrangement = Arrangement.spacedBy(8.dp)) {
LongPressButton(onClick = { onResume(false) }, onLongPress = { LongPressButton(onClick = { onResume(false) }, onLongPress = {
showSafeModeDialog = true showSafeModeDialog = true
}) { }) {
RetryButtonContents(uiState.reason) RetryButtonContents(uiState.reason)
} }
}
if (crashInfo != null) { if (crashInfo != null) {
FilledTonalButton(onClick = onMore) { FilledTonalButton(onClick = onMore) {
@@ -330,6 +342,7 @@ fun LaunchProgressCard(
} }
} }
} }
}
} else { } else {
LaunchProgressBody(statusInfo = status) LaunchProgressBody(statusInfo = status)