home *** CD-ROM | disk | FTP | other *** search
/ Nebula 2 / Nebula Two.iso / Apps / ScreenSavers / BackSpaceViews / AnalogClockView.BackModule / AnalogClockView.h < prev    next >
Encoding:
Text File  |  1995-06-12  |  1.0 KB  |  36 lines

  1. //
  2. // AnalogClock
  3. //
  4. // Module for BackSpace.app
  5. // 7 Nov 91
  6. // Matt Pharr- pharr@cs.yale.edu
  7. //
  8.  
  9. #import <appkit/View.h>
  10. #import "Thinker.h"
  11.  
  12. #define CLOCK_WIDTH 256
  13. #define CLOCK_HEIGHT 256
  14.  
  15. @interface AnalogClockView:View
  16. {
  17.   NXPoint currentLocation;     // current location of the bitmap
  18.   NXPoint moveVector;          // not a point, but a vector that describes how
  19.                                // the bitmap is moving...
  20.   int hours;
  21.   int mins;
  22.   int secs;
  23.   int hasColor;                // 0 if a monochome machine, else 1
  24.   NXSize currentSize;          // the size of the bitmap
  25.   id currentImage;             // the bitmap itself that holds the drawing of 
  26.                                // the time
  27.   id hourMinuteImage;          // bitmap of the clock minus the second hand, so
  28.                                // we only have to draw the whole clock once a
  29.                                // minute, as opposed to once a second, as before
  30. }
  31.  
  32. -oneStep;
  33. -drawSelf:(const NXRect *)rects :(int)rectCount;
  34. -initFrame:(const NXRect *)frameRect;
  35. @end
  36.