CAiwMenuPane Class Reference

class CAiwMenuPane : public CBase

CAiwMenuPane for providers to have limited access to consumer menu.

AIW provider can get a reference to CAiwMenuPane in its InitializeMenuPaneL() method, which is derived from CAiwServiceIfMenu . With this reference, the provider can e.g. insert menu items to the consumer application's menu.

ServiceHandler.lib
Since
Series 60 2.6

Inherits from

Nested Classes and Structures

Constructor & Destructor Documentation

CAiwMenuPane(CEikMenuPane &, TInt)

IMPORT_C CAiwMenuPane ( CEikMenuPane & aMenuPane,
TInt aBaseCmdId
)

Constructor.

Parameters

CEikMenuPane & aMenuPane Consumer's menu pane handle.
TInt aBaseCmdId Base command ID for new menu items, specified by consumer.

~CAiwMenuPane()

IMPORT_C ~CAiwMenuPane ( ) [virtual]

Destructor.

Member Functions Documentation

AddMenuItemL(TInt, CEikMenuPaneItem::SData &, TInt)

IMPORT_C void AddMenuItemL ( TInt aServiceCmd,
CEikMenuPaneItem::SData & aMenuItem,
TInt aIndex
)

Adds a menu item to consumer menu. For each addition a mapping element is created. This method should normally be called from provider's InitializeMenuPaneL().

Parameters

TInt aServiceCmd The AIW service command the provider implements.
CEikMenuPaneItem::SData & aMenuItem The menu item data.
TInt aIndex Position of item where to add menu items.

AddMenuItemL(TInt, CEikMenuPaneItem::SData &, TInt, const TDesC &)

IMPORT_C void AddMenuItemL ( TInt aServiceCmd,
CEikMenuPaneItem::SData & aMenuItem,
TInt aIndex,
const TDesC & aExtraText
)

Adds a menu item to consumer menu. For each addition a mapping element is created. This method should normally be called from provider's InitializeMenuPaneL().

Parameters

TInt aServiceCmd The AIW service command the provider implements.
CEikMenuPaneItem::SData & aMenuItem The menu item data.
TInt aIndex Position of item where to add menu items.
const TDesC & aExtraText Altenative menu item text, if it is placed to a submenu.

AddMenuItemsL(TResourceReader &, TInt, TInt, TBool)

IMPORT_C void AddMenuItemsL ( TResourceReader & aReader,
TInt aServiceCmd,
TInt aIndex,
TBool aAddSeperator = EFalse
)

Adds a menu item(s) to consumer menu from provider resource. This method should normally be called from provider's InitializeMenuPaneL().

Parameters

TResourceReader & aReader Resource reader pointing to the menu resource.
TInt aServiceCmd The AIW service command the provider implements.
TInt aIndex Position of item where to add menu items.
TBool aAddSeperator = EFalse

AddMenuItemsL(TFileName &, TInt, TInt, TInt, TBool)

IMPORT_C void AddMenuItemsL ( TFileName & aFileName,
TInt aResId,
TInt aServiceCmd,
TInt aIndex,
TBool aAddSeperator = EFalse
)

Adds a menu item(s) to consumer menu from provider resource. This method should normally be called from provider's InitializeMenuPaneL().

Parameters

TFileName & aFileName The provider's resource where menu item(s) are defined.
TInt aResId Resource id of a MENU_PANE.
TInt aServiceCmd The AIW service command the provider implements.
TInt aIndex Position of item where to add menu items.
TBool aAddSeperator = EFalse Currently not in use.

AddTitleItemL(const TDesC &, TInt)

IMPORT_C void AddTitleItemL ( const TDesC & aTitle,
TInt aIndex
)

Add sub menu title item. This item will not be visible in menus, but will be used as title for comsumer's AIW submenu (if consumer requests that).

Since
2.8

Parameters

const TDesC & aTitle Title text
TInt aIndex Position of title item in menu (can be anything, but if there is several title item definitions in menu, then the last one will be used).

CommandOwner(TInt)

CAiwServiceIfBase * CommandOwner ( TInt aDynId ) const [private]

Parameters

TInt aDynId

DynCmdId(TInt)

IMPORT_C TInt DynCmdId ( TInt aMenuCmdId ) const

Gets the dynamic menu command ID (generated by the AIW framework) from the provider's original menu command ID. There are usually multiple matching dynamic menu command IDs, so this method returns the first item found.

Parameters

TInt aMenuCmdId Provider's original menu command ID.

ExtraText(TInt)

const TDesC & ExtraText ( TInt aDynMenuCmdId ) [private]

Parameters

TInt aDynMenuCmdId

FindCmdId(TInt)

TInt FindCmdId ( TInt aIndex ) [private]

Parameters

TInt aIndex

InitializingOwner()

CAiwServiceIfBase * InitializingOwner ( ) const [private, inline]

IsCmdInRange(TInt, TInt)

TBool IsCmdInRange ( TInt aCmdSpaceSize,
TInt aCmd
) [private]

Parameters

TInt aCmdSpaceSize
TInt aCmd

MenuCmdId(TInt)

IMPORT_C TInt MenuCmdId ( TInt aDynCmdId ) const

Gets the provider's original menu command ID from the dynamic menu command ID (generated by the AIW framework).

Parameters

TInt aDynCmdId Dynamic menu command ID.

MenuPane()

CEikMenuPane & MenuPane ( ) [private, inline]

MenuResourceId()

TInt MenuResourceId ( ) const [private, inline]

PaneOffset()

TInt PaneOffset ( ) const [private, inline]

ResourceSlotId()

TInt ResourceSlotId ( ) const [private, inline]

ServiceCmdId(TInt)

IMPORT_C TInt ServiceCmdId ( TInt aDynCmdId ) const

Gets the AIW service command ID from the dynamic menu command ID (generated by the AIW framework).

Parameters

TInt aDynCmdId Dynamic menu command ID.

SetInitializingOwner(CAiwServiceIfBase *)

void SetInitializingOwner ( CAiwServiceIfBase * aOwner ) [private, inline]

Parameters

CAiwServiceIfBase * aOwner

SetMenuResourceId(TInt)

void SetMenuResourceId ( TInt aMenuResourceId ) [private, inline]

Parameters

TInt aMenuResourceId

SetPaneOffset(TInt)

void SetPaneOffset ( TInt aOffset ) [private, inline]

Parameters

TInt aOffset

SetResourceSlotId(TInt)

void SetResourceSlotId ( TInt aSlot ) [private, inline]

Parameters

TInt aSlot

Member Data Documentation

TInt iBaseCmdId

TInt iBaseCmdId [private]

void * iExtension

void * iExtension [private]

RArray< SMenuIdMap > iIdMap

RArray < SMenuIdMap > iIdMap [private]

CAiwServiceIfBase * iInitializingOwner

CAiwServiceIfBase * iInitializingOwner [private]

CEikMenuPane * iMenuPane

CEikMenuPane * iMenuPane [private]

TInt iMenuResourceId

TInt iMenuResourceId [private]

TInt iNextCmdId

TInt iNextCmdId [private]

TInt iPaneOffset

TInt iPaneOffset [private]

TInt iReserved_1

TInt iReserved_1 [private]

TInt iResourceSlotId

TInt iResourceSlotId [private]