#include <CScoreDialog.h>
Collaboration diagram for CScoreDialog:

Static Public Methods | |
| void | RunDlgLD (CHighScores &aHighScores, TInt aScore) |
| Show enter name dialog. More... | |
Private Methods | |
| CScoreDialog (CHighScores &aHighScores, TInt aScore) | |
| constructor. More... | |
| TBool | OkToExitL (TInt aKeycode) |
| Add high score. More... | |
Private Attributes | |
| CHighScores & | iHighScores |
| High score table. More... | |
| TInt | iScore |
| Players score. More... | |
Definition at line 36 of file CScoreDialog.h.
|
||||||||||||
|
constructor.
Definition at line 40 of file CScoreDialog.cpp. Referenced by RunDlgLD().
00041 :iHighScores(aHighScores), iScore(aScore) { 00042 00043 } |
|
||||||||||||
|
Show enter name dialog. Creates the dialog, runs it. The ExecuteLD() function will return when the dialog has completed and will delete the dialog.
Definition at line 33 of file CScoreDialog.cpp. References CScoreDialog(). Referenced by CGameAppUi::HandleCommandL().
00033 {
00034 CEikDialog* dialog = new (ELeave) CScoreDialog(aHighScores, aScore);
00035 dialog->ExecuteLD(R_SCORE_DIALOG);
00036 }
|
|
|
Add high score. If the user pressed OK or enter this will add their name to the high score table.
Definition at line 55 of file CScoreDialog.cpp. References CHighScores::AddScoreL(), EHighScoreNameControlId, iHighScores, and iScore.
00055 {
00056 if(aKeycode==EEikBidOk) {
00057 CEikGlobalTextEditor *ed= STATIC_CAST(CEikGlobalTextEditor*,Control(EHighScoreNameControlId));
00058 CGlobalText *text=ed->GlobalText();
00059 iHighScores.AddScoreL(text->Read(0),iScore);
00060 }
00061 return ETrue;
00062 }
|
|
|
High score table.
Definition at line 45 of file CScoreDialog.h. Referenced by OkToExitL(). |
|
|
Players score.
Definition at line 46 of file CScoreDialog.h. Referenced by OkToExitL(). |