new profile/course screen polish

This commit is contained in:
Chris Danford
2005-08-05 10:07:49 +00:00
parent c885a38d9f
commit 1a9b738d8b
7 changed files with 90 additions and 19 deletions
+14 -2
View File
@@ -26,6 +26,7 @@ void ScreenOptionsEditProfile::Init()
{
ScreenOptions::Init();
m_Original = *GAMESTATE->GetEditLocalProfile();
vector<OptionRowDefinition> vDefs;
vector<OptionRowHandler*> vHands;
@@ -36,6 +37,7 @@ void ScreenOptionsEditProfile::Init()
def.m_bAllowThemeItems = false;
def.m_bAllowThemeTitles = false;
def.m_bAllowExplanation = false;
def.m_bExportOnChange = true;
Profile &pro = PROFILEMAN->GetLocalProfile( GAMESTATE->m_sEditLocalProfileID );
@@ -90,12 +92,10 @@ void ScreenOptionsEditProfile::ExportOptions( int iRow, const vector<PlayerNumbe
void ScreenOptionsEditProfile::GoToNextScreen()
{
SCREENMAN->SetNewScreen( "ScreenOptionsService" );
}
void ScreenOptionsEditProfile::GoToPrevScreen()
{
SCREENMAN->SetNewScreen( "ScreenOptionsService" );
}
void ScreenOptionsEditProfile::HandleScreenMessage( const ScreenMessage SM )
@@ -104,10 +104,22 @@ void ScreenOptionsEditProfile::HandleScreenMessage( const ScreenMessage SM )
{
PROFILEMAN->SaveLocalProfile( GAMESTATE->m_sEditLocalProfileID );
}
else if( SM == SM_GoToPrevScreen )
{
*GAMESTATE->GetEditLocalProfile() = m_Original;
}
ScreenOptions::HandleScreenMessage( SM );
}
void ScreenOptionsEditProfile::AfterChangeValueInRow( int iRow, PlayerNumber pn )
{
ScreenOptions::AfterChangeValueInRow( iRow, pn );
// cause the overlay to reload
GAMESTATE->m_sEditLocalProfileID.Set( GAMESTATE->m_sEditLocalProfileID );
}
void ScreenOptionsEditProfile::ProcessMenuStart( PlayerNumber pn, const InputEventType type )
{
int iRow = GetCurrentRow();;