home *** CD-ROM | disk | FTP | other *** search
/ Geek 6 / Geek-006.iso / linux / video / xmovie-1.5.3.tar.gz / xmovie-1.5.3.tar / xmovie-1.5.3 / guicast / bcrepeater.h < prev    next >
C/C++ Source or Header  |  2000-11-29  |  646b  |  39 lines

  1. #ifndef BCREPEATER_H
  2. #define BCREPEATER_H
  3.  
  4. #include "bcrepeater.inc"
  5. #include "bcwindowbase.inc"
  6. #include "mutex.h"
  7. #include "thread.h"
  8. #include "timer.h"
  9.  
  10. class BC_Repeater : public Thread
  11. {
  12. public:
  13.     BC_Repeater(BC_WindowBase *top_level, long delay);
  14.     ~BC_Repeater();
  15.  
  16.     int start_repeating();
  17.     int stop_repeating();
  18.     void run();
  19.  
  20.     long repeat_id;
  21.     long delay;
  22.     int repeating;
  23.     int interrupted;
  24. // Prevent new signal until existing event is processed
  25.     Mutex repeat_lock;
  26.  
  27. private:
  28.     Timer timer;
  29.     BC_WindowBase *top_level;
  30. // Delay corrected for the time the last repeat took
  31.     long next_delay;
  32.     Mutex pause_lock;
  33.     Mutex startup_lock;
  34. };
  35.  
  36.  
  37.  
  38. #endif
  39.