mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-03-12 14:46:49 +01:00
- Bugfix: Don't allow for repeated paths in ISOfolder
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@1790 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
parent
fdd06da500
commit
d6ad009d7a
@ -111,10 +111,17 @@ void CGameListCtrl::BrowseForDirectory()
|
|||||||
|
|
||||||
if (dialog.ShowModal() == wxID_OK)
|
if (dialog.ShowModal() == wxID_OK)
|
||||||
{
|
{
|
||||||
SConfig::GetInstance().m_ISOFolder.push_back(
|
std::string sPath(dialog.GetPath().ToAscii());
|
||||||
std::string(dialog.GetPath().ToAscii())
|
std::vector<std::string>::iterator itResult = std::find(
|
||||||
|
SConfig::GetInstance().m_ISOFolder.begin(), SConfig::GetInstance().m_ISOFolder.end(), sPath
|
||||||
);
|
);
|
||||||
SConfig::GetInstance().SaveSettings();
|
|
||||||
|
if (itResult == SConfig::GetInstance().m_ISOFolder.end())
|
||||||
|
{
|
||||||
|
SConfig::GetInstance().m_ISOFolder.push_back(sPath);
|
||||||
|
SConfig::GetInstance().SaveSettings();
|
||||||
|
}
|
||||||
|
|
||||||
Update();
|
Update();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user