Remove m_bMemoryCardsMountOnlyWhenNecessary; always do that.
This commit is contained in:
@@ -109,8 +109,9 @@ void GameState::Reset()
|
||||
EndGame();
|
||||
|
||||
/* Don't do the OS mount for cards during the attract screens. Only do OS mounts in
|
||||
* the time between BeginGame and PlayersFinalized. XXX: I think we do that anyway,
|
||||
* when m_bMemoryCardsMountOnlyWhenNecessary is true. Can we remove this? */
|
||||
* the time between BeginGame and PlayersFinalized. I think we do that anyway (except
|
||||
* for background write tests, which happen anyway unless the memory card thread is
|
||||
* paused). Can we remove this? */
|
||||
MEMCARDMAN->LockCards();
|
||||
|
||||
ASSERT( THEME );
|
||||
@@ -274,8 +275,7 @@ void GameState::PlayersFinalized()
|
||||
ApplyModifiers( pn, DEFAULT_CPU_MODIFIERS );
|
||||
}
|
||||
|
||||
if( PREFSMAN->m_bMemoryCardsMountOnlyWhenNecessary )
|
||||
MEMCARDMAN->UnmountAllUsedCards();
|
||||
MEMCARDMAN->UnmountAllUsedCards();
|
||||
MEMCARDMAN->UnPauseMountingThread();
|
||||
}
|
||||
|
||||
@@ -351,8 +351,7 @@ void GameState::EndGame()
|
||||
}
|
||||
|
||||
MEMCARDMAN->PauseMountingThread();
|
||||
if( PREFSMAN->m_bMemoryCardsMountOnlyWhenNecessary )
|
||||
MEMCARDMAN->MountAllUsedCards();
|
||||
MEMCARDMAN->MountAllUsedCards();
|
||||
|
||||
BOOKKEEPER->WriteToDisk();
|
||||
PROFILEMAN->SaveAllProfiles();
|
||||
@@ -365,8 +364,7 @@ void GameState::EndGame()
|
||||
PROFILEMAN->UnloadProfile( pn );
|
||||
}
|
||||
|
||||
if( PREFSMAN->m_bMemoryCardsMountOnlyWhenNecessary )
|
||||
MEMCARDMAN->UnmountAllUsedCards();
|
||||
MEMCARDMAN->UnmountAllUsedCards();
|
||||
|
||||
// Reset the USB storage device numbers -after- saving
|
||||
CHECKPOINT;
|
||||
|
||||
@@ -246,8 +246,7 @@ void MemoryCardManager::TryMountAllCards()
|
||||
}
|
||||
}
|
||||
|
||||
/* When m_bMemoryCardsMountOnlyWhenNecessary, called in EndGame just before writing the
|
||||
* profile. Should block. */
|
||||
/* Called in EndGame just before writing the profile. Should block. */
|
||||
void MemoryCardManager::MountAllUsedCards()
|
||||
{
|
||||
FOREACH_EnabledPlayer( p )
|
||||
|
||||
@@ -335,7 +335,6 @@ void PrefsManager::Init()
|
||||
m_iMemoryCardUsbPort[p] = -1;
|
||||
m_iMemoryCardUsbLevel[p] = -1;
|
||||
}
|
||||
m_bMemoryCardsMountOnlyWhenNecessary = false;
|
||||
|
||||
m_sMemoryCardProfileSubdir = PRODUCT_NAME;
|
||||
m_iProductID = 1;
|
||||
@@ -536,7 +535,6 @@ void PrefsManager::ReadPrefsFromFile( CString sIni )
|
||||
ini.GetValue( "Options", ssprintf("MemoryCardUsbPortP%d",p+1), m_iMemoryCardUsbPort[p] );
|
||||
ini.GetValue( "Options", ssprintf("MemoryCardUsbLevelP%d",p+1), m_iMemoryCardUsbLevel[p] );
|
||||
}
|
||||
ini.GetValue( "Options", "MemoryCardsMountOnlyWhenNecessary", m_bMemoryCardsMountOnlyWhenNecessary );
|
||||
|
||||
ini.GetValue( "Options", "CenterImageTranslateX", m_iCenterImageTranslateX );
|
||||
ini.GetValue( "Options", "CenterImageTranslateY", m_iCenterImageTranslateY );
|
||||
@@ -766,7 +764,6 @@ void PrefsManager::SaveGlobalPrefsToDisk() const
|
||||
ini.SetValue( "Options", ssprintf("MemoryCardUsbPortP%d",p+1), m_iMemoryCardUsbPort[p] );
|
||||
ini.SetValue( "Options", ssprintf("MemoryCardUsbLevelP%d",p+1), m_iMemoryCardUsbLevel[p] );
|
||||
}
|
||||
ini.SetValue( "Options", "MemoryCardsMountOnlyWhenNecessary", m_bMemoryCardsMountOnlyWhenNecessary );
|
||||
|
||||
ini.SetValue( "Options", "CenterImageTranslateX", m_iCenterImageTranslateX );
|
||||
ini.SetValue( "Options", "CenterImageTranslateY", m_iCenterImageTranslateY );
|
||||
|
||||
@@ -192,7 +192,6 @@ public:
|
||||
int m_iMemoryCardUsbBus[NUM_PLAYERS]; // look for this bus when assigning cards. -1 = match any
|
||||
int m_iMemoryCardUsbPort[NUM_PLAYERS]; // look for this port when assigning cards. -1 = match any
|
||||
int m_iMemoryCardUsbLevel[NUM_PLAYERS]; // look for this level when assigning cards. -1 = match any
|
||||
bool m_bMemoryCardsMountOnlyWhenNecessary;
|
||||
int m_iCenterImageTranslateX;
|
||||
int m_iCenterImageTranslateY;
|
||||
int m_fCenterImageAddWidth;
|
||||
|
||||
@@ -1358,7 +1358,7 @@ void ScreenEvaluation::Input( const DeviceInput& DeviceI, const InputEventType t
|
||||
PROFILEMAN->IsUsingProfile(pn) )
|
||||
{
|
||||
MEMCARDMAN->PauseMountingThread();
|
||||
if( PROFILEMAN->ProfileWasLoadedFromMemoryCard(pn) && PREFSMAN->m_bMemoryCardsMountOnlyWhenNecessary )
|
||||
if( PROFILEMAN->ProfileWasLoadedFromMemoryCard(pn) )
|
||||
MEMCARDMAN->MountCard( pn );
|
||||
|
||||
Profile* pProfile = PROFILEMAN->GetProfile(pn);
|
||||
@@ -1367,7 +1367,7 @@ void ScreenEvaluation::Input( const DeviceInput& DeviceI, const InputEventType t
|
||||
CString sFileName = SaveScreenshot( sDir, true, true, iScreenshotIndex );
|
||||
CString sPath = sDir+sFileName;
|
||||
|
||||
if( PROFILEMAN->ProfileWasLoadedFromMemoryCard(pn) && PREFSMAN->m_bMemoryCardsMountOnlyWhenNecessary )
|
||||
if( PROFILEMAN->ProfileWasLoadedFromMemoryCard(pn) )
|
||||
MEMCARDMAN->UnmountCard( pn );
|
||||
MEMCARDMAN->UnPauseMountingThread();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user