home *** CD-ROM | disk | FTP | other *** search
/ Big Green CD 8 / BGCD_8_Dev.iso / NEXTSTEP / Examples / InfoWow-0.00-MIHS / src / AnimatedView.m < prev    next >
Encoding:
Text File  |  1993-12-07  |  632 b   |  47 lines

  1.  
  2. #import "AnimatedView.h"
  3. #import "Animator.h"
  4.  
  5. @implementation AnimatedView
  6.  
  7. - initFrame:(const NXRect *)frm                // initialize instance
  8. {
  9.     [super initFrame:frm];
  10.     [self allocateGState];
  11.     animator = [[Animator alloc] initChronon:0.05 adaptation:0.0 target:self
  12.             action:@selector(autoUpdate:) autoStart:NO eventMask:0];
  13.     return self;
  14. }
  15.  
  16. - autoUpdate:sender
  17. {
  18.     return self;
  19. }
  20.  
  21. - start:sender
  22. {
  23.     [animator startEntry];
  24.     return self;
  25. }
  26.  
  27. - stop:sender
  28. {
  29.     [animator stopEntry];
  30.     return self;
  31. }
  32.  
  33. - windowWillClose:sender
  34. {
  35.     [self stop:self];
  36.     return self;
  37. }
  38.  
  39. - free
  40. {
  41.     [[animator stopEntry] free];
  42.     return [super free];
  43. }
  44.  
  45.  
  46. @end
  47.