ISO: Move game size assignment to size_calc_func in game_list_table.cpp

This commit is contained in:
Functionable 2026-01-07 18:51:01 +00:00 committed by Elad
parent 407cbf9690
commit bc1d0b9e65
2 changed files with 7 additions and 8 deletions

View file

@ -538,14 +538,6 @@ void game_list_frame::OnParsingFinished()
gui_game_info game{};
game.info.path = dir_or_elf;
if (archive)
{
fs::stat_t iso_stat;
fs::get_stat(game.info.path, iso_stat);
game.info.size_on_disk = iso_stat.size;
}
const Localized thread_localized;
const std::string sfo_dir = !archive ? rpcs3::utils::get_sfo_dir_from_game_path(dir_or_elf) : "PS3_GAME";

View file

@ -285,6 +285,13 @@ void game_list_table::populate(
// Do not report size of apps inside /dev_flash (it does not make sense to do so)
game->info.size_on_disk = 0;
}
else if(is_file_iso(game->info.path))
{
fs::stat_t iso_stat;
fs::get_stat(game->info.path, iso_stat);
game->info.size_on_disk = iso_stat.size;
}
else
{
game->info.size_on_disk = fs::get_dir_size(game->info.path, 1, cancel.get());