equal
deleted
inserted
replaced
55 // CWmPlugin::~CWmPlugin |
55 // CWmPlugin::~CWmPlugin |
56 // --------------------------------------------------------- |
56 // --------------------------------------------------------- |
57 // |
57 // |
58 CWmPlugin::~CWmPlugin() |
58 CWmPlugin::~CWmPlugin() |
59 { |
59 { |
|
60 if ( iWmInstaller && |
|
61 iWmInstaller->IsActive() ) |
|
62 { |
|
63 iWmInstaller->Cancel(); |
|
64 } |
|
65 |
60 // delete members |
66 // delete members |
61 delete iResourceLoader; |
67 delete iResourceLoader; |
62 delete iEffectManager; |
68 delete iEffectManager; |
63 delete iPostponedContent; |
69 delete iPostponedContent; |
64 delete iWmInstaller; |
70 delete iWmInstaller; |
65 } |
71 } |
66 |
72 |
67 // --------------------------------------------------------- |
73 // --------------------------------------------------------- |
68 // CWmPlugin::CWmPlugin |
74 // CWmPlugin::CWmPlugin |
69 // --------------------------------------------------------- |
75 // --------------------------------------------------------- |
111 iViewAppUi->View( TUid::Uid(EWmMainContainerViewId) ) ); |
117 iViewAppUi->View( TUid::Uid(EWmMainContainerViewId) ) ); |
112 if ( !IsActive() && view && iHsContentController ) |
118 if ( !IsActive() && view && iHsContentController ) |
113 { |
119 { |
114 TRAP_IGNORE( |
120 TRAP_IGNORE( |
115 iEffectManager->BeginFullscreenEffectL( |
121 iEffectManager->BeginFullscreenEffectL( |
116 KAppStartCommonDefaultStyle ); |
122 KAppStartEffectStyle ); |
117 iViewAppUi->ActivateLocalViewL( |
123 iViewAppUi->ActivateLocalViewL( |
118 TUid::Uid( EWmMainContainerViewId ) ); |
124 TUid::Uid( EWmMainContainerViewId ) ); |
119 ); |
125 ); |
120 } |
126 } |
121 } |
127 } |
178 if ( IsActive() ) |
184 if ( IsActive() ) |
179 { |
185 { |
180 iWmMainContainer->SetClosingDown( ETrue ); |
186 iWmMainContainer->SetClosingDown( ETrue ); |
181 TRAP_IGNORE( |
187 TRAP_IGNORE( |
182 iEffectManager->BeginFullscreenEffectL( |
188 iEffectManager->BeginFullscreenEffectL( |
183 KAppExitCommonDefaultStyle ); |
189 KAppExitEffectStyle ); |
184 iViewAppUi->ActivateLocalViewL( |
190 iViewAppUi->ActivateLocalViewL( |
185 iPreviousViewUid.iViewUid ); |
191 iPreviousViewUid.iViewUid ); |
186 ); |
192 ); |
187 } |
193 } |
188 } |
194 } |
285 { |
291 { |
286 switch ( aError ) |
292 switch ( aError ) |
287 { |
293 { |
288 case KHsErrorViewFull: |
294 case KHsErrorViewFull: |
289 case KHsErrorDoesNotFit: |
295 case KHsErrorDoesNotFit: |
|
296 // Not enough space to add new widget to active page. |
|
297 // Remove some content first. |
290 ResourceLoader().InfoPopupL( |
298 ResourceLoader().InfoPopupL( |
291 R_QTN_HS_ADD_WIDGET_NO_SPACE_NOTE, KNullDesC ); |
299 R_QTN_HS_ADD_WIDGET_NO_SPACE_NOTE, KNullDesC ); |
292 break; |
300 break; |
293 |
301 case KErrNoMemory: |
294 case KHsErrorMaxInstanceCountExceeded: |
302 // Not enough memory to add more content. |
295 { |
303 // Please remove some Homescreen content and try again. |
296 TInt resource = ( iPostponedContent->Type() == KContentTemplate ) ? |
304 ResourceLoader().InfoPopupL( R_QTN_HS_HS_MEMORY_FULL, KNullDesC ); |
297 resource = R_QTN_HS_ADD_WIDGET_MAX_REACHED : // wrt |
|
298 resource = R_QTN_HS_ADD_WIDGET_MAX_COUNT_NOTE; // native |
|
299 |
|
300 ResourceLoader().InfoPopupL( resource, KNullDesC ); |
|
301 break; |
305 break; |
302 } |
|
303 |
|
304 case KErrNoMemory: |
|
305 ResourceLoader().InfoPopupL( R_QTN_HS_HS_MEMORY_FULL, KNullDesC ); |
|
306 break; |
|
307 |
|
308 default: |
306 default: |
309 ResourceLoader().ErrorPopup( aError ); |
307 ResourceLoader().ErrorPopup( aError ); |
310 break; |
308 break; |
311 } |
309 } |
312 } |
310 } |