mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-29 17:19:44 -06:00
Adds the option to change the path to the wii nand root
when nand root is changed the current sysconf is saved, and the sysconf in the new location is either loaded (if exists) or the default sysconf is created wii menu item is updated when the root changes small fix to saving gamelist paths to .ini paths that are removed from the gui are now removed from the ini instead of simply changing the number of paths git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7555 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
@ -132,16 +132,28 @@ void SConfig::SaveSettings()
|
||||
ini.Set("General", "LastFilename", m_LastFilename);
|
||||
|
||||
// ISO folders
|
||||
ini.Set("General", "GCMPathes", (int)m_ISOFolder.size());
|
||||
|
||||
for (size_t i = 0; i < m_ISOFolder.size(); i++)
|
||||
// clear removed folders
|
||||
int oldPaths,
|
||||
numPaths = (int)m_ISOFolder.size();
|
||||
ini.Get("General", "GCMPathes", &oldPaths, 0);
|
||||
for (int i = numPaths; i < oldPaths; i++)
|
||||
{
|
||||
TCHAR tmp[16];
|
||||
sprintf(tmp, "GCMPath%i", (int)i);
|
||||
sprintf(tmp, "GCMPath%i", i);
|
||||
ini.DeleteKey("General", tmp);
|
||||
}
|
||||
|
||||
ini.Set("General", "GCMPathes", numPaths);
|
||||
|
||||
for (int i = 0; i < numPaths; i++)
|
||||
{
|
||||
TCHAR tmp[16];
|
||||
sprintf(tmp, "GCMPath%i", i);
|
||||
ini.Set("General", tmp, m_ISOFolder[i]);
|
||||
}
|
||||
|
||||
ini.Set("General", "RecursiveGCMPaths", m_RecursiveISOFolder);
|
||||
ini.Set("General", "NANDRoot", m_NANDPath);
|
||||
|
||||
// Interface
|
||||
ini.Set("Interface", "ConfirmStop", m_LocalCoreStartupParameter.bConfirmStop);
|
||||
@ -263,6 +275,9 @@ void SConfig::LoadSettings()
|
||||
}
|
||||
|
||||
ini.Get("General", "RecursiveGCMPaths", &m_RecursiveISOFolder, false);
|
||||
|
||||
ini.Get("General", "NANDRoot", &m_NANDPath);
|
||||
m_NANDPath = File::GetUserPath(D_WIIROOT_IDX, m_NANDPath);
|
||||
}
|
||||
|
||||
{
|
||||
|
@ -43,6 +43,7 @@ struct SConfig : NonCopyable
|
||||
bool m_RecursiveISOFolder;
|
||||
|
||||
SCoreStartupParameter m_LocalCoreStartupParameter;
|
||||
std::string m_NANDPath;
|
||||
|
||||
std::string m_strMemoryCardA;
|
||||
std::string m_strMemoryCardB;
|
||||
|
Reference in New Issue
Block a user