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 void AddWallpaperL (const TDesC &, const TSize &)
IMPORT_C TInt CheckIconConfiguration ( TUid )
IMPORT_C TInt ClearScalableGraphics ()
IMPORT_C void ClientError ( TInt )
IMPORT_C void Close ()
IMPORT_C TInt Connect ( MAknsSkinChangeObserver *, TInt )
IMPORT_C TInt CopySkin (const TAknsPkgID , TAknSkinSrvSkinPackageLocation , TAknSkinSrvSkinPackageLocation )
IMPORT_C TInt CopySoundFile (const TDesC &, const TDesC &)
IMPORT_C CAknsSrvChunkLookup * CreateChunkLookupL ()
IMPORT_C void DecodeWallpaperImageL (const TDesC &, const TSize &, CFbsBitmap *&, CFbsBitmap *&)
IMPORT_C TInt DeleteSkin (const TAknsPkgID , TAknSkinSrvSkinPackageLocation )
IMPORT_C void DisableSkinChangeNotify ()
IMPORT_C void EnableSkinChangeNotify ()
IMPORT_C CArrayPtr < CAknsSrvSkinInformationPkg > * EnumerateSkinPackagesL ( TAknSkinSrvSkinPackageLocation )
IMPORT_C void FreeUnnecessaryLayoutBitmaps ( TAknsSrcScreenMode )
IMPORT_C TInt OpenBitmapFile (const TDesC &, TInt &)
IMPORT_C TInt OpenImageInifile ( TAknsSrvInifileType , TInt &)
IMPORT_C TInt OpenInifile (const TAknsPkgID , TAknSkinSrvSkinPackageLocation , TInt &, TBool )
IMPORT_C void RemoveAllWallpapers ()
IMPORT_C void RemoveWallpaper (const TDesC &)
IMPORT_C TInt SetAllDefinitionSets (const TAknsPkgID )
IMPORT_C TInt SetIdleWallpaper (const TDesC &)
IMPORT_C TInt SetSlideSetWallpaper (const CDesCArray &)
IMPORT_C TInt StoreScalableGraphics (const TAknsItemID &, const TInt , const TSize &, const CFbsBitmap *, const CFbsBitmap *, TBool )
IMPORT_C CFbsBitmap * WallpaperImageL (const TDesC &)
Private Member Functions
void EventHandled ()
IMPORT_C TInt Reserved1 ()
IMPORT_C TInt Reserved2 ()
IMPORT_C TInt Reserved3 ()
IMPORT_C void Reserved4 ()
void SendCancel ()
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_C RAknsSrvSession ( )

C++ default constructor.

Member Functions Documentation

AcknowledgeSkinChangeNotification()

TInt AcknowledgeSkinChangeNotification ( )

Acknowledges the skin change notification.

Since
2.7

AddWallpaperL(const TDesC &, const TSize &)

IMPORT_C void AddWallpaperL ( const TDesC & aFilename,
const TSize & aTargetSize
)

Add one wallpaper.

Parameters

const TDesC & aFilename a 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 TInt CheckIconConfiguration ( TUid aAppUid )

Parameters

TUid aAppUid

ClearScalableGraphics()

IMPORT_C TInt ClearScalableGraphics ( )

Instructs the server to cleanup any stored layout bitmaps.

Since
2.8

ClientError(TInt)

IMPORT_C void ClientError ( TInt aErrorCode = 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 = 0 Error code.

Close()

IMPORT_C void Close ( )

Closes the session.

Since
2.0

Connect(MAknsSkinChangeObserver *, TInt)

IMPORT_C TInt Connect ( MAknsSkinChangeObserver * aObserver = NULL,
TInt aPriority = CActive::EPriorityStandard
)

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

Since
2.0

Parameters

MAknsSkinChangeObserver * aObserver = NULL Skin change observer.
TInt aPriority = CActive::EPriorityStandard Observer priority.

CopySkin(const TAknsPkgID, TAknSkinSrvSkinPackageLocation, TAknSkinSrvSkinPackageLocation)

IMPORT_C TInt CopySkin ( const TAknsPkgID aPID,
TAknSkinSrvSkinPackageLocation aSourceLocation,
TAknSkinSrvSkinPackageLocation aDestLocation
)

CopySoundFile(const TDesC &, const TDesC &)

IMPORT_C TInt CopySoundFile ( 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 void DecodeWallpaperImageL ( 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 TInt DeleteSkin ( const TAknsPkgID aPID,
TAknSkinSrvSkinPackageLocation aLocation
)

Parameters

const TAknsPkgID aPID
TAknSkinSrvSkinPackageLocation aLocation

DisableSkinChangeNotify()

IMPORT_C void DisableSkinChangeNotify ( )

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 void EnableSkinChangeNotify ( )

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 ( TAknSkinSrvSkinPackageLocation aLocation = 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 = EAknsSrvPhone the location from where to look for the skin packages. Default value is phone (i.e., c and z drives).

EventHandled()

void EventHandled ( ) [private]

Completes event handling.

FreeUnnecessaryLayoutBitmaps(TAknsSrcScreenMode)

IMPORT_C void FreeUnnecessaryLayoutBitmaps ( TAknsSrcScreenMode aMode )

Parameters

TAknsSrcScreenMode aMode

OpenBitmapFile(const TDesC &, TInt &)

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

Parameters

const TDesC & aFilename
TInt & aFileHandle

OpenImageInifile(TAknsSrvInifileType, TInt &)

IMPORT_C TInt OpenImageInifile ( TAknsSrvInifileType aType,
TInt & aFilehandle
)

Parameters

TAknsSrvInifileType aType
TInt & aFilehandle

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

IMPORT_C TInt OpenInifile ( const TAknsPkgID aPID,
TAknSkinSrvSkinPackageLocation aLocation,
TInt & aFilehandle,
TBool aWriteToFile
)

Parameters

const TAknsPkgID aPID
TAknSkinSrvSkinPackageLocation aLocation
TInt & aFilehandle
TBool aWriteToFile

RemoveAllWallpapers()

IMPORT_C void RemoveAllWallpapers ( )

Remove all decoded wallpaper.

RemoveWallpaper(const TDesC &)

IMPORT_C void RemoveWallpaper ( const TDesC & aFilename )

Remove one decoded wallpaper.

Parameters

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

Reserved1()

IMPORT_C TInt Reserved1 ( ) [private]

Reserved for future use.

Since
2.0

Reserved2()

IMPORT_C TInt Reserved2 ( ) [private]

Reserved for future use.

Since
2.0

Reserved3()

IMPORT_C TInt Reserved3 ( ) [private]

Reserved for future use.

Since
2.0

Reserved4()

IMPORT_C void Reserved4 ( ) [private]

Reserved for future use.

Since
2.0

SendCancel()

void SendCancel ( ) [private]

Cancels send operation.

SetAllDefinitionSets(const TAknsPkgID)

IMPORT_C TInt SetAllDefinitionSets ( const TAknsPkgID aPID )

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 aPID Package ID of the skin to be activated.

SetIdleWallpaper(const TDesC &)

IMPORT_C TInt SetIdleWallpaper ( const TDesC & aFilename )

Sets the idle state wallpaper.

Since
2.0

Parameters

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

SetSlideSetWallpaper(const CDesCArray &)

IMPORT_C TInt SetSlideSetWallpaper ( const CDesCArray & aFilenameArray )

Parameters

const CDesCArray & aFilenameArray

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

IMPORT_C TInt StoreScalableGraphics ( const TAknsItemID & aIID,
const TInt aType,
const TSize & aLayoutSize,
const CFbsBitmap * aBmp,
const CFbsBitmap * aMask,
TBool aMorphing = EFalse
)

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

Since
2.8

Parameters

const TAknsItemID & aIID Item ID used as a key.
const TInt aType Layout type used as a key.
const TSize & aLayoutSize
const CFbsBitmap * aBmp Pointer to a bitmap. Must be non-NULL. No ownership is transferred.
const CFbsBitmap * aMask Pointer 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]