timer.h 1.0 KB

1234567891011121314151617181920212223242526272829303132333435
  1. /////////////////////////////////////////////////////////////////////////////
  2. // Name: wx/gtk/private/timer.h
  3. // Purpose: wxTimerImpl for wxGTK
  4. // Author: Robert Roebling
  5. // Copyright: (c) 1998 Robert Roebling
  6. // Licence: wxWindows licence
  7. /////////////////////////////////////////////////////////////////////////////
  8. #ifndef _WX_GTK_PRIVATE_TIMER_H_
  9. #define _WX_GTK_PRIVATE_TIMER_H_
  10. #if wxUSE_TIMER
  11. #include "wx/private/timer.h"
  12. //-----------------------------------------------------------------------------
  13. // wxTimer
  14. //-----------------------------------------------------------------------------
  15. class WXDLLIMPEXP_CORE wxGTKTimerImpl : public wxTimerImpl
  16. {
  17. public:
  18. wxGTKTimerImpl(wxTimer* timer) : wxTimerImpl(timer) { m_sourceId = 0; }
  19. virtual bool Start( int millisecs = -1, bool oneShot = false );
  20. virtual void Stop();
  21. virtual bool IsRunning() const { return m_sourceId != 0; }
  22. protected:
  23. int m_sourceId;
  24. };
  25. #endif // wxUSE_TIMER
  26. #endif // _WX_GTK_PRIVATE_TIMER_H_