JX Application Framework
|
#include <JXCursorAnimator.h>
Public Member Functions | |
JXCursorAnimator (JXWindow *window) | |
~JXCursorAnimator () | |
void | Activate () |
void | Deactivate () |
void | SetFrameSequence (const JArray< JCursorIndex > &frames) |
void | ResetFrameCounter () |
void | NextFrame () |
Static Public Attributes | |
static const JSize | kmsecPerFrame = 500 |
This class simplifies the animation of cursors. During a long process, call NextFrame() regularly, and this class will ensure that the cursor twirls smoothly. The default animation is the a beach ball. You can change this with SetFrameSequence(). We are owned by a particular JXWidget. This object must activate us when it controls the cursor, and must deactivate us otherwise. This allows an unlimited number of simultaneously animated cursors, with at most one visible at any one time. This class was not designed to be a base class.
JXCursorAnimator::JXCursorAnimator | ( | JXWindow * | window | ) |
JXCursorAnimator::~JXCursorAnimator | ( | ) |
|
inline |
|
inline |
void JXCursorAnimator::NextFrame | ( | ) |
Show the next frame of the cursor -if enough time has elapsed-.
|
inline |
Reset the counter to start the animation from the first frame.
void JXCursorAnimator::SetFrameSequence | ( | const JArray< JCursorIndex > & | frames | ) |
|
static |