Location:
W32ADLL.H
class MAnimGeneralFunctions;
General animation utility functions interface.
The interface provides functions to set the animation timing, event functions, and other general functions.
You do not have to create an object of this type. The class is implemented by the window server and provides utility functions
to all CAnim-derived classes via the CAnim::iFunctions
pointer.
It is not intended for user derivation.
Defined in MAnimGeneralFunctions
:
Animate()
, Client()
, CloseFont()
, DuplicateBitmapL()
, DuplicateFontL()
, EEventExtentionInterface
, EInterfaceCount
, ENumberOfExtendedInterfaces
, ESyncDay
, ESyncFlash
, ESyncMinute
, ESyncNone
, ESyncSecond
, EWindowExtensionInterface
, EventExtension()
, ExtendedInterface()
, FlashStateOn()
, GetRawEvents()
, Message()
, NumberOfExtendedInterfaces()
, Panic()
, PostKeyEvent()
, PostRawEvent()
, RegisterForNotifications()
, ReplyBuf()
, ReplyBuf()
, Reserved1()
, Reserved2()
, Reserved3()
, ScreenDevice()
, SetInterval()
, SetNextInterval()
, SetSync()
, Sync()
, SystemTime()
, TAnimSync
, WindowExtension()
, anonymous
virtual void Animate(TDateTime *aDateTime)=0;
Calls the DLL's Animate()
function then deactivates the graphics context.
This allows users to do drawing from their own active object.
Note:
If the user calls the CAnim-derived classes' Animate()
function directly, or otherwise does drawing from their own active object, then this will not deactivate the graphics context.
This causes the window server to panic the client.
Alternatively, use CFreeTimerWindowAnim
, which allows you to deactivate the graphics context yourself.
|
virtual void SetSync(TAnimSync aSyncMode)=0;
Sets the synchronisation mode.
This determines the time intervals between calls to the Animate()
function.
|
virtual void SetInterval(TInt aInterval)=0;
Sets the repeat interval.
If the synchronisation mode is TAnimSync::ESyncNone, then the Animate()
function is called at intervals defined by some number of flash ticks. There are two flash ticks a second, with a 7/12 second
- 5/12 second cycle. If the function is called when the synchronisation mode is not TAnimSync::ESyncNone, then the window
server panics the client.
If the new interval is greater than the current countdown, then the call does not affect the current countdown. For example, if the countdown has 10 flash ticks remaining, and the interval is set to 20, the new interval does not apply until the current countdown is complete.
However if the new interval is less the current countdown, then the new interval applies immediately i.e. the countdown is reset to the interval value.
If the interval is set to zero the countdown stops, and the Animate()
function is no longer called.
|
virtual void SetNextInterval(TInt aInterval)=0;
Sets the next interval.
This function immediately resets the current countdown to the specified number of flash ticks, irrespective of its current value. After the countdown expires, the interval returns to its usual rate. Note that this may be zero (i.e. not at all).
To call this function, the synchronisation mode must be TAnimSync::ESyncNone, otherwise the window server panics the client.
Note: there are two flash ticks a second, with a 7/12 second - 5/12 second cycle.
|
virtual TDateTime SystemTime() const=0;
Gets the system time as it was when Animate()
was last called.
|
virtual TBool FlashStateOn() const=0;
Tests the flash cycle state.
The flash cycle has 2 states: on (7/12 second) or off (5/12 second).
|
virtual TAnimSync Sync() const=0;
Gets the current synchronisation mode.
|
virtual const CFbsScreenDevice *ScreenDevice()=0;
Gets a pointer to the screen device.
For example, this might be used to gain access to twips to pixel conversion functions.
|
virtual CFbsBitmap *DuplicateBitmapL(TInt aHandle)=0;
Creates and duplicates a bitmap from a handle.
This function might be used to duplicate client side bitmaps on the server side.
|
|
virtual CFbsFont *DuplicateFontL(TInt aHandle)=0;
Creates and duplicates a font from a handle.
This function might be used to duplicate client side fonts on the server side.
|
|
virtual void CloseFont(CFbsFont *)=0;
Closes a duplicate font.
|
virtual const RThread &Client()=0;
Gets a reference to the calling client's thread.
|
virtual void Panic() const=0;
Panics the client.
This will result in the client thread being destroyed.
virtual void GetRawEvents(TBool aGetEvents) const=0;
Switches animation raw event handling on and off.
If raw event handling is switched on, then raw events, e.g. pointer, key, or power events are all offered to the animation
event handling code's MEventHandler::OfferRawEvent()
.
|
virtual void PostRawEvent(const TRawEvent &aRawEvent) const=0;
Posts a raw event, just as if it had come from the kernel.
|
virtual void PostKeyEvent(const TKeyEvent &aRawEvent) const=0;
Posts a key event.
The function is similar to PostRawEvent()
but should be used for posting key events.
|
virtual const RMessagePtr2 *Message()=0;
Get the address of an object which can retrieve information from and send information to the client-side.
|
virtual TAny *ExtendedInterface(TInt aInterface)=0;
Returns an extension interface, maybe extended further in the future.
|
|
virtual TInt RegisterForNotifications(TUint32 aNotifications)=0;
Register to receive notifications.
|
|
inline MAnimGeneralFunctionsWindowExtension *WindowExtension();
Gets access to Window Extension utility functions.
|
inline MAnimGeneralFunctionsEventExtension *EventExtension();
Gets access to EventExtension utility functions.
|
TAnimSync
Animation synchronisation flags.
The animation can be synchronised to any of these values; the Animate()
call will take place at the start of the new unit (day, hour, etc...).
|