diff --git a/Core/Config.cpp b/Core/Config.cpp index e2faaabd5f..ffaeba439e 100644 --- a/Core/Config.cpp +++ b/Core/Config.cpp @@ -554,7 +554,11 @@ void Config::Save() { void Config::AddRecent(const std::string &file) { for (auto str = recentIsos.begin(); str != recentIsos.end(); str++) { - if (*str == file) { +#ifdef _WIN32 + if (!strcmpIgnore(*str, file, "\\", "/")) { +#else + if (!strcmp(*str, file)) { +#endif recentIsos.erase(str); recentIsos.insert(recentIsos.begin(), file); if ((int)recentIsos.size() > iMaxRecent) diff --git a/UI/GameScreen.cpp b/UI/GameScreen.cpp index ff88db4917..6a509a25e6 100644 --- a/UI/GameScreen.cpp +++ b/UI/GameScreen.cpp @@ -211,7 +211,11 @@ UI::EventReturn GameScreen::OnCreateShortcut(UI::EventParams &e) { bool GameScreen::isRecentGame(std::string gamePath) { for (auto it = g_Config.recentIsos.begin(); it != g_Config.recentIsos.end(); ++it) { - if (!strcmp((*it).c_str(),gamePath.c_str())) +#ifdef _WIN32 + if (!strcmpIgnore((*it).c_str(), gamePath_.c_str(), "\\","/")) +#else + if (!strcmp((*it).c_str(), gamePath_)) +#endif return true; } return false; @@ -219,7 +223,11 @@ bool GameScreen::isRecentGame(std::string gamePath) { UI::EventReturn GameScreen::OnRemoveFromRecent(UI::EventParams &e) { for (auto it = g_Config.recentIsos.begin(); it != g_Config.recentIsos.end(); ++it) { - if (!strcmp((*it).c_str(),gamePath_.c_str())) { +#ifdef _WIN32 + if (!strcmpIgnore((*it).c_str(), gamePath_.c_str(), "\\","/")) { +#else + if (!strcmp((*it).c_str(), gamePath_)) { +#endif g_Config.recentIsos.erase(it); screenManager()->switchScreen(new MainScreen()); return UI::EVENT_DONE;