RBitmapAnim Class Reference

#include <mw/bmpancli.h>

Link against: bmpanim.lib

class RBitmapAnim : public RAnim

Inherits from

Detailed Description

Enables a client to package animation data, and send it to the window server for display.

Before using RBitmapAnim, a client must instantiate an RAnimDll. This provides a reference to the window server DLL that runs the animation specified through the RBitmapAnim() object. To complete construction, call ConstructL().

Constructor & Destructor Documentation

RBitmapAnim ( RAnimDll & )

IMPORT_CRBitmapAnim(RAnimDll &aAnimDll)

class RBitmapAnim Constructor.

aAnimDllA reference to the DLL that runs the animation

Member Function Documentation

ConstructL ( const RWindowBase & )

IMPORT_C voidConstructL(const RWindowBase &aWindow)

Completes construction of an animation object.

This must be done after calling RBitmapAnim(), and before an application attempts any other communication with the server.

aWindowA reference to the container control window that will hold the animation.

DisplayFrameL ( TInt )

IMPORT_C voidDisplayFrameL(TIntaIndex)

Sets the animation frame to display.

How it appears depends on whether the animation is already running. If the animation is running, the animation jumps to the specified frame, then continues playing. If the animation is not running, the animation is played, starting with the specified frame

aIndexThe frame to display.

SetBitmapAnimDataL ( const CBitmapAnimClientData & )

IMPORT_C voidSetBitmapAnimDataL(const CBitmapAnimClientData &aBitmapAnimData)

Specifies the animation object to play and sends it to the animation server.

To start the animation, you must subsequently call StartL(). Calling this method while an animation is running will stop the animation.

aBitmapAnimDataThe animation object to play

SetFlashL ( TBool )

IMPORT_C voidSetFlashL(TBoolaFlash)

Sets or unsets the animation to be drawn flashing.

aFlashETrue to draw the animation flashing, otherwise EFalse.

SetFrameIntervalL ( TInt )

IMPORT_C voidSetFrameIntervalL(TIntaFrameIntervalInMilliSeconds)

Specifies the number of milliseconds for which each frame in the animation is displayed.

This is not used for any frames in the animation that specify their own interval.

aFrameIntervalInMilliSecondsThe number of milliseconds for which each frame in the animation is displayed

SetNumberOfCyclesL ( TInt )

IMPORT_C voidSetNumberOfCyclesL(TIntaNumberOfCycles)

Sets how many times the animation is played.

If the play mode is CBitmapAnimClientData::EBounce, the number of cycles must be at least two to ensure a complete animation routine is played.

aNumberOfCyclesThe number of times to play the animation.

SetPlayModeL ( CBitmapAnimClientData::TPlayMode )

IMPORT_C voidSetPlayModeL(CBitmapAnimClientData::TPlayModeaPlayMode)

Sets the current animation's play mode.

aPlayModeThe animation's play mode.

SetPositionL ( TPoint )

IMPORT_C voidSetPositionL(TPointaPosition)

Sets the animation's position relative to the animation window.

aPositionThe animation's position relative to the animation window

StartL ( )

IMPORT_C voidStartL()

Starts the animation.

You must first specify an animation with SetBitmapAnimDataL().

If you have specified CBitmapAnimClientData::ECycle or CBitmapAnimClientData::EBounce as the animation's play mode, but have not specified the number of cycles using SetNumberOfCyclesL(), you must call StopL() to stop the animation.

StopL ( )

IMPORT_C voidStopL()

Stops the animation.