X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/c2ca375c5620209d77a88d2d378bdcdedbc82e7e..804eeca5d59fc4d3822b719dee61a9d491e6bcfc:/include/wx/unix/private/timer.h diff --git a/include/wx/unix/private/timer.h b/include/wx/unix/private/timer.h index cdcf53b3d2..535ba7db95 100644 --- a/include/wx/unix/private/timer.h +++ b/include/wx/unix/private/timer.h @@ -11,6 +11,8 @@ #ifndef _WX_UNIX_PRIVATE_TIMER_H_ #define _WX_UNIX_PRIVATE_TIMER_H_ +#if wxUSE_TIMER + #include "wx/private/timer.h" // the type used for milliseconds is large enough for microseconds too but @@ -31,10 +33,17 @@ public: virtual bool Start(int milliseconds = -1, bool oneShot = false); virtual void Stop(); + // for wxTimerScheduler only: resets the internal flag indicating that the + // timer is running + void MarkStopped() + { + wxASSERT_MSG( m_isRunning, _T("stopping non-running timer?") ); + + m_isRunning = false; + } + private: bool m_isRunning; - - friend class wxTimerScheduler; }; // ---------------------------------------------------------------------------- @@ -128,4 +137,6 @@ private: // returns the number of microseconds since the Epoch extern wxUsecClock_t wxGetLocalTimeUsec(); +#endif // wxUSE_TIMER + #endif // _WX_UNIX_PRIVATE_TIMER_H_