diff --git a/stepmania/src/ScreenBookkeeping.cpp b/stepmania/src/ScreenBookkeeping.cpp index f8a39917ad..99c8ec02ed 100644 --- a/stepmania/src/ScreenBookkeeping.cpp +++ b/stepmania/src/ScreenBookkeeping.cpp @@ -7,6 +7,7 @@ #include "ScreenDimensions.h" #include "InputEventPlus.h" #include "RageUtil.h" +#include "LocalizedString.h" REGISTER_SCREEN_CLASS( ScreenBookkeeping ); @@ -103,6 +104,11 @@ void ScreenBookkeeping::MenuCoin( PlayerNumber pn ) Screen::MenuCoin( pn ); } +static LocalizedString ALL_TIME ( "ScreenBookkeeping", "All-time Total:" ); +static LocalizedString LAST_DAYS ( "ScreenBookkeeping", "Coin Data of Last %d Days" ); +static LocalizedString LAST_WEEKS ( "ScreenBookkeeping", "Coin Data of Last %d Weeks" ); +static LocalizedString DAY_OF_WEEK ( "ScreenBookkeeping", "Coin Data by Day of Week, All-Time" ); +static LocalizedString HOUR_OF_DAY ( "ScreenBookkeeping", "Coin Data by Hour of Day, All-Time" ); void ScreenBookkeeping::ChangeView( View newView ) { m_View = newView; @@ -110,8 +116,8 @@ void ScreenBookkeeping::ChangeView( View newView ) { CString s; - s += "All-time Total: "; - s += ssprintf( "%i\n", BOOKKEEPER->GetCoinsTotal() ); + s += ALL_TIME.GetValue(); + s += ssprintf( " %i\n", BOOKKEEPER->GetCoinsTotal() ); m_textAllTime.SetText( s ); } @@ -119,7 +125,7 @@ void ScreenBookkeeping::ChangeView( View newView ) { case VIEW_LAST_DAYS: { - m_textTitle.SetText( ssprintf("Coin Data of Last %d Days", NUM_LAST_DAYS) ); + m_textTitle.SetText( ssprintf(LAST_DAYS.GetValue(), NUM_LAST_DAYS) ); int coins[NUM_LAST_DAYS]; BOOKKEEPER->GetCoinsLastDays( coins ); @@ -128,12 +134,12 @@ void ScreenBookkeeping::ChangeView( View newView ) CString sTitle, sData; for( int i=0; iGetCoinsLastWeeks( coins ); @@ -158,7 +164,7 @@ void ScreenBookkeeping::ChangeView( View newView ) for( int row=0; row<52/4; row++ ) { int week = row*4+col; - sTemp += LastWeekToDisplayString(week) + ssprintf(": %d",coins[week]) + "\n"; + sTemp += LastWeekToThemedString(week) + ssprintf(": %d",coins[week]) + "\n"; } m_textData[col].SetHorizAlign( Actor::align_left ); @@ -168,7 +174,7 @@ void ScreenBookkeeping::ChangeView( View newView ) break; case VIEW_DAY_OF_WEEK: { - m_textTitle.SetText( "Coin Data by Day of Week, All-Time" ); + m_textTitle.SetText( DAY_OF_WEEK ); int coins[DAYS_IN_WEEK]; BOOKKEEPER->GetCoinsByDayOfWeek( coins ); @@ -190,7 +196,7 @@ void ScreenBookkeeping::ChangeView( View newView ) break; case VIEW_HOUR_OF_DAY: { - m_textTitle.SetText( "Coin Data by Hour of Day, All-Time" ); + m_textTitle.SetText( HOUR_OF_DAY ); int coins[HOURS_IN_DAY]; BOOKKEEPER->GetCoinsByHour( coins ); @@ -198,14 +204,14 @@ void ScreenBookkeeping::ChangeView( View newView ) CString sTitle1, sData1; for( int i=0; i