diff options
Diffstat (limited to 'src/core/Frontend.cpp')
-rw-r--r-- | src/core/Frontend.cpp | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/src/core/Frontend.cpp b/src/core/Frontend.cpp index 707184d5..bd72a15f 100644 --- a/src/core/Frontend.cpp +++ b/src/core/Frontend.cpp @@ -3730,8 +3730,13 @@ CMenuManager::LoadSettings() CFileMgr::SetDir(""); #ifdef LOAD_INI_SETTINGS - LoadINISettings(); - LoadINIControllerSettings(); // Calling that after LoadINISettings is important because of gSelectedJoystickName loading + if (LoadINISettings()) { + LoadINIControllerSettings(); + } else { + // no re3.ini, create it + SaveINISettings(); + SaveINIControllerSettings(); + } #endif m_PrefsVsync = m_PrefsVsyncDisp; @@ -3828,12 +3833,6 @@ CMenuManager::SaveSettings() CFileMgr::SetDir(""); #else - static bool firstTime = true; - // In other conditions we already call SaveINIControllerSettings explicitly. - if (firstTime) { - SaveINIControllerSettings(); - firstTime = false; - } SaveINISettings(); #endif } @@ -5605,6 +5604,9 @@ CMenuManager::SwitchMenuOnAndOff() #endif ShutdownJustMenu(); SaveSettings(); +#ifdef LOAD_INI_SETTINGS + SaveINIControllerSettings(); +#endif m_bStartUpFrontEndRequested = false; pControlEdit = nil; m_bShutDownFrontEndRequested = false; |