RAknsSrvSession Class Reference

class RAknsSrvSession : public RSessionBase

The client side interface class for the skins server Provides functionality to change the system skin, to retrieve skin content definitions from the server and to listen for skin change events.

AknSkinSrv.lib

Since
2.0

Inherits from

Public Member Functions
RAknsSrvSession()
TInt AcknowledgeSkinChangeNotification()
IMPORT_C voidAddWallpaperL(const TDesC &, const TSize &)
IMPORT_C TIntCheckIconConfiguration(TUid)
IMPORT_C TIntClearScalableGraphics()
IMPORT_C voidClientError(TInt)
IMPORT_C voidClose()
IMPORT_C TIntConnect(MAknsSkinChangeObserver *, TInt)
IMPORT_C TIntCopySkin(const TAknsPkgID, TAknSkinSrvSkinPackageLocation, TAknSkinSrvSkinPackageLocation)
IMPORT_C TIntCopySoundFile(const TDesC &, const TDesC &)
IMPORT_C CAknsSrvChunkLookup *CreateChunkLookupL()
IMPORT_C voidDecodeWallpaperImageL(const TDesC &, const TSize &, CFbsBitmap *&, CFbsBitmap *&)
IMPORT_C TIntDeleteSkin(const TAknsPkgID, TAknSkinSrvSkinPackageLocation)
IMPORT_C voidDisableSkinChangeNotify()
IMPORT_C voidEnableSkinChangeNotify()
IMPORT_C CArrayPtr< CAknsSrvSkinInformationPkg > *EnumerateSkinPackagesL(TAknSkinSrvSkinPackageLocation)
IMPORT_C voidFreeUnnecessaryLayoutBitmaps(TAknsSrcScreenMode)
IMPORT_C TIntOpenBitmapFile(const TDesC &, TInt &)
IMPORT_C TIntOpenImageInifile(TAknsSrvInifileType, TInt &)
IMPORT_C TIntOpenInifile(const TAknsPkgID, TAknSkinSrvSkinPackageLocation, TInt &, TBool)
IMPORT_C voidRemoveAllWallpapers()
IMPORT_C voidRemoveWallpaper(const TDesC &)
IMPORT_C TIntSetAllDefinitionSets(const TAknsPkgID)
IMPORT_C TIntSetIdleWallpaper(const TDesC &)
IMPORT_C TIntSetSlideSetWallpaper(const CDesCArray &)
IMPORT_C TIntStoreScalableGraphics(const TAknsItemID &, const TInt, const TSize &, const CFbsBitmap *, const CFbsBitmap *, TBool)
IMPORT_C CFbsBitmap *WallpaperImageL(const TDesC &)
Private Member Functions
voidEventHandled()
IMPORT_C TIntReserved1()
IMPORT_C TIntReserved2()
IMPORT_C TIntReserved3()
IMPORT_C voidReserved4()
voidSendCancel()
TVersion Version()
Inherited Functions
RHandleBase::Attributes()const
RHandleBase::BTraceId()const
RHandleBase::DoExtendedClose()
RHandleBase::Duplicate(const RThread &,TOwnerType)
RHandleBase::FullName()const
RHandleBase::FullName(TDes &)const
RHandleBase::Handle()const
RHandleBase::HandleInfo(THandleInfo *)
RHandleBase::Name()const
RHandleBase::NotifyDestruction(TRequestStatus &)
RHandleBase::Open(const TFindHandleBase &,TOwnerType)
RHandleBase::OpenByName(const TDesC &,TOwnerType,TInt)
RHandleBase::RHandleBase()
RHandleBase::RHandleBase(TInt)
RHandleBase::SetHandle(TInt)
RHandleBase::SetHandleNC(TInt)
RSessionBase::CreateSession(RServer2,const TVersion &)
RSessionBase::CreateSession(RServer2,const TVersion &,TInt)
RSessionBase::CreateSession(RServer2,const TVersion &,TInt,TIpcSessionType,const TSecurityPolicy *,TRequestStatus *)
RSessionBase::CreateSession(const TDesC &,const TVersion &)
RSessionBase::CreateSession(const TDesC &,const TVersion &,TInt)
RSessionBase::CreateSession(const TDesC &,const TVersion &,TInt,TIpcSessionType,const TSecurityPolicy *,TRequestStatus *)
RSessionBase::CreateSession(const TDesC &,const TVersion &,TInt,TRequestStatus *)
RSessionBase::Open(RMessagePtr2,TInt,TOwnerType)
RSessionBase::Open(RMessagePtr2,TInt,const TSecurityPolicy &,TOwnerType)
RSessionBase::Open(TInt,TOwnerType)
RSessionBase::Open(TInt,const TSecurityPolicy &,TOwnerType)
RSessionBase::Send(TInt)const
RSessionBase::Send(TInt,const TIpcArgs &)const
RSessionBase::SendReceive(TInt)const
RSessionBase::SendReceive(TInt,TRequestStatus &)const
RSessionBase::SendReceive(TInt,const TIpcArgs &)const
RSessionBase::SendReceive(TInt,const TIpcArgs &,TRequestStatus &)const
RSessionBase::SetReturnedHandle(TInt)
RSessionBase::SetReturnedHandle(TInt,RHandleBase &)
RSessionBase::SetReturnedHandle(TInt,const TSecurityPolicy &)
RSessionBase::ShareAuto()
RSessionBase::ShareProtected()
Inherited Enumerations
RHandleBase:TAttributes
RSessionBase:TAttachMode
Private Attributes
TAknsSrvClientMemberData *iMemberData
Inherited Attributes
RHandleBase::iHandle

Constructor & Destructor Documentation

RAknsSrvSession()

IMPORT_CRAknsSrvSession()

C++ default constructor.

Member Functions Documentation

AcknowledgeSkinChangeNotification()

TInt AcknowledgeSkinChangeNotification()

Acknowledges the skin change notification.

Since
2.7

AddWallpaperL(const TDesC &, const TSize &)

IMPORT_C voidAddWallpaperL(const TDesC &aFilename,
const TSize &aTargetSize
)

Add one wallpaper.

Parameters

const TDesC & aFilenamea fully qualified path(incl. path + filename) of the wallpaper
const TSize & aTargetSize- Decoded size. if not set, Both portait and landscape(base on screen size) will be decoded.

CheckIconConfiguration(TUid)

IMPORT_C TIntCheckIconConfiguration(TUidaAppUid)

Parameters

TUid aAppUid

ClearScalableGraphics()

IMPORT_C TIntClearScalableGraphics()

Instructs the server to cleanup any stored layout bitmaps.

Since
2.8

ClientError(TInt)

IMPORT_C voidClientError(TIntaErrorCode = 0)

Notifies the server that the skin client has encountered an error while doing a skin change. After this call the server falls back to the system default skin and ignores any calls to this funcion to avoid infite loop.

Since
2.0

Parameters

TInt aErrorCode = 0Error code.

Close()

IMPORT_C voidClose()

Closes the session.

Since
2.0

Connect(MAknsSkinChangeObserver *, TInt)

IMPORT_C TIntConnect(MAknsSkinChangeObserver *aObserver = NULL,
TIntaPriority = CActive::EPriorityStandard
)

Starts the server if it's not allready started and creates a new session.

Since
2.0

Parameters

MAknsSkinChangeObserver * aObserver = NULLSkin change observer.
TInt aPriority = CActive::EPriorityStandardObserver priority.

CopySkin(const TAknsPkgID, TAknSkinSrvSkinPackageLocation, TAknSkinSrvSkinPackageLocation)

IMPORT_C TIntCopySkin(const TAknsPkgIDaPID,
TAknSkinSrvSkinPackageLocationaSourceLocation,
TAknSkinSrvSkinPackageLocationaDestLocation
)

Parameters

const TAknsPkgID aPID
TAknSkinSrvSkinPackageLocation aSourceLocation
TAknSkinSrvSkinPackageLocation aDestLocation

CopySoundFile(const TDesC &, const TDesC &)

IMPORT_C TIntCopySoundFile(const TDesC &aSourceFilename,
const TDesC &aTargetFilename
)

Parameters

const TDesC & aSourceFilename
const TDesC & aTargetFilename

CreateChunkLookupL()

IMPORT_C CAknsSrvChunkLookup *CreateChunkLookupL()

Creates a chunk lookup object.

Since
2.0
Exceptions:
If construction fails, method leaves with an error code.

DecodeWallpaperImageL(const TDesC &, const TSize &, CFbsBitmap *&, CFbsBitmap *&)

IMPORT_C voidDecodeWallpaperImageL(const TDesC &aFilename,
const TSize &aTargetSize,
CFbsBitmap *&aBitmap,
CFbsBitmap *&aMask
)

Parameters

const TDesC & aFilename
const TSize & aTargetSize
CFbsBitmap *& aBitmap
CFbsBitmap *& aMask

DeleteSkin(const TAknsPkgID, TAknSkinSrvSkinPackageLocation)

IMPORT_C TIntDeleteSkin(const TAknsPkgIDaPID,
TAknSkinSrvSkinPackageLocationaLocation
)

Parameters

const TAknsPkgID aPID
TAknSkinSrvSkinPackageLocation aLocation

DisableSkinChangeNotify()

IMPORT_C voidDisableSkinChangeNotify()

Disables the servers skin change notification mechanism. After this call no notification events are generated until a subsequent EnableSkinChangeNotify() is called. The function affects all sessions.

Since
2.0

EnableSkinChangeNotify()

IMPORT_C voidEnableSkinChangeNotify()

Enables the servers skin change notifications mechanism. If the skin definitions have changed, or there are pending notification events, SkinContentChanged() is called for all sessions. The function affects all sessions.

Since
2.0

EnumerateSkinPackagesL(TAknSkinSrvSkinPackageLocation)

IMPORT_C CArrayPtr< CAknsSrvSkinInformationPkg > *EnumerateSkinPackagesL(TAknSkinSrvSkinPackageLocationaLocation = EAknsSrvPhone)

Retrieves skin information for all the available skins packages in specified location. After a call to this function, the ownewship of the array and the items in it is transferred to the caller.

Since
2.0
Exceptions:
If enumeration failed, method leaves with an error code.

Parameters

TAknSkinSrvSkinPackageLocation aLocation = EAknsSrvPhonethe location from where to look for the skin packages. Default value is phone (i.e., c and z drives).

EventHandled()

voidEventHandled()[private]

Completes event handling.

FreeUnnecessaryLayoutBitmaps(TAknsSrcScreenMode)

IMPORT_C voidFreeUnnecessaryLayoutBitmaps(TAknsSrcScreenModeaMode)

Parameters

TAknsSrcScreenMode aMode

OpenBitmapFile(const TDesC &, TInt &)

IMPORT_C TIntOpenBitmapFile(const TDesC &aFilename,
TInt &aFileHandle
)

Parameters

const TDesC & aFilename
TInt & aFileHandle

OpenImageInifile(TAknsSrvInifileType, TInt &)

IMPORT_C TIntOpenImageInifile(TAknsSrvInifileTypeaType,
TInt &aFilehandle
)

Parameters

TAknsSrvInifileType aType
TInt & aFilehandle

OpenInifile(const TAknsPkgID, TAknSkinSrvSkinPackageLocation, TInt &, TBool)

IMPORT_C TIntOpenInifile(const TAknsPkgIDaPID,
TAknSkinSrvSkinPackageLocationaLocation,
TInt &aFilehandle,
TBoolaWriteToFile
)

Parameters

const TAknsPkgID aPID
TAknSkinSrvSkinPackageLocation aLocation
TInt & aFilehandle
TBool aWriteToFile

RemoveAllWallpapers()

IMPORT_C voidRemoveAllWallpapers()

Remove all decoded wallpaper.

RemoveWallpaper(const TDesC &)

IMPORT_C voidRemoveWallpaper(const TDesC &aFilename)

Remove one decoded wallpaper.

Parameters

const TDesC & aFilenamea fully qualified path(incl. path + filename) of the wallpaper

Reserved1()

IMPORT_C TIntReserved1()[private]

Reserved for future use.

Since
2.0

Reserved2()

IMPORT_C TIntReserved2()[private]

Reserved for future use.

Since
2.0

Reserved3()

IMPORT_C TIntReserved3()[private]

Reserved for future use.

Since
2.0

Reserved4()

IMPORT_C voidReserved4()[private]

Reserved for future use.

Since
2.0

SendCancel()

voidSendCancel()[private]

Cancels send operation.

SetAllDefinitionSets(const TAknsPkgID)

IMPORT_C TIntSetAllDefinitionSets(const TAknsPkgIDaPID)

Sets all the active item definition sets (including all the classes). Item definition sets of the skin with the given package ID are activated and clients are notified about the skin change.

Since
2.0

Parameters

const TAknsPkgID aPIDPackage ID of the skin to be activated.

SetIdleWallpaper(const TDesC &)

IMPORT_C TIntSetIdleWallpaper(const TDesC &aFilename)

Sets the idle state wallpaper.

Since
2.0

Parameters

const TDesC & aFilenamea fully qualified path(incl. path + filename) to the mbm file containing the wallpaper

SetSlideSetWallpaper(const CDesCArray &)

IMPORT_C TIntSetSlideSetWallpaper(const CDesCArray &aFilenameArray)

Parameters

const CDesCArray & aFilenameArray

StoreScalableGraphics(const TAknsItemID &, const TInt, const TSize &, const CFbsBitmap *, const CFbsBitmap *, TBool)

IMPORT_C TIntStoreScalableGraphics(const TAknsItemID &aIID,
const TIntaType,
const TSize &aLayoutSize,
const CFbsBitmap *aBmp,
const CFbsBitmap *aMask,
TBoolaMorphing = EFalse
)

Stores a duplicate of the given bitmap (optionally with mask).

Since
2.8

Parameters

const TAknsItemID & aIIDItem ID used as a key.
const TInt aTypeLayout type used as a key.
const TSize & aLayoutSize
const CFbsBitmap * aBmpPointer to a bitmap. Must be non-NULL. No ownership is transferred.
const CFbsBitmap * aMaskPointer to a mask, or NULL. No ownership is transferred.
TBool aMorphing = EFalse

Version()

TVersion Version()const [private]

Gets the server version.

WallpaperImageL(const TDesC &)

IMPORT_C CFbsBitmap *WallpaperImageL(const TDesC &aFilename)

Get a decoded wallpaper.

Parameters

const TDesC & aFilename

Member Data Documentation

TAknsSrvClientMemberData * iMemberData

TAknsSrvClientMemberData *iMemberData[private]