This is IconAnimator.h in view mode; [Download] [Up]
//** Craig Laurent #import <appkit/appkit.h> #import <eointerface/eointerface.h> /* IconAnimator - an Object to animate the icon for an application. This Object will allow similiar activity to NeXTMail when new mail arrives. Pass in an array of NXImages, an array of NSNumbers indicating the pattern, and the number of loops through the pattern to execute. The time interval between image changes, and the stopAnimation icon can be set after initialization. imageArray - an array of NXImages to be placed in the icon one at a time. animationPattern - an array of NSNumbers. Each number indicates which image number (objectAt:) should be displayed. The order of the numbers will reflect the pattern of the animation. patternLoops - the number of times that the animationPattern will be looped through. timeInterval - the time interval between image changes. Defaults to 0.2 seconds. See setTimeInterval: method. indexOfEndIcon - the index of the icon to be displayed at the end of the animation cycle. Defaults to 1. See setIndexOfEndIcon: method. indexOfStopIcon - the index of the icon to be displayed after stopAnimation:. Defaults to 0. See setIndexOfStopIcon: method. */ @interface IconAnimator:NSObject { NXImage *appTile; View *appIconContentView; NSMutableArray *animationPattern; NSMutableArray *imageArray; int patternLoops; float timeInterval; int indexOfEndIcon; int indexOfStopIcon; DPSTimedEntry timedEntry; int patternIterator; int loopCount; int patternEnd; int offset; } void Animate (DPSTimedEntry timedEntry, double now, void *who); - init; - initWithImageArray:(NSArray*)anArray animationPattern:(NSArray*)patternArray andPatternLoops:(int)loops; //designated initializer - (void)dealloc; //** instance methods - (NSArray*)imageArray; - (void)setImageArray:(NSArray*)anArray; - (NSArray*)animationPattern; - (void)setAnimationPattern:(NSArray*)anArray; - (int)patternLoops; - (void)setPatternLoops:(int)numLoops; - (float)timeInterval; - (void)setTimeInterval:(float)interval; - (int)indexOfEndIcon; - (void)setIndexOfEndIcon:(int)endIcon; - (int)indexOfStopIcon; - (void)setIndexOfStopIcon:(int)stopIcon; //** methods to change Animation - (void)startAnimation:sender; - (void)stopAnimation; //** Internal methods - (void)removeTimedEntry; - (NXPoint)cornerPointForImage:(NXImage*)anImage; - (void)displayImage:(NXImage*)anImage; - (void)animateIcon; @end
These are the contents of the former NiCE NeXT User Group NeXTSTEP/OpenStep software archive, currently hosted by Netfuture.ch.