Skip to content

Commit f76517c

Browse files
committed
[Sophon] Fix 0 total size on fallback to install mode
1 parent 5336976 commit f76517c

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

CollapseLauncher/Classes/InstallManagement/BaseClass/InstallManagerBase.Sophon.cs

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -300,9 +300,15 @@ await SimpleDialogs.Dialog_ChooseAudioLanguageChoice(
300300
_gameVersionManager.GamePreset.SetVoiceLanguageID(setAsDefaultVo);
301301

302302
// Get the remote total size and current total size
303-
_progressAllCountTotal = sophonInfoPairList.Sum(x => x.ChunksInfo.FilesCount);
304-
_progressAllSizeTotal = sophonInfoPairList.Sum(x => x.ChunksInfo.TotalSize);
305-
_progressAllSizeCurrent = 0;
303+
_progressAllCountTotal = sophonInfoPairList.Sum(x => x.ChunksInfo.FilesCount);
304+
_progressAllSizeTotal = sophonInfoPairList.Sum(x => x.ChunksInfo.TotalSize);
305+
_progressAllSizeCurrent = 0;
306+
307+
// If the fallback is used from update, use the same display as All Size for Per File progress.
308+
if (fallbackFromUpdate)
309+
{
310+
_progressPerFileSizeTotal = _progressAllSizeTotal;
311+
}
306312

307313
// Set the display to Install Mode
308314
UpdateStatus();

0 commit comments

Comments
 (0)