Const.
This commit is contained in:
@@ -35,9 +35,9 @@ static void DefaultLocalProfileIDInit( size_t /*PlayerNumber*/ i, RString &sName
|
|||||||
|
|
||||||
Preference1D<RString> ProfileManager::m_sDefaultLocalProfileID( DefaultLocalProfileIDInit, NUM_PLAYERS );
|
Preference1D<RString> ProfileManager::m_sDefaultLocalProfileID( DefaultLocalProfileIDInit, NUM_PLAYERS );
|
||||||
|
|
||||||
#define NEW_MEM_CARD_NAME ""
|
const RString NEW_MEM_CARD_NAME = "";
|
||||||
#define USER_PROFILES_DIR "/Save/LocalProfiles/"
|
const RString USER_PROFILES_DIR = "/Save/LocalProfiles/";
|
||||||
#define MACHINE_PROFILE_DIR "/Save/MachineProfile/"
|
const RString MACHINE_PROFILE_DIR = "/Save/MachineProfile/";
|
||||||
const RString LAST_GOOD_SUBDIR = "LastGood/";
|
const RString LAST_GOOD_SUBDIR = "LastGood/";
|
||||||
|
|
||||||
|
|
||||||
@@ -383,7 +383,7 @@ void ProfileManager::RefreshLocalProfilesFromDisk()
|
|||||||
UnloadAllLocalProfiles();
|
UnloadAllLocalProfiles();
|
||||||
|
|
||||||
vector<RString> vsProfileID;
|
vector<RString> vsProfileID;
|
||||||
GetDirListing( USER_PROFILES_DIR "*", vsProfileID, true, true );
|
GetDirListing( USER_PROFILES_DIR + "*", vsProfileID, true, true );
|
||||||
FOREACH_CONST( RString, vsProfileID, p )
|
FOREACH_CONST( RString, vsProfileID, p )
|
||||||
{
|
{
|
||||||
g_vLocalProfile.push_back( DirAndProfile() );
|
g_vLocalProfile.push_back( DirAndProfile() );
|
||||||
@@ -540,7 +540,7 @@ bool ProfileManager::LastLoadWasFromLastGood( PlayerNumber pn ) const
|
|||||||
return !m_sProfileDir[pn].empty() && m_bLastLoadWasFromLastGood[pn];
|
return !m_sProfileDir[pn].empty() && m_bLastLoadWasFromLastGood[pn];
|
||||||
}
|
}
|
||||||
|
|
||||||
RString ProfileManager::GetProfileDir( ProfileSlot slot ) const
|
const RString& ProfileManager::GetProfileDir( ProfileSlot slot ) const
|
||||||
{
|
{
|
||||||
switch( slot )
|
switch( slot )
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -76,7 +76,7 @@ public:
|
|||||||
const Profile* GetProfile( ProfileSlot slot ) const;
|
const Profile* GetProfile( ProfileSlot slot ) const;
|
||||||
Profile* GetProfile( ProfileSlot slot ) { return (Profile*) ((const ProfileManager *) this)->GetProfile(slot); }
|
Profile* GetProfile( ProfileSlot slot ) { return (Profile*) ((const ProfileManager *) this)->GetProfile(slot); }
|
||||||
|
|
||||||
RString GetProfileDir( ProfileSlot slot ) const;
|
const RString& GetProfileDir( ProfileSlot slot ) const;
|
||||||
RString GetProfileDirImportedFrom( ProfileSlot slot ) const;
|
RString GetProfileDirImportedFrom( ProfileSlot slot ) const;
|
||||||
|
|
||||||
Profile* GetMachineProfile() { return m_pMachineProfile; }
|
Profile* GetMachineProfile() { return m_pMachineProfile; }
|
||||||
|
|||||||
Reference in New Issue
Block a user