X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/d254213eb2b973e826ed3bc84bc681a819eae091..aeab14d443572bdec6eef20def591d339e35df1e:/src/unix/threadpsx.cpp?ds=sidebyside diff --git a/src/unix/threadpsx.cpp b/src/unix/threadpsx.cpp index 8e7d9bba9f..2274d96da2 100644 --- a/src/unix/threadpsx.cpp +++ b/src/unix/threadpsx.cpp @@ -67,6 +67,16 @@ #define THR_ID(thr) ((long)(thr)->GetId()) #endif +#ifdef __WXMAC__ + + // implement wxCriticalSection using mutexes +wxCriticalSection::wxCriticalSection() { } +wxCriticalSection::~wxCriticalSection() { } + +void wxCriticalSection::Enter() { (void)m_mutex.Lock(); } +void wxCriticalSection::Leave() { (void)m_mutex.Unlock(); } + +#endif // ---------------------------------------------------------------------------- // constants // ---------------------------------------------------------------------------- @@ -1050,11 +1060,6 @@ void wxThread::Yield() #endif } -void wxThread::Sleep(unsigned long milliseconds) -{ - wxMilliSleep(milliseconds); -} - int wxThread::GetCPUCount() { #if defined(_SC_NPROCESSORS_ONLN)