CAknsBasicBackgroundControlContext Class Reference

API published in: S60 2nd Ed

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

Capability Information

Required Capabilities

None


#include <aknsbasicbackgroundcontrolcontext.h>

Inherits MAknsControlContext.

Inherited by CAknsLayeredBackgroundControlContext, and CAknsListBoxBackgroundControlContext.


Detailed Description

Implementation of a control context that provides a layout background with a background bitmap and its layout rectangle.

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


Public Member Functions

virtual  ~CAknsBasicBackgroundControlContext ()
  Destructor.
IMPORT_C void  SetBitmap (const TAknsItemID &aID)
  Sets the item ID of the background bitmap.
IMPORT_C void  SetRect (const TRect &aRect)
  Sets the layout rectangle of the bitmap.
IMPORT_C void  SetParentPos (const TPoint &aPos)
  Sets the parent position for the layout.
IMPORT_C void  SetParentContext (MAknsControlContext *aParentContext)
  Sets the parent context (drawn beneath the context itself).
TInt  SupplySkinParameter (TAknsCCParameter aParam)
  Provides context specific integer parameter.

Parameters:
aParam  Type of the parameter to be retrieved. Possible values are defined in TAknsCCParameter enumeration.
Returns:
Integer value as defined in TAknsCCParameter for the particular parameter. For unknown or unhandled values zero must be returned.

TAny *  SupplySkinObject (TAknsCCObject aObject)
  Provides context specific object.

Parameters:
aObject  Type of the object to be retrieved. Possible values are defined in TAknsCCObject enumeration.
Returns:
Pointer to object as defined in TAknsCCObject for that specific aObject parameter value. For unknown or unhandled values NULL must be returned.

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.


Static Public Member Functions

static IMPORT_C CAknsBasicBackgroundControlContext NewL (const TAknsItemID &aImageID, const TRect &aRect, TBool aParentAbsolute)
  Two-phased constructor.

Protected Member Functions

  CAknsBasicBackgroundControlContext ()
  C++ constructor.
void  ConstructL (const TRect &aRect, TBool aParentAbsolute, const TAknsItemID &aImageID)
  Symbian 2nd phase constructor.

Protected Attributes

TAknsBackground *  iLayout
MAknsControlContext iParentContext

Constructor & Destructor Documentation

virtual CAknsBasicBackgroundControlContext::~CAknsBasicBackgroundControlContext  )  [virtual]
 

Destructor.

CAknsBasicBackgroundControlContext::CAknsBasicBackgroundControlContext  )  [protected]
 

C++ constructor.


Member Function Documentation

void CAknsBasicBackgroundControlContext::ConstructL const TRect &  aRect,
TBool  aParentAbsolute,
const TAknsItemID aImageID
[protected]
 

Symbian 2nd phase constructor.

TBool CAknsBasicBackgroundControlContext::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.

Implements MAknsControlContext.

Reimplemented in CAknsFrameBackgroundControlContext, CAknsLayeredBackgroundControlContext, and CAknsListBoxBackgroundControlContext.

static IMPORT_C CAknsBasicBackgroundControlContext* CAknsBasicBackgroundControlContext::NewL const TAknsItemID aImageID,
const TRect &  aRect,
TBool  aParentAbsolute
[static]
 

Two-phased constructor.

Parameters:
aImageID  Item ID of the background bitmap.
aRect  Rectangle where the bitmap should be laid out.
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 CAknsBasicBackgroundControlContext::SetBitmap const TAknsItemID aID  ) 
 

Sets the item ID of the background bitmap.

Parameters:
aID  Item ID of the bitmap.
IMPORT_C void CAknsBasicBackgroundControlContext::SetParentContext MAknsControlContext aParentContext  ) 
 

Sets the parent context (drawn beneath the context itself).

No ownership is claimed. The parent context object must be valid as long as it is set as parent context.

Parameters:
aParentContext  Pointer to the parent context, or NULL (default value) if none used.
IMPORT_C void CAknsBasicBackgroundControlContext::SetParentPos const TPoint &  aPos  ) 
 

Sets the parent position for the layout.

This is only used if parent absolute layout was enabled during construction.

Parameters:
aPos  Parent position in screen relative coordinates.
IMPORT_C void CAknsBasicBackgroundControlContext::SetRect const TRect &  aRect  ) 
 

Sets the layout rectangle of the bitmap.

Parameters:
aRect  Rectangle where the bitmap should be laid out.
TAny* CAknsBasicBackgroundControlContext::SupplySkinObject TAknsCCObject  aObject  )  [virtual]
 

Provides context specific object.

Parameters:
aObject  Type of the object to be retrieved. Possible values are defined in TAknsCCObject enumeration.
Returns:
Pointer to object as defined in TAknsCCObject for that specific aObject parameter value. For unknown or unhandled values NULL must be returned.

Implements MAknsControlContext.

TInt CAknsBasicBackgroundControlContext::SupplySkinParameter TAknsCCParameter  aParam  )  [virtual]
 

Provides context specific integer parameter.

Parameters:
aParam  Type of the parameter to be retrieved. Possible values are defined in TAknsCCParameter enumeration.
Returns:
Integer value as defined in TAknsCCParameter for the particular parameter. For unknown or unhandled values zero must be returned.

Implements MAknsControlContext.


Field Documentation

TAknsBackground* CAknsBasicBackgroundControlContext::iLayout [protected]
 
MAknsControlContext* CAknsBasicBackgroundControlContext::iParentContext [protected]
 

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

Copyright © Nokia Corporation 2001-2008
Back to top