home *** CD-ROM | disk | FTP | other *** search
/ MacHack 2000 / MacHack 2000.toast / pc / The Hacks / Genie / Projects / AEA / Source / Sources / AEA1AEIdleFunction.cc
Encoding:
C/C++ Source or Header  |  2000-06-24  |  772 b   |  39 lines

  1. /*    =====================
  2.  *    AEA1AEIdleFunction.cc
  3.  *    =====================
  4.  */
  5.  
  6. #include <AppleEvents.h>
  7.  
  8. #include "AEADebugging.h"
  9.  
  10. #include "AEA1AEIdleFunction.hh"
  11.  
  12. AEA1AEIdleFunction::AEA1AEIdleFunction(AEAApplication &inApp)
  13. : mAEIdleUPP(NewAEIdleProc(AEIdleFunction)), mApp(inApp)
  14. {
  15.     //mAEIdleUPP = NewAEIdleProc(AEIdleFunction);
  16. }
  17.  
  18. AEA1AEIdleFunction::~AEA1AEIdleFunction()
  19. {
  20. }
  21.  
  22. /*    
  23.  *    AESend() idle function
  24.  *    
  25.  *    Return whether or not you're tired of waiting.
  26.  */
  27.  
  28. pascal Boolean
  29. AEA1AEIdleFunction::AEIdleFunction(EventRecord *inEvent, long *outSleepTime, RgnHandle *outMouseRgn)
  30. {
  31. // This hack allows us to tap PowerPlant's event loop.
  32. // Later it will be revised for Standard App.
  33. #ifdef _H_LApplication
  34.     mApp.DispatchEvent(*inEvent);
  35. #endif
  36.     return false;
  37. }
  38.  
  39.