31
31
* Construct the Csymbian_ua_guiAppUi instance
33
Csymbian_ua_guiAppUi::Csymbian_ua_guiAppUi() : CTimer(0)
35
// [[[ begin generated region: do not modify [Generated Contents]
36
// ]]] end generated region [Generated Contents]
33
Csymbian_ua_guiAppUi::Csymbian_ua_guiAppUi() : CTimer (0)
35
// [[[ begin generated region: do not modify [Generated Contents]
36
// ]]] end generated region [Generated Contents]
41
41
* The appui's destructor removes the container from the control
42
42
* stack and destroys it.
44
44
Csymbian_ua_guiAppUi::~Csymbian_ua_guiAppUi()
46
// [[[ begin generated region: do not modify [Generated Contents]
47
TRAPD( err_Dlg_wait_init, RemoveDlg_wait_initL() );
48
// ]]] end generated region [Generated Contents]
46
// [[[ begin generated region: do not modify [Generated Contents]
47
TRAPD (err_Dlg_wait_init, RemoveDlg_wait_initL());
48
// ]]] end generated region [Generated Contents]
51
51
// [[[ begin generated function: do not modify
52
52
void Csymbian_ua_guiAppUi::InitializeContainersL()
54
iSymbian_ua_guiContainerView = Csymbian_ua_guiContainerView::NewL();
55
AddViewL( iSymbian_ua_guiContainerView );
56
iSymbian_ua_guiSettingItemListView = Csymbian_ua_guiSettingItemListView::NewL();
57
AddViewL( iSymbian_ua_guiSettingItemListView );
58
SetDefaultViewL( *iSymbian_ua_guiSettingItemListView );
54
iSymbian_ua_guiContainerView = Csymbian_ua_guiContainerView::NewL();
55
AddViewL (iSymbian_ua_guiContainerView);
56
iSymbian_ua_guiSettingItemListView = Csymbian_ua_guiSettingItemListView::NewL();
57
AddViewL (iSymbian_ua_guiSettingItemListView);
58
SetDefaultViewL (*iSymbian_ua_guiSettingItemListView);
60
60
// ]]] end generated function
63
63
* Handle a command for this appui (override)
64
64
* @param aCommand command id to be handled
66
void Csymbian_ua_guiAppUi::HandleCommandL( TInt aCommand )
68
// [[[ begin generated region: do not modify [Generated Code]
69
TBool commandHandled = EFalse;
71
{ // code to dispatch to the AppUi's menu and CBA commands is generated here
77
if ( !commandHandled )
79
if ( aCommand == EAknSoftkeyExit || aCommand == EEikCmdExit )
85
// ]]] end generated region [Generated Code]
66
void Csymbian_ua_guiAppUi::HandleCommandL (TInt aCommand)
68
// [[[ begin generated region: do not modify [Generated Code]
69
TBool commandHandled = EFalse;
71
switch (aCommand) { // code to dispatch to the AppUi's menu and CBA commands is generated here
77
if (!commandHandled) {
78
if (aCommand == EAknSoftkeyExit || aCommand == EEikCmdExit) {
84
// ]]] end generated region [Generated Code]
90
89
* Override of the HandleResourceChangeL virtual function
92
void Csymbian_ua_guiAppUi::HandleResourceChangeL( TInt aType )
94
CAknViewAppUi::HandleResourceChangeL( aType );
95
// [[[ begin generated region: do not modify [Generated Code]
96
// ]]] end generated region [Generated Code]
91
void Csymbian_ua_guiAppUi::HandleResourceChangeL (TInt aType)
93
CAknViewAppUi::HandleResourceChangeL (aType);
94
// [[[ begin generated region: do not modify [Generated Code]
95
// ]]] end generated region [Generated Code]
101
100
* Override of the HandleKeyEventL virtual function
102
101
* @return EKeyWasConsumed if event was handled, EKeyWasNotConsumed if not
106
TKeyResponse Csymbian_ua_guiAppUi::HandleKeyEventL(
107
const TKeyEvent& aKeyEvent,
110
// The inherited HandleKeyEventL is private and cannot be called
111
// [[[ begin generated region: do not modify [Generated Contents]
112
// ]]] end generated region [Generated Contents]
114
return EKeyWasNotConsumed;
105
TKeyResponse Csymbian_ua_guiAppUi::HandleKeyEventL (
106
const TKeyEvent& aKeyEvent,
109
// The inherited HandleKeyEventL is private and cannot be called
110
// [[[ begin generated region: do not modify [Generated Contents]
111
// ]]] end generated region [Generated Contents]
113
return EKeyWasNotConsumed;
118
117
* Override of the HandleViewDeactivation virtual function
120
* @param aViewIdToBeDeactivated
121
* @param aNewlyActivatedViewId
119
* @param aViewIdToBeDeactivated
120
* @param aNewlyActivatedViewId
123
void Csymbian_ua_guiAppUi::HandleViewDeactivation(
124
const TVwsViewId& aViewIdToBeDeactivated,
125
const TVwsViewId& aNewlyActivatedViewId )
127
CAknViewAppUi::HandleViewDeactivation(
128
aViewIdToBeDeactivated,
129
aNewlyActivatedViewId );
130
// [[[ begin generated region: do not modify [Generated Contents]
131
// ]]] end generated region [Generated Contents]
122
void Csymbian_ua_guiAppUi::HandleViewDeactivation (
123
const TVwsViewId& aViewIdToBeDeactivated,
124
const TVwsViewId& aNewlyActivatedViewId)
126
CAknViewAppUi::HandleViewDeactivation (
127
aViewIdToBeDeactivated,
128
aNewlyActivatedViewId);
129
// [[[ begin generated region: do not modify [Generated Contents]
130
// ]]] end generated region [Generated Contents]
136
* @brief Completes the second phase of Symbian object construction.
137
* Put initialization code that could leave here.
135
* @brief Completes the second phase of Symbian object construction.
136
* Put initialization code that could leave here.
139
138
void Csymbian_ua_guiAppUi::ConstructL()
141
// [[[ begin generated region: do not modify [Generated Contents]
142
BaseConstructL( EAknEnableSkin );
143
InitializeContainersL();
144
// ]]] end generated region [Generated Contents]
146
// Create private folder
150
path.Copy( process.FileName().Left(2) );
152
if(path.Compare(_L("c")) || path.Compare(_L("C")))
153
CEikonEnv::Static()->FsSession().CreatePrivatePath(EDriveC);
154
else if(path.Compare(_L("e")) || path.Compare(_L("E")))
155
CEikonEnv::Static()->FsSession().CreatePrivatePath(EDriveE);
158
if (symbian_ua_init() != 0) {
159
symbian_ua_destroy();
163
ExecuteDlg_wait_initLD();
165
CTimer::ConstructL();
166
CActiveScheduler::Add( this );
140
// [[[ begin generated region: do not modify [Generated Contents]
141
BaseConstructL (EAknEnableSkin);
142
InitializeContainersL();
143
// ]]] end generated region [Generated Contents]
145
// Create private folder
149
path.Copy (process.FileName().Left (2));
151
if (path.Compare (_L ("c")) || path.Compare (_L ("C")))
152
CEikonEnv::Static()->FsSession().CreatePrivatePath (EDriveC);
153
else if (path.Compare (_L ("e")) || path.Compare (_L ("E")))
154
CEikonEnv::Static()->FsSession().CreatePrivatePath (EDriveE);
157
if (symbian_ua_init() != 0) {
158
symbian_ua_destroy();
162
ExecuteDlg_wait_initLD();
164
CTimer::ConstructL();
165
CActiveScheduler::Add (this);
171
170
* Override of the HandleApplicationSpecificEventL virtual function
173
void Csymbian_ua_guiAppUi::HandleApplicationSpecificEventL(
175
const TWsEvent& anEvent )
177
CAknViewAppUi::HandleApplicationSpecificEventL( aType, anEvent );
178
// [[[ begin generated region: do not modify [Generated Code]
179
// ]]] end generated region [Generated Code]
172
void Csymbian_ua_guiAppUi::HandleApplicationSpecificEventL (
174
const TWsEvent& anEvent)
176
CAknViewAppUi::HandleApplicationSpecificEventL (aType, anEvent);
177
// [[[ begin generated region: do not modify [Generated Code]
178
// ]]] end generated region [Generated Code]
184
183
* Handle the applicationSpecificEvent event.
186
void Csymbian_ua_guiAppUi::HandleSymbian_ua_guiAppUiApplicationSpecificEventL(
188
const TWsEvent& /* anEvent */ )
190
// TODO: implement applicationSpecificEvent event handler
185
void Csymbian_ua_guiAppUi::HandleSymbian_ua_guiAppUiApplicationSpecificEventL (
187
const TWsEvent& /* anEvent */)
189
// TODO: implement applicationSpecificEvent event handler
193
192
// [[[ begin generated function: do not modify
195
194
* Execute the wait dialog for dlg_wait_init. This routine returns
198
197
* @param aOverrideText optional override text. When null the text configured
199
198
* in the UI Designer is used.
201
void Csymbian_ua_guiAppUi::ExecuteDlg_wait_initLD( const TDesC* aOverrideText )
203
iDlg_wait_init = new ( ELeave ) CAknWaitDialog(
204
reinterpret_cast< CEikDialog** >( &iDlg_wait_init ), EFalse );
205
if ( aOverrideText != NULL )
207
iDlg_wait_init->SetTextL( *aOverrideText );
209
iDlg_wait_init->ExecuteLD( R_APPLICATION_DLG_WAIT_INIT );
210
iDlg_wait_initCallback = new ( ELeave ) CProgressDialogCallback(
211
this, iDlg_wait_init, &Csymbian_ua_guiAppUi::HandleDlg_wait_initCanceledL );
212
iDlg_wait_init->SetCallback( iDlg_wait_initCallback );
200
void Csymbian_ua_guiAppUi::ExecuteDlg_wait_initLD (const TDesC* aOverrideText)
202
iDlg_wait_init = new (ELeave) CAknWaitDialog (
203
reinterpret_cast< CEikDialog** > (&iDlg_wait_init), EFalse);
205
if (aOverrideText != NULL) {
206
iDlg_wait_init->SetTextL (*aOverrideText);
209
iDlg_wait_init->ExecuteLD (R_APPLICATION_DLG_WAIT_INIT);
210
iDlg_wait_initCallback = new (ELeave) CProgressDialogCallback (
211
this, iDlg_wait_init, &Csymbian_ua_guiAppUi::HandleDlg_wait_initCanceledL);
212
iDlg_wait_init->SetCallback (iDlg_wait_initCallback);
214
214
// ]]] end generated function
216
216
// [[[ begin generated function: do not modify