1.4.0 version string is now saved to (Win) registry and portable.ini. We use this to detect older configuration files and start the First Time Wizard if necessary. This also prevents all older .inis (PCSX2, plugins) from being used in 1.4.0.

This commit should probably not be merged into master, but stay on this branch. A nicer way to handle upgrades is planned.
This commit is contained in:
ramapcsx2 2015-12-29 17:52:23 +01:00
parent 22880339b6
commit 8ba761d334
2 changed files with 7 additions and 3 deletions

View File

@ -56,7 +56,8 @@ namespace PathDefs
const wxDirName& Settings()
{
static const wxDirName retval( L"inis" );
static const wxDirName retval(wxsFormat(L"inis_%d.%d.%d",
PCSX2_VersionHi, PCSX2_VersionMid, PCSX2_VersionLo));
return retval;
}

View File

@ -289,13 +289,15 @@ void Pcsx2App::EstablishAppUserMode()
// Wizard is only run once. The status of the wizard having been run is stored in
// the installation ini file, which can be either the portable install (useful for admins)
// or the registry/user local documents position.
int version;
conf_install->Read(L"Version", &version, 0);
bool runWiz;
conf_install->Read( L"RunWizard", &runWiz, true );
App_LoadInstallSettings( conf_install );
int pcsx2Ver = PCSX2_VersionHi * 100 + PCSX2_VersionMid * 10 + PCSX2_VersionLo;
if( !Startup.ForceWizard && !runWiz )
if( !Startup.ForceWizard && !runWiz && version == pcsx2Ver)
{
AppConfig_OnChangedSettingsFolder( false );
return;
@ -310,5 +312,6 @@ void Pcsx2App::EstablishAppUserMode()
// Wizard completed successfully, so let's not torture the user with this crap again!
conf_install->Write( L"RunWizard", false );
conf_install->Write(L"Version", pcsx2Ver);
}