CEikStatusPaneBase Class Reference

API published in: S60 1st Ed

Link against: eikcoctl.lib

Capability Information

Required Capabilities

None


#include <eikspane.h>

Inherited by CEikStatusPane.


Detailed Description

The base class for status panes.

Public Types

enum   TDrawCmd { ENoDraw, EDrawNow, EDrawDeferred }
  Status pane drawing commands. More...

Public Member Functions

IMPORT_C  ~CEikStatusPaneBase ()
  Destructor.
void  SetObserver (MEikStatusPaneObserver *aObserver)
  Sets the status pane observer.
IMPORT_C void  ReduceRect (TRect &aBoundingRect) const
  Modifies the bounding rectangle so that it lies next to the status pane rectangle.
IMPORT_C void  GetShapeL (TRegion &aRegion, TBool aIncludeAppPanes, TBool aIncludeServerPanes) const
  Adds and removes pane rectangles from aRegion.
virtual IMPORT_C void  SwitchLayoutL (TInt aLayoutResourceId)
  Switches to the specified status pane layout.
virtual IMPORT_C void  MakeVisible (TBool aVisible)
  Sets the visiblility of the status pane and its contents.
virtual IMPORT_C void  SetDimmed (TBool aDimmed)
  Sets the status pane and its contents to dimmed state.
virtual IMPORT_C void  SetFaded (TBool aFaded)
  Not implemented.
virtual IMPORT_C void  HandleResourceChange (TInt aType)
  Handles changes in resources which are shared across the environment.
virtual IMPORT_C TBool  OkToChangeStatusPaneNow ()
  Returns always ETrue.
IMPORT_C void  SetFlags (TInt aFlags)
  Sets all the visual flags at once (KEikStatusPaneBaseVisibleBitdimmed and KEikStatusPaneBaseDimmedBit).
IMPORT_C TInt  Flags () const
  Gets status pane settings.
IMPORT_C TBool  IsVisible () const
  Gets the visibility of the status pane.
IMPORT_C TBool  IsDimmed () const
  Gets the dimmed state of the status pane.
IMPORT_C TBool  IsFaded () const
  Gets the fade status of the status pane.
IMPORT_C TPaneCapabilities  PaneCapabilities (TPaneId aPaneId) const
  Gets the capabilities of the status pane.
IMPORT_C TRect  PaneRectL (TPaneId aPaneId) const
  Provides the screen rectangle of a sub pane.
IMPORT_C CCoeControl *  ControlL (TPaneId aPaneId) const
  Provides the control currently inside a sub pane.
IMPORT_C CCoeControl *  SwapControlL (TPaneId aPaneId, CCoeControl *aNewControl)
  Swaps the control currently inside a sub pane.
IMPORT_C CCoeControl *  ContainerControlL (TPaneId aPaneId) const
  Provides access to the container control for a sub pane.
RWindowGroup *  WindowGroup () const
  Provides access to a server-side window group.
IMPORT_C void  DrawNow ()
  Draws the control.
IMPORT_C TInt  CurrentLayoutResId () const
  Gets the resource id of the current layout.
void  SetCbaAreaBackgroundID (const TAknsItemID &aBgID, CEikStatusPaneBase::TDrawCmd aDrawCmd)
  Sets the skin background ID of sub-panes which are in the CBA area.
TAknsItemID  CbaAreaBackgroundID ()
  Returns the current skin background ID of the sub-panes which are in the CBA area.
void  ReportSizeChange ()
  Notifies the command button area and status pane observer about the status pane size change.

Static Public Member Functions

static IMPORT_C CEikStatusPaneBase Current ()
  Gets a pointer to the thread's currently active status pane without transferring ownership.

Protected Types

typedef CArrayPtrFlat< CEikStatusPaneContainer >  CContainerControls

Protected Member Functions

IMPORT_C  CEikStatusPaneBase (CEikonEnv &aEikEnv, RWindowGroup *aParent)
  C++ default constructor.
IMPORT_C void  BaseConstructL (TInt aCoreResId)
  Initializes the status pane with standard values.
virtual CEikStatusPaneModelBase CreateModelL (TInt aCoreResId) const =0
  Creates a new model for the status pane.
void  CreatePanesL ()
  Creates sub panes to the status pane.
void  CreatePaneL (const TEikStatusPaneInit &aPaneInit)
  Creates a sub pane.
CEikStatusPaneContainer *  Find (TPaneId aPaneId) const
  Gets a container of a wanted pane.
virtual TBool  IsApp () const =0
  Returns always ETrue.
TRect  Rect () const
  Gets the rectangle of the status pane.
void  DoDrawNow (TDrawCmd aDraw)
  Calls CCoeControl's DrawNow() or DrawDeferred() to draw the status pane.
CAknStatuspaneClearer *  Clearer ()
  Gets the status pane clearer.
IMPORT_C void  DisableClearer (TBool aDisabled)
  Disables the status pane clearer.
IMPORT_C void  CommonPrepareForAppExit ()
  Prepares the status pane for the application exit.
CAknStatusPaneDataSubscriber *  DataSubscriber () const
  Gets the status pane data subscriber.
void  SetInitialUsedResourceId (TInt aResourceId)
  Sets the initial status pane resource id to an extension class CEikStatusPaneBaseExtension.
void  OptimizeClearerWindowShape (TInt aOldResourceId, TInt aNewResourceId, TRegion &aRegion)
  Optimizes the status pane region which cleared during status pane layout change.
void  SetStoreHandler (RWindow *aWindow, TBool aOn)
  Sets redraw storing state of the window.

Protected Attributes

CEikonEnv &  iEikEnv
  An environment for creating controls and utility functions for manipulating them.
CEikStatusPaneModelBase iModel
  Status pane model class.
TInt  iFlags
  Flags for the status pane.
CContainerControls iControls

Friends

class  TSetRectAndVisibility

Data Structures

class   TPaneCapabilities
  Describes the capabilities of a subpane. More...
class   TSetRectAndVisibility

Member Typedef Documentation

typedef CArrayPtrFlat<CEikStatusPaneContainer> CEikStatusPaneBase::CContainerControls [protected]
 

Member Enumeration Documentation

enum CEikStatusPaneBase::TDrawCmd
 

Status pane drawing commands.

Enumerator:
ENoDraw  Do not draw.
EDrawNow  Draw immediately.
EDrawDeferred  Draw with low priority.

Constructor & Destructor Documentation

IMPORT_C CEikStatusPaneBase::~CEikStatusPaneBase  ) 
 

Destructor.

IMPORT_C CEikStatusPaneBase::CEikStatusPaneBase CEikonEnv &  aEikEnv,
RWindowGroup *  aParent
[protected]
 

C++ default constructor.

Parameters:
aEikEnv  An environment for creating controls and utility functions for manipulating them.
aParent  Pointer to the parent window group.

Member Function Documentation

IMPORT_C void CEikStatusPaneBase::BaseConstructL TInt  aCoreResId  )  [protected]
 

Initializes the status pane with standard values.

Parameters:
aCoreResId  Id for the status pane resource.
TAknsItemID CEikStatusPaneBase::CbaAreaBackgroundID  ) 
 

Returns the current skin background ID of the sub-panes which are in the CBA area.

CAknStatuspaneClearer* CEikStatusPaneBase::Clearer  )  [protected]
 

Gets the status pane clearer.

Returns:
Pointer to the status pane clearer instance.
IMPORT_C void CEikStatusPaneBase::CommonPrepareForAppExit  )  [protected]
 

Prepares the status pane for the application exit.

Clears the status pane.

IMPORT_C CCoeControl* CEikStatusPaneBase::ContainerControlL TPaneId  aPaneId  )  const
 

Provides access to the container control for a sub pane.

You will need access to the container for a sub pane if you want to swap in a new control. The container control should be set as the parent window of the new control. It also provides a fast way to get the rectangle of the sub pane (

See also:
PaneRect()).
Parameters:
aPaneId  Status pane ID.
Returns:
Pointer to the new container control for the subpane.
Leave:
KErrNotFound The subpane ID is not valid.
IMPORT_C CCoeControl* CEikStatusPaneBase::ControlL TPaneId  aPaneId  )  const
 

Provides the control currently inside a sub pane.

This gives the application direct access to the contents of a pane.

Parameters:
aPaneId  The status pane id.
Returns:
Pointer to the control instance inside of the sub pane.
Leave:
KErrNotFound The subpane ID is not valid.
virtual CEikStatusPaneModelBase* CEikStatusPaneBase::CreateModelL TInt  aCoreResId  )  const [protected, pure virtual]
 

Creates a new model for the status pane.

Parameters:
aCoreResId  Id for the status pane resource.
Returns:
Pointer to the new status pane model instance.
void CEikStatusPaneBase::CreatePaneL const TEikStatusPaneInit aPaneInit  )  [protected]
 

Creates a sub pane.

Parameters:
[in]  aPaneInit  Initial values for the sub pane.
void CEikStatusPaneBase::CreatePanesL  )  [protected]
 

Creates sub panes to the status pane.

static IMPORT_C CEikStatusPaneBase* CEikStatusPaneBase::Current  )  [static]
 

Gets a pointer to the thread's currently active status pane without transferring ownership.

Returns:
Pointer to currently active status pane. Returns NULL if no such pane exists.
IMPORT_C TInt CEikStatusPaneBase::CurrentLayoutResId  )  const
 

Gets the resource id of the current layout.

Returns:
The Resource id of the current layout.
See also:
avkon.rsg
CAknStatusPaneDataSubscriber* CEikStatusPaneBase::DataSubscriber  )  const [protected]
 

Gets the status pane data subscriber.

Returns:
Pointer to the status pane data subscriber.
IMPORT_C void CEikStatusPaneBase::DisableClearer TBool  aDisabled  )  [protected]
 

Disables the status pane clearer.

Parameters:
aDisabled  Disabled if ETrue.
void CEikStatusPaneBase::DoDrawNow TDrawCmd  aDraw  )  [protected]
 

Calls CCoeControl's DrawNow() or DrawDeferred() to draw the status pane.

If aDraw is ENoDraw status pane is not drawed.

Parameters:
aDraw  Status pane drawing commands.
IMPORT_C void CEikStatusPaneBase::DrawNow  ) 
 

Draws the control.

CEikStatusPaneContainer* CEikStatusPaneBase::Find TPaneId  aPaneId  )  const [protected]
 

Gets a container of a wanted pane.

Parameters:
aPaneId  The pane id.
Returns:
Pointer to the container of the pane with a given id.
IMPORT_C TInt CEikStatusPaneBase::Flags  )  const
 

Gets status pane settings.

Returns:
Flags used by status pane base class.
IMPORT_C void CEikStatusPaneBase::GetShapeL TRegion &  aRegion,
TBool  aIncludeAppPanes,
TBool  aIncludeServerPanes
const
 

Adds and removes pane rectangles from aRegion.

Parameters:
aRegion  The two-dimensional area from where rectangles are removed from or where rectangles are added to.
aIncludeAppPanes  If ETrue, app panes are added, otherwise removed.
aIncludeServerPanes  If ETrue, server panes are added, otherwise removed.
virtual IMPORT_C void CEikStatusPaneBase::HandleResourceChange TInt  aType  )  [virtual]
 

Handles changes in resources which are shared across the environment.

This function responds to the changes in resources by propagating them to sub-parts of the status pane.

Parameters:
aType  A message type.

Reimplemented in CEikStatusPane.

virtual TBool CEikStatusPaneBase::IsApp  )  const [protected, pure virtual]
 

Returns always ETrue.

Returns:
ETrue.
IMPORT_C TBool CEikStatusPaneBase::IsDimmed  )  const
 

Gets the dimmed state of the status pane.

Returns:
ETrue if the status pane is dimmed.
IMPORT_C TBool CEikStatusPaneBase::IsFaded  )  const
 

Gets the fade status of the status pane.

Returns:
ETrue if status pane is faded.
IMPORT_C TBool CEikStatusPaneBase::IsVisible  )  const
 

Gets the visibility of the status pane.

Returns:
ETrue if the status pane is visible.
virtual IMPORT_C void CEikStatusPaneBase::MakeVisible TBool  aVisible  )  [virtual]
 

Sets the visiblility of the status pane and its contents.

Parameters:
aVisible  If ETrue the status pane and its contents are set visible.

Reimplemented in CEikStatusPane.

virtual IMPORT_C TBool CEikStatusPaneBase::OkToChangeStatusPaneNow  )  [virtual]
 

Returns always ETrue.

Returns:
ETrue.

Reimplemented in CEikStatusPane.

void CEikStatusPaneBase::OptimizeClearerWindowShape TInt  aOldResourceId,
TInt  aNewResourceId,
TRegion &  aRegion
[protected]
 

Optimizes the status pane region which cleared during status pane layout change.

Parameters:
aOldResourceId  Old status pane resource ID.
aNewResourceId  New status pane resource ID.
[in,out]  aRegion  Status pane region. On return contains only the region that needs to be cleared.
IMPORT_C TPaneCapabilities CEikStatusPaneBase::PaneCapabilities TPaneId  aPaneId  )  const
 

Gets the capabilities of the status pane.

Parameters:
aPaneId  Status pane id.
Returns:
Status pane capabilities.
IMPORT_C TRect CEikStatusPaneBase::PaneRectL TPaneId  aPaneId  )  const
 

Provides the screen rectangle of a sub pane.

This can be used to set the size of a new control which you want to place in the status pane.

Parameters:
aPaneId  Status pane id.
Returns:
The sub pane rectangle.
Leave:
KErrNotFound The subpane ID is not valid.
TRect CEikStatusPaneBase::Rect  )  const [inline, protected]
 

Gets the rectangle of the status pane.

Returns:
The rectangle used by the status pane.
IMPORT_C void CEikStatusPaneBase::ReduceRect TRect &  aBoundingRect  )  const
 

Modifies the bounding rectangle so that it lies next to the status pane rectangle.

The status pane always places itself along the edge of the screen, so that it is consistent across applications and the server. It is assumed that the given bounding rectangle does not extend beyond the screen area.

Parameters:
[in,out]  aBoundingRect  The bounding rectangle.
void CEikStatusPaneBase::ReportSizeChange  ) 
 

Notifies the command button area and status pane observer about the status pane size change.

If the status pane is an embedded application, also this application is notified.

void CEikStatusPaneBase::SetCbaAreaBackgroundID const TAknsItemID aBgID,
CEikStatusPaneBase::TDrawCmd  aDrawCmd
 

Sets the skin background ID of sub-panes which are in the CBA area.

virtual IMPORT_C void CEikStatusPaneBase::SetDimmed TBool  aDimmed  )  [virtual]
 

Sets the status pane and its contents to dimmed state.

Parameters:
aDimmed  If ETrue the status pane and its contents are set to dimmed state.

Reimplemented in CEikStatusPane.

virtual IMPORT_C void CEikStatusPaneBase::SetFaded TBool  aFaded  )  [virtual]
 

Not implemented.

Parameters:
aFaded  Not used.

Reimplemented in CEikStatusPane.

IMPORT_C void CEikStatusPaneBase::SetFlags TInt  aFlags  ) 
 

Sets all the visual flags at once (KEikStatusPaneBaseVisibleBitdimmed and KEikStatusPaneBaseDimmedBit).

Parameters:
aFlags  Flags to be set.
void CEikStatusPaneBase::SetInitialUsedResourceId TInt  aResourceId  )  [protected]
 

Sets the initial status pane resource id to an extension class CEikStatusPaneBaseExtension.

Parameters:
aResourceId  The initial status pane resource id.
void CEikStatusPaneBase::SetObserver MEikStatusPaneObserver aObserver  )  [inline]
 

Sets the status pane observer.

Parameters:
aObserver  Pointer to status pane observer.
void CEikStatusPaneBase::SetStoreHandler RWindow *  aWindow,
TBool  aOn
[protected]
 

Sets redraw storing state of the window.

Parameters:
aWindow  The window whose redraw storing state is to be set.
aOn  ETrue to turn redraw storing on.
IMPORT_C CCoeControl* CEikStatusPaneBase::SwapControlL TPaneId  aPaneId,
CCoeControl *  aNewControl
 

Swaps the control currently inside a sub pane.

The new control must be a fully constructed control. It will be placed inside the status pane, and the current content will be returned to the caller.

Parameters:
aPaneId  ID of the subpane.
aNewControl  A fully constructed control to place at aPaneId.
Returns:
The control which was at aPaneId.
Leave:
KErrNotFound This can occur before ownership of the new control is taken, if the subpane ID is not valid.
virtual IMPORT_C void CEikStatusPaneBase::SwitchLayoutL TInt  aLayoutResourceId  )  [virtual]
 

Switches to the specified status pane layout.

The actual layout to which this method switches may not be the same as specified in aLayoutResourceId parameter. Eg. if landscape mode status pane layout is set with this method, while in portrait mode, it's mapped to the corresponding layout in the portrait mode. This should be noted when using CEikStatusPaneBase::CurrentLayoutResId().

From S60 3.2 on the old status pane layouts are also mapped to the new layouts, ie. R_AVKON_STATUS_PANE_LAYOUT_USUAL -> R_AVKON_STATUS_PANE_LAYOUT_USUAL_EXT

R_AVKON_STATUS_PANE_LAYOUT_IDLE -> R_AVKON_STATUS_PANE_LAYOUT_IDLE_EXT

Parameters:
aLayoutResourceId  Layout resource Id. This must be one of the layouts identified in the status pane resource structures, otherwise the function leaves KErrNotFound.
See also:
avkon.rsg
Leave:
KErrNotFound The specified layout does not exist in the status pane resource structures.
RWindowGroup * CEikStatusPaneBase::WindowGroup  )  const [inline]
 

Provides access to a server-side window group.

Returns:
Pointer to the window group.

Friends And Related Function Documentation

friend class TSetRectAndVisibility [friend]
 

Field Documentation

CContainerControls* CEikStatusPaneBase::iControls [protected]
 
CEikonEnv& CEikStatusPaneBase::iEikEnv [protected]
 

An environment for creating controls and utility functions for manipulating them.

TInt CEikStatusPaneBase::iFlags [protected]
 

Flags for the status pane.

CEikStatusPaneModelBase* CEikStatusPaneBase::iModel [protected]
 

Status pane model class.


Own.


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

Copyright © Nokia Corporation 2001-2008
Back to top