mirror of
https://github.com/hrydgard/ppsspp.git
synced 2024-11-23 05:19:56 +00:00
NativeApp: Load config before processing flags (duh)
This commit is contained in:
parent
875f3569ee
commit
d56bc40db4
@ -32,30 +32,37 @@ public:
|
||||
CConfig();
|
||||
~CConfig();
|
||||
|
||||
// Many of these are currently broken.
|
||||
bool bEnableSound;
|
||||
bool bAutoLoadLast;
|
||||
// Whether to save the config on close.
|
||||
bool bSaveSettings;
|
||||
|
||||
// These are broken
|
||||
bool bAutoLoadLast;
|
||||
bool bFirstRun;
|
||||
bool bAutoRun;
|
||||
bool bSpeedLimit;
|
||||
bool bConfirmOnQuit;
|
||||
|
||||
// Core
|
||||
bool bIgnoreBadMemAccess;
|
||||
bool bFastMemory;
|
||||
int iCpuCore;
|
||||
|
||||
// GFX
|
||||
bool bDisplayFramebuffer;
|
||||
bool bHardwareTransform;
|
||||
bool bBufferedRendering;
|
||||
bool bDrawWireframe;
|
||||
int iWindowZoom; // for Windows
|
||||
|
||||
// Sound
|
||||
bool bEnableSound;
|
||||
|
||||
// UI
|
||||
bool bShowTouchControls;
|
||||
bool bShowDebuggerOnLoad;
|
||||
bool bShowAnalogStick;
|
||||
bool bShowFPSCounter;
|
||||
bool bShowDebugStats;
|
||||
int iWindowZoom; // for Windows
|
||||
int iCpuCore;
|
||||
|
||||
std::string currentDirectory;
|
||||
std::string memCardDirectory;
|
||||
|
@ -169,6 +169,10 @@ void NativeInit(int argc, const char *argv[], const char *savegame_directory, co
|
||||
LogManager *logman = LogManager::GetInstance();
|
||||
ILOG("Logman: %p", logman);
|
||||
|
||||
config_filename = user_data_path + "ppsspp.ini";
|
||||
|
||||
g_Config.Load(config_filename.c_str());
|
||||
|
||||
bool gfxLog = false;
|
||||
// Parse command line
|
||||
LogTypes::LOG_LEVELS logLevel = LogTypes::LINFO;
|
||||
@ -184,12 +188,15 @@ void NativeInit(int argc, const char *argv[], const char *savegame_directory, co
|
||||
break;
|
||||
case 'j':
|
||||
g_Config.iCpuCore = CPU_JIT;
|
||||
g_Config.bSaveSettings = false;
|
||||
break;
|
||||
case 'f':
|
||||
g_Config.iCpuCore = CPU_FASTINTERPRETER;
|
||||
g_Config.bSaveSettings = false;
|
||||
break;
|
||||
case 'i':
|
||||
g_Config.iCpuCore = CPU_INTERPRETER;
|
||||
g_Config.bSaveSettings = false;
|
||||
break;
|
||||
}
|
||||
} else {
|
||||
@ -207,10 +214,6 @@ void NativeInit(int argc, const char *argv[], const char *savegame_directory, co
|
||||
}
|
||||
}
|
||||
|
||||
config_filename = user_data_path + "ppsspp.ini";
|
||||
|
||||
g_Config.Load(config_filename.c_str());
|
||||
|
||||
if (g_Config.currentDirectory == "") {
|
||||
#if defined(ANDROID) || defined(BLACKBERRY) || defined(__SYMBIAN32__)
|
||||
g_Config.currentDirectory = external_directory;
|
||||
|
Loading…
Reference in New Issue
Block a user