diff options
| author | Matthew Parlane <parlane@gmail.com> | 2016-05-07 19:47:13 +1200 |
|---|---|---|
| committer | Matthew Parlane <parlane@gmail.com> | 2016-05-07 19:47:13 +1200 |
| commit | 461a48f8e38101e757f18a1d3b8d04c6ddfea336 (patch) | |
| tree | 5974178190f2f35e702b0f549acfa06a5cdac58f /Source/Core/DolphinWX/NetPlay/NetWindow.cpp | |
| parent | 48237b38e89abc833e6052bd95646d9d93c73694 (diff) | |
| parent | 453d7777e5e8cdb186561bb20faa5ab6b6f1a9a9 (diff) | |
Merge pull request #3820 from Lionel07/netplay-elf-title-regression
Fix regression for .elf files in Netplay Game Selector
Diffstat (limited to 'Source/Core/DolphinWX/NetPlay/NetWindow.cpp')
| -rw-r--r-- | Source/Core/DolphinWX/NetPlay/NetWindow.cpp | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/Source/Core/DolphinWX/NetPlay/NetWindow.cpp b/Source/Core/DolphinWX/NetPlay/NetWindow.cpp index 61a59b1460..9274b2b9aa 100644 --- a/Source/Core/DolphinWX/NetPlay/NetWindow.cpp +++ b/Source/Core/DolphinWX/NetPlay/NetWindow.cpp @@ -80,6 +80,8 @@ static std::string BuildGameName(const GameListItem& game) } std::string name(game.GetName(lang)); + if (name.empty()) + name = game.GetName(); int disc_number = game.GetDiscNumber() + 1; @@ -92,16 +94,12 @@ static std::string BuildGameName(const GameListItem& game) std::string disc_text = "Disc "; info.push_back(disc_text + std::to_string(disc_number)); } - if (info.empty()) return name; - else - { - std::ostringstream ss; - std::copy(info.begin(), info.end() -1, std::ostream_iterator<std::string>(ss, ", ")); - ss << info.back(); - return name + " (" + ss.str() + ")"; - } + std::ostringstream ss; + std::copy(info.begin(), info.end() -1, std::ostream_iterator<std::string>(ss, ", ")); + ss << info.back(); + return name + " (" + ss.str() + ")"; } void NetPlayDialog::FillWithGameNames(wxListBox* game_lbox, const CGameListCtrl& game_list) |
