Nokia N97 SDK
Example Applications Guide

CAknExPbarAppUi Class Reference

#include <aknexpbarappui.h>

Inheritance diagram for CAknExPbarAppUi:

List of all members.

Detailed Description

Application UI class. Provides support for the following features:

Definition at line 42 of file aknexpbarappui.h.


Public Member Functions

  CAknExPbarAppUi ()
void  ConstructL ()
virtual  ~CAknExPbarAppUi ()

Private Member Functions

void  HandleCommandL (TInt aCommand)
virtual void  HandleResourceChangeL (TInt aType)

Private Attributes

CAknExPbarContainer *  iContainer


Constructor & Destructor Documentation

CAknExPbarAppUi::CAknExPbarAppUi (   ) 
 

CAknExPbarAppUi C++ default constructor.

Definition at line 34 of file aknexpbarappui.cpp.

00035     {
00036     // No implementation required
00037     }

CAknExPbarAppUi::~CAknExPbarAppUi (   )  [virtual]
 

~CAknExPbarAppUi Virtual Destructor.

Definition at line 58 of file aknexpbarappui.cpp.

References iContainer.

00059     {
00060     if ( iContainer )
00061         {
00062         RemoveFromStack( iContainer );
00063         delete iContainer;
00064         iContainer = NULL;
00065         }
00066     }


Member Function Documentation

void CAknExPbarAppUi::ConstructL (   ) 
 

ConstructL 2nd phase constructor.

Definition at line 44 of file aknexpbarappui.cpp.

References iContainer, and CAknExPbarContainer::NewL().

00045     {
00046     // Initialise app UI with standard value.
00047     BaseConstructL( EAknEnableSkin );
00048     
00049     iContainer = CAknExPbarContainer::NewL( ClientRect() );
00050     AddToStackL( iContainer );
00051     }

void CAknExPbarAppUi::HandleCommandL (  TInt  aCommand  )  [private]
 

HandleCommandL. Takes care of command handling.

Parameters:
aCommand  Command to be handled.

Definition at line 73 of file aknexpbarappui.cpp.

References iContainer, CAknExPbarContainer::IncrementBarsAndDraw(), CAknExPbarContainer::SetFinalValue(), and CAknExPbarContainer::ShowInfo().

00074     {
00075     TInt increment = KInitIncrement;
00076     
00077     switch ( aCommand )
00078         {
00079         case EAknCmdExit:
00080         case EAknSoftkeyExit:
00081         case EEikCmdExit:
00082             Exit();
00083             return; // returns if exit
00084 
00085         case EProgCmdChangeSetFinalValue1:
00086             iContainer->SetFinalValue();
00087             break;
00088 
00089         case EProgCmdChangeShowInfo0:
00090             iContainer->ShowInfo( EAknExpBarBar0 );
00091             break;
00092 
00093         case EProgCmdChangeShowInfo1:
00094             iContainer->ShowInfo( EAknExpBarBar1 );
00095             break;
00096 
00097         default:
00098             break;
00099         }
00100         
00101     if ( increment )
00102         {
00103         iContainer->IncrementBarsAndDraw( increment );
00104         }
00105    
00106     }

void CAknExPbarAppUi::HandleResourceChangeL (  TInt  aType  )  [private, virtual]
 

HandleResourceChangeL() Called by framework when layout is changed.

Parameters:
aType  The type of resources that have changed.

Definition at line 113 of file aknexpbarappui.cpp.

References iContainer, and CAknExPbarContainer::ReConstructProgressBarsL().

00114     {
00115     CAknAppUi::HandleResourceChangeL( aType );
00116        
00117     if ( aType==KEikDynamicLayoutVariantSwitch )
00118         {
00119         TRect rect;
00120         AknLayoutUtils::LayoutMetricsRect(AknLayoutUtils::EMainPane, rect);
00121         iContainer->SetRect( rect );
00122         iContainer->ReConstructProgressBarsL();
00123         }   
00124     //Controls derived from CCoeControl, handled in container class
00125     iContainer->HandleResourceChange( aType );                   
00126     }


Member Data Documentation

CAknExPbarContainer* CAknExPbarAppUi::iContainer [private]
 

iContainer, The application view Not owned by CAknExPbarAppUi object.

Definition at line 88 of file aknexpbarappui.h.

Referenced by ConstructL(), HandleCommandL(), HandleResourceChangeL(), and ~CAknExPbarAppUi().


The documentation for this class was generated from the following files:

© Nokia 2009

Back to top