// Enables a full list of gamefixes. The list can be either comma or pipe-delimited. // Example: "XGKick,IpuWait" or "EEtiming,FpuCompare" // If an unrecognized tag is encountered, a warning is printed to the console, but no error // is generated. This allows the system to function in the event that future versions of // PCSX2 remove old hacks once they become obsolete. void Pcsx2Config::GamefixOptions::Set( const wxString& list, bool enabled ) { wxStringTokenizer izer( list, L",|", wxTOKEN_STRTOK ); while( izer.HasMoreTokens() ) { wxString token( izer.GetNextToken() ); GamefixId i; for (i=GamefixId_FIRST; i < pxEnumEnd; ++i) { if( token.CmpNoCase( EnumToString(i) ) == 0 ) break; } if( i < pxEnumEnd ) Set( i ); } }
bool plFileUtils::EnsureFilePathExists( const wchar_t *filename ) { hsWStringTokenizer izer( filename, L"\\/" ); bool lastWorked = false; wchar_t token[ kFolderIterator_MaxPath ]; while( izer.Next( token, arrsize( token ) ) && izer.HasMoreTokens() ) { // Want the full path from the start of the string lastWorked = CreateDir( izer.fString ); izer.RestoreLastTerminator(); } return lastWorked; }