247 iFastSwapArea->SetRect( rects[1] ); // cannot be before iAppsHeading constructL |
247 iFastSwapArea->SetRect( rects[1] ); // cannot be before iAppsHeading constructL |
248 iAppsHeading->SetRect( rects[0] ); |
248 iAppsHeading->SetRect( rects[0] ); |
249 |
249 |
250 CleanupStack::PopAndDestroy( &rects ); |
250 CleanupStack::PopAndDestroy( &rects ); |
251 |
251 |
252 UpdateHeadingsL(); |
252 UpdateHeadingsL(0); |
253 } |
253 } |
254 |
254 |
255 // ----------------------------------------------------------------------------- |
255 // ----------------------------------------------------------------------------- |
256 // CTsAppView::GetRects |
256 // CTsAppView::GetRects |
257 // ----------------------------------------------------------------------------- |
257 // ----------------------------------------------------------------------------- |
627 |
627 |
628 // ----------------------------------------------------------------------------- |
628 // ----------------------------------------------------------------------------- |
629 // CTsAppView::DataChanged |
629 // CTsAppView::DataChanged |
630 // ----------------------------------------------------------------------------- |
630 // ----------------------------------------------------------------------------- |
631 // |
631 // |
632 void CTsAppView::DataChanged( CCoeControl* /*aWhere*/, TInt /*aNewCount*/ ) |
632 void CTsAppView::DataChanged( CCoeControl* /*aWhere*/, TInt aNewCount ) |
633 { |
633 { |
634 TRAP_IGNORE( UpdateHeadingsL() ); |
634 TRAP_IGNORE( UpdateHeadingsL( aNewCount ) ); |
635 } |
635 } |
636 |
636 |
637 // ----------------------------------------------------------------------------- |
637 // ----------------------------------------------------------------------------- |
638 // CTsAppView::UpdateHeadingsL |
638 // CTsAppView::UpdateHeadingsL |
639 // ----------------------------------------------------------------------------- |
639 // ----------------------------------------------------------------------------- |
640 // |
640 // |
641 void CTsAppView::UpdateHeadingsL() |
641 void CTsAppView::UpdateHeadingsL( TInt aNewCount ) |
642 { |
642 { |
643 #ifndef TASKSWITCHER_USE_CUSTOM_LAYOUT |
|
644 HBufC* text = StringLoader::LoadLC( |
643 HBufC* text = StringLoader::LoadLC( |
645 R_TASK_SWITCHER_HEADING_APPLICATIONS ); |
644 R_TASK_SWITCHER_HEADING_APPLICATIONS, aNewCount ); |
646 #else |
|
647 _LIT( KTitle, "Task switcher" ); |
|
648 HBufC* text = KTitle().AllocLC(); |
|
649 #endif |
|
650 iAppsHeading->SetTextL( *text ); |
645 iAppsHeading->SetTextL( *text ); |
651 iAppsHeading->DrawDeferred(); |
646 iAppsHeading->DrawDeferred(); |
652 CleanupStack::PopAndDestroy( text ); |
647 CleanupStack::PopAndDestroy( text ); |
653 |
|
654 } |
648 } |
655 |
649 |
656 |
650 |
657 // ----------------------------------------------------------------------------- |
651 // ----------------------------------------------------------------------------- |
658 // CTsAppView::HandleAppKey |
652 // CTsAppView::HandleAppKey |