Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Qt: Fall back to VERSION in game list #6383

Merged
merged 1 commit into from
Aug 21, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions rpcs3/Emu/GameInfo.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ struct GameInfo
std::string name;
std::string serial;
std::string app_ver;
std::string version;
std::string category;
std::string fw;

Expand All @@ -31,6 +32,7 @@ struct GameInfo
name = "Unknown";
serial = "Unknown";
app_ver = "Unknown";
version = "Unknown";
category = "Unknown";
fw = "Unknown";

Expand Down
7 changes: 7 additions & 0 deletions rpcs3/rpcs3qt/game_list_frame.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -464,6 +464,7 @@ void game_list_frame::Refresh(const bool fromDrive, const bool scrollAfter)
game.serial = psf::get_string(psf, "TITLE_ID", "");
game.name = psf::get_string(psf, "TITLE", cat_unknown);
game.app_ver = psf::get_string(psf, "APP_VER", cat_unknown);
game.version = psf::get_string(psf, "VERSION", cat_unknown);
game.category = psf::get_string(psf, "CATEGORY", cat_unknown);
game.fw = psf::get_string(psf, "PS3_SYSTEM_VER", cat_unknown);
game.parental_lvl = psf::get_integer(psf, "PARENTAL_LEVEL", 0);
Expand Down Expand Up @@ -1803,6 +1804,12 @@ int game_list_frame::PopulateGameList()
// Version
QString app_version = qstr(game->info.app_ver);

if (app_version == category::unknown)
{
// Fall back to Disc/Pkg Revision
app_version = qstr(game->info.version);
}

if (!game->compat.version.isEmpty() && (app_version == category::unknown || game->compat.version.toDouble() > app_version.toDouble()))
{
app_version = tr("%0 (Update available: %1)").arg(app_version, game->compat.version);
Expand Down