CAknsFrameBackgroundControlContext Class Reference

API published in: S60 2nd Ed

Link against: aknskins.lib aknskinsrv.lib aknswallpaperutils.lib

Capability Information

Required Capabilities

None


#include <aknsframebackgroundcontrolcontext.h>

Inherits CAknsLayeredBackgroundControlContext.


Detailed Description

Implementation of a control context that provides a layout background generated from a frame item.

This is a public class with exported functions. The class is not intended for derivation outside the library.


Public Member Functions

virtual  ~CAknsFrameBackgroundControlContext ()
  Destructor.
IMPORT_C void  SetFrame (const TAknsItemID &aFrameID)
  Reconstructs the entire frame from the given item ID.
IMPORT_C void  SetFrameRects (const TRect &aOuterRect, const TRect &aInnerRect)
  Sets the outer and the inner rectangles of the frame.
IMPORT_C void  SetCenter (const TAknsItemID &aID)
  Overrides the center part of the frame.
IMPORT_C void  SetFramePartRect (const TRect &aRect, const TAknsFrameElementIndex aFrameElement)
  Sets the rectangle of a single part of the frame.
TBool  IsCompatibleWithType (const TAknsControlContextType aType) const
  Determines whether this control context is compatible with the given derived type.

Parameters:
aType  Type of the derived control context class (one of the values in TAknsControlContextType).
Returns:
ETrue if this control context instance is compatible with the given type (i.e. can be casted to the corresponding concrete class). EFalse otherwise.

TInt  UpdateContext ()
  Updates the control context, if necessary.

Static Public Member Functions

static IMPORT_C CAknsFrameBackgroundControlContext NewL (const TAknsItemID &aFrameID, const TRect &aOuterRect, const TRect &aInnerRect, const TBool aParentAbsolute)
  Two-phased constructor.

Protected Member Functions

void  UpdateFrame ()
  Updates the type-dependant parameters of the frame.
  CAknsFrameBackgroundControlContext ()
  C++ constructor.
void  ConstructL (const TAknsItemID &aFrameID, const TRect &aOuterRect, const TRect &aInnerRect, const TBool aParentAbsolute)
  Symbian 2nd phase constructor.

Protected Attributes

TAknsItemID  iFrameID
TAknsItemID  iCenterID
TRect  iInnerRect
TRect  iOuterRect
TBool  iSingleElementFrame

Constructor & Destructor Documentation

virtual CAknsFrameBackgroundControlContext::~CAknsFrameBackgroundControlContext  )  [virtual]
 

Destructor.

CAknsFrameBackgroundControlContext::CAknsFrameBackgroundControlContext  )  [protected]
 

C++ constructor.


Member Function Documentation

void CAknsFrameBackgroundControlContext::ConstructL const TAknsItemID aFrameID,
const TRect &  aOuterRect,
const TRect &  aInnerRect,
const TBool  aParentAbsolute
[protected]
 

Symbian 2nd phase constructor.

TBool CAknsFrameBackgroundControlContext::IsCompatibleWithType const TAknsControlContextType  aType  )  const [virtual]
 

Determines whether this control context is compatible with the given derived type.

Parameters:
aType  Type of the derived control context class (one of the values in TAknsControlContextType).
Returns:
ETrue if this control context instance is compatible with the given type (i.e. can be casted to the corresponding concrete class). EFalse otherwise.

Reimplemented from CAknsLayeredBackgroundControlContext.

static IMPORT_C CAknsFrameBackgroundControlContext* CAknsFrameBackgroundControlContext::NewL const TAknsItemID aFrameID,
const TRect &  aOuterRect,
const TRect &  aInnerRect,
const TBool  aParentAbsolute
[static]
 

Two-phased constructor.

Parameters:
aFrameID  Item ID of the entire frame.
aOuterRect  Outer rectangle of the frame.
aInnerRect  Inner rectangle of the frame.
aParentAbsolute  ETrue if parent absolute layout should be used, EFalse otherwise. If a parent absolute layout is used, the parent position must be set and updated using SetParentPos.
Returns:
Newly constructed object.
IMPORT_C void CAknsFrameBackgroundControlContext::SetCenter const TAknsItemID aID  ) 
 

Overrides the center part of the frame.

Parameters:
aID  Item ID of the center part to be used.
IMPORT_C void CAknsFrameBackgroundControlContext::SetFrame const TAknsItemID aFrameID  ) 
 

Reconstructs the entire frame from the given item ID.

Parameters:
aID  Item ID of the entire frame.
IMPORT_C void CAknsFrameBackgroundControlContext::SetFramePartRect const TRect &  aRect,
const TAknsFrameElementIndex  aFrameElement
 

Sets the rectangle of a single part of the frame.

Parameters:
aRect  Rectangle of the specific part of the frame.
aFrameElement  Element (index) of the frame element to which the rectangle is applied.
IMPORT_C void CAknsFrameBackgroundControlContext::SetFrameRects const TRect &  aOuterRect,
const TRect &  aInnerRect
 

Sets the outer and the inner rectangles of the frame.

Parameters:
aOuterRect  The outer rectangle of the frame.
aInnerRect  The inner rectangle of the frame.
TInt CAknsFrameBackgroundControlContext::UpdateContext  )  [virtual]
 

Updates the control context, if necessary.

This method is called by the framework before drawing with the context.

Implementation in CAknsFrameBackgroundControlContext updates the items to ensure that transition between single-bitmap and multi-bitmap frames work as expected.

Returns:
Return value reserved for future use. Currently returns 0.

Reimplemented from MAknsControlContext.

void CAknsFrameBackgroundControlContext::UpdateFrame  )  [protected]
 

Updates the type-dependant parameters of the frame.


Field Documentation

TAknsItemID CAknsFrameBackgroundControlContext::iCenterID [protected]
 
TAknsItemID CAknsFrameBackgroundControlContext::iFrameID [protected]
 
TRect CAknsFrameBackgroundControlContext::iInnerRect [protected]
 
TRect CAknsFrameBackgroundControlContext::iOuterRect [protected]
 
TBool CAknsFrameBackgroundControlContext::iSingleElementFrame [protected]
 

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

Copyright © Nokia Corporation 2001-2008
Back to top