finish import/export of edits

This commit is contained in:
Chris Danford
2005-11-30 05:33:01 +00:00
parent 42f056dfdb
commit 3b799327fc
5 changed files with 48 additions and 5 deletions
+27
View File
@@ -5,6 +5,7 @@
#include "MemoryCardManager.h"
#include "GameState.h"
#include "ScreenManager.h"
#include "ScreenPrompt.h"
REGISTER_SCREEN_CLASS( ScreenOptionsMemoryCard );
@@ -94,6 +95,32 @@ void ScreenOptionsMemoryCard::ExportOptions( int iRow, const vector<PlayerNumber
}
}
void ScreenOptionsMemoryCard::ProcessMenuStart( const InputEventPlus &input )
{
int iCurRow = m_iCurrentRow[GAMESTATE->m_MasterPlayerNumber];
if( iCurRow == (int)m_pRows.size()-1 ) // "exit"
{
MenuBack( GAMESTATE->m_MasterPlayerNumber );
}
else // a card
{
const vector<UsbStorageDevice> v = MEMCARDMAN->GetStorageDevices();
const UsbStorageDevice &dev = v[iCurRow];
MEMCARDMAN->m_sEditorMemoryCardOsMountPoint.Set( dev.sOsMountDir );
bool bSuccess = MEMCARDMAN->MountCard( PLAYER_1, dev );
if( bSuccess )
{
this->BeginFadingOut();
}
else
{
CString s = ssprintf("error mounting card: %s", MEMCARDMAN->GetCardError(PLAYER_1).c_str() );
ScreenPrompt::Prompt( SM_None, s );
}
}
}
/*
* (c) 2005 Chris Danford
* All rights reserved.