Skip to content

Commit

Permalink
Qt: show all unique game data entries
Browse files Browse the repository at this point in the history
  • Loading branch information
Megamouse committed May 5, 2019
1 parent c1e245a commit f480ba1
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions rpcs3/rpcs3qt/game_list_frame.cpp
Expand Up @@ -401,8 +401,8 @@ void game_list_frame::Refresh(const bool fromDrive, const bool scrollAfter)
path_list.back().resize(path_list.back().find_last_not_of('/') + 1);
}

// Used to remove duplications from the list (serial -> set of cats)
std::map<std::string, std::set<std::string>> serial_cat;
// Used to remove duplications from the list (serial -> set of cat names)
std::map<std::string, std::set<std::string>> serial_cat_name;

QSet<QString> serials;

Expand Down Expand Up @@ -431,7 +431,7 @@ void game_list_frame::Refresh(const bool fromDrive, const bool scrollAfter)
game.attr = psf::get_integer(psf, "ATTRIBUTE", 0);

// Detect duplication
if (!serial_cat[game.serial].emplace(game.category).second)
if (!serial_cat_name[game.serial].emplace(game.category + game.name).second)
{
continue;
}
Expand Down Expand Up @@ -517,7 +517,13 @@ void game_list_frame::Refresh(const bool fromDrive, const bool scrollAfter)
{
LOG_ERROR(GENERAL, "Failed to update the displayed version numbers for title ID %s\n%s thrown: %s", entry->info.serial, typeid(e).name(), e.what());
}
break; // Next Entry

const std::string key = "GD" + other->info.name;
serial_cat_name[other->info.serial].erase(key);
if (!serial_cat_name[other->info.serial].count(key))
{
break;
}
}
}
}
Expand Down

0 comments on commit f480ba1

Please sign in to comment.