|
S60 3rd Edition SDK for Symbian OS Example Applications Guide |
00001 /* 00002 * ============================================================================== 00003 * Name : RegistrationView.h 00004 * Part of : Registration 00005 * Interface : 00006 * Description : 00007 * Version : 00008 * 00009 * Copyright (c) 2005-2006 Nokia Corporation. 00010 * This material, including documentation and any related 00011 * computer programs, is protected by copyright controlled by 00012 * Nokia Corporation. 00013 * ============================================================================== 00014 */ 00015 00016 #ifndef REGISTRATIONVIEW_H 00017 #define REGISTRATIONVIEW_H 00018 00019 // INCLUDE FILES 00020 #include <aknview.h> 00021 #include <avkon.hrh> 00022 #include <avkon.rsg> 00023 #include <akntitle.h> 00024 #include <aknviewappui.h> 00025 00026 #include <Registration.rsg> 00027 #include "Registration.hrh" 00028 #include "RegistrationItemdata.h" 00029 00030 // CONSTANTS 00031 // UID of View. 00032 const TUid KViewId = { 1 }; 00033 const TInt KMaxEmailLength = 40; 00034 00035 // FORWARD DECLARATIONS 00036 class CRegistrationListbox; 00037 00038 // CLASS DECLARATION 00039 /** 00040 * CRegistrationView view class. 00041 */ 00042 class CRegistrationView : public CAknView 00043 { 00044 public: // Constructors and destructor 00045 /** 00046 * NewL 00047 * Two-phased constructor. 00048 * Create a CRegistrationView object, which will draw itself to aRect. 00049 * @param aRect The rectangle this view will be drawn to. 00050 * @return a pointer to the created instance of CRegistrationView. 00051 */ 00052 static CRegistrationView* NewL(); 00053 00054 /** 00055 * NewLC 00056 * Two-phased constructor. 00057 * Create a CRegistrationView object, which will draw itself to aRect. 00058 * @param aRect Rectangle this view will be drawn to. 00059 * @return A pointer to the created instance of CRegistrationView. 00060 */ 00061 static CRegistrationView* NewLC(); 00062 00063 /** 00064 * ~CRegistrationView 00065 * Virtual Destructor. 00066 */ 00067 virtual ~CRegistrationView(); 00068 00069 public: // New function 00070 /** 00071 * SizeChanged 00072 * Creates Listbox 00073 * Called by AppUi when the view size is changed. 00074 */ 00075 void SizeChanged(); 00076 00077 /** 00078 * ValidateInput 00079 * Checks validity of input. 00080 * @return ETrue if input is valid and EFalse if not valid 00081 */ 00082 TBool ValidateInput(); 00083 00084 public: // From CAknView 00085 /** 00086 * Id 00087 * Returns the ID of view. 00088 * @return The ID of view. 00089 */ 00090 TUid Id() const; 00091 00092 /** 00093 * HandleCommandL. 00094 * handles the commands. if the command is command which is require to 00095 * display outline-screen, the command is reported to container class. 00096 * @param aCommand Command to be handled. 00097 */ 00098 void HandleCommandL( TInt aCommand ); 00099 00100 private: // Constructors and destructor 00101 /** 00102 * CRegistrationView 00103 * C++ default constructor. 00104 */ 00105 CRegistrationView(); 00106 00107 /** 00108 * ConstructL 00109 * 2nd phase constructor. 00110 * Perform the second phase construction of a CRegistrationView object. 00111 */ 00112 void ConstructL(); 00113 00114 private: // From CAknView 00115 /** 00116 * DoActivateL. 00117 * Creates the Container class object. 00118 * @param aPrevViewId aPrevViewId is not used. 00119 * @param aCustomMessageId aCustomMessageId is not used. 00120 * @param aCustomMessage aCustomMessage is not used. 00121 */ 00122 void DoActivateL( const TVwsViewId& aPrevViewId, 00123 TUid aCustomMessageId, 00124 const TDesC8& aCustomMessage ); 00125 00126 /** 00127 * DoDeactivate. 00128 * Deletes the Container class object. 00129 */ 00130 void DoDeactivate(); 00131 00132 private: // Data 00133 00134 CRegistrationListbox* iListbox; 00135 TRegistrationItemdata iItemData; 00136 }; 00137 00138 #endif // REGISTRATIONVIEW_H 00139 00140 // End of File
|
© Nokia 2006 |