[Home] [Prev] [Next] [Up]
InitCursorAnimation
WaitCursor
NormalCursor
Simplified animated cursor support
Usage:
#include <XCursorUtil.h>
void InitCursorAnimation(short *alist);
void WaitCursor(void);
void NormalCursor(void);
Description
These utilities provide a simplified way of putting up an animated cursor sequence, and step through that sequence during a long computation.
InitCursorAnimation initializes the sequence to use. The argument is an array of resource indexes (similar to those passed to SetCursorID), terminated by '0'.
WaitCursor either converts the displayed cursor to the first cursor in the sequence specified, or (if already called before), steps to the next cursor in the sequence. If InitCursorAnimation has not been called, this puts up a watch cursor. You should call the WaitCursor periodically during a long computation.
NormalCursor puts up the cursor that was up before WaitCursor was originally called. This is called after the long computation is over.