mirror of https://github.com/PCSX2/pcsx2.git
i18n: Fix assertion crash of my previous commit. I recreate all logics for the folder option to avoid issue with jNO_DEFAULT
Note: now it will be easy to add a folder selection in the appearance panel (if still exists, it does not appear on my system) git-svn-id: http://pcsx2.googlecode.com/svn/trunk@4252 96395faa-99c1-11dd-bbfe-3dabce05a288
This commit is contained in:
parent
f19dc6f9fb
commit
06fbb06b30
|
@ -221,6 +221,7 @@ wxDirName& AppConfig::FolderOptions::operator[]( FoldersEnum_t folderidx )
|
|||
case FolderId_Savestates: return Savestates;
|
||||
case FolderId_MemoryCards: return MemoryCards;
|
||||
case FolderId_Logs: return Logs;
|
||||
case FolderId_Langs: return Langs;
|
||||
|
||||
case FolderId_Documents: return CustomDocumentsFolder;
|
||||
|
||||
|
@ -246,6 +247,7 @@ bool AppConfig::FolderOptions::IsDefault( FoldersEnum_t folderidx ) const
|
|||
case FolderId_Savestates: return UseDefaultSavestates;
|
||||
case FolderId_MemoryCards: return UseDefaultMemoryCards;
|
||||
case FolderId_Logs: return UseDefaultLogs;
|
||||
case FolderId_Langs: return UseDefaultLangs;
|
||||
|
||||
case FolderId_Documents: return false;
|
||||
|
||||
|
@ -298,6 +300,11 @@ void AppConfig::FolderOptions::Set( FoldersEnum_t folderidx, const wxString& src
|
|||
UseDefaultLogs = useDefault;
|
||||
break;
|
||||
|
||||
case FolderId_Langs:
|
||||
Langs = src;
|
||||
UseDefaultLangs = useDefault;
|
||||
break;
|
||||
|
||||
case FolderId_Documents:
|
||||
CustomDocumentsFolder = src;
|
||||
break;
|
||||
|
@ -576,6 +583,7 @@ void AppConfig::FolderOptions::ApplyDefaults()
|
|||
if( UseDefaultSavestates ) Savestates = PathDefs::GetSavestates();
|
||||
if( UseDefaultMemoryCards ) MemoryCards = PathDefs::GetMemoryCards();
|
||||
if( UseDefaultLogs ) Logs = PathDefs::GetLogs();
|
||||
if( UseDefaultLangs ) Langs = PathDefs::GetLangs();
|
||||
}
|
||||
|
||||
// ------------------------------------------------------------------------
|
||||
|
@ -584,6 +592,7 @@ AppConfig::FolderOptions::FolderOptions()
|
|||
, Snapshots ( PathDefs::GetSnapshots() )
|
||||
, Savestates ( PathDefs::GetSavestates() )
|
||||
, MemoryCards ( PathDefs::GetMemoryCards() )
|
||||
, Langs ( PathDefs::GetLangs() )
|
||||
, Logs ( PathDefs::GetLogs() )
|
||||
|
||||
, RunIso( PathDefs::GetDocuments() ) // raw default is always the Documents folder.
|
||||
|
@ -606,12 +615,14 @@ void AppConfig::FolderOptions::LoadSave( IniInterface& ini )
|
|||
IniBitBool( UseDefaultSavestates );
|
||||
IniBitBool( UseDefaultMemoryCards );
|
||||
IniBitBool( UseDefaultLogs );
|
||||
IniBitBool( UseDefaultLangs );
|
||||
|
||||
IniEntry( Bios );
|
||||
IniEntry( Snapshots );
|
||||
IniEntry( Savestates );
|
||||
IniEntry( MemoryCards );
|
||||
IniEntry( Logs );
|
||||
IniEntry( Langs );
|
||||
|
||||
IniEntry( RunIso );
|
||||
IniEntry( RunELF );
|
||||
|
|
|
@ -127,7 +127,8 @@ public:
|
|||
UseDefaultSnapshots:1,
|
||||
UseDefaultSavestates:1,
|
||||
UseDefaultMemoryCards:1,
|
||||
UseDefaultLogs:1;
|
||||
UseDefaultLogs:1,
|
||||
UseDefaultLangs:1;
|
||||
BITFIELD_END
|
||||
|
||||
wxDirName
|
||||
|
@ -135,6 +136,7 @@ public:
|
|||
Snapshots,
|
||||
Savestates,
|
||||
MemoryCards,
|
||||
Langs,
|
||||
Logs;
|
||||
|
||||
wxDirName RunIso; // last used location for Iso loading.
|
||||
|
|
Loading…
Reference in New Issue