X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/38d377e230b31d00d375f8e48cd8e7d536862855..5c7b506103cfc078a821860766e31c47d595e07f:/src/mac/carbon/thread.cpp?ds=sidebyside diff --git a/src/mac/carbon/thread.cpp b/src/mac/carbon/thread.cpp index cacf2e5e35..04383b0f94 100644 --- a/src/mac/carbon/thread.cpp +++ b/src/mac/carbon/thread.cpp @@ -25,19 +25,8 @@ #include "wx/thread.h" -#ifdef __WXMAC__ -#ifdef __DARWIN__ - #include -#else - #include - #include -#endif - +#include #include "wx/mac/uma.h" -#endif - -#include "wx/mac/macnotfy.h" - // the possible states of the thread: // ("=>" shows all possible transitions from this state) @@ -136,15 +125,9 @@ void wxCriticalSection::Leave() // wxMutex implementation // ---------------------------------------------------------------------------- -#if TARGET_API_MAC_OSX #define wxUSE_MAC_SEMAPHORE_MUTEX 0 #define wxUSE_MAC_CRITICAL_REGION_MUTEX 1 #define wxUSE_MAC_PTHREADS_MUTEX 0 -#else -#define wxUSE_MAC_SEMAPHORE_MUTEX 0 -#define wxUSE_MAC_CRITICAL_REGION_MUTEX 1 -#define wxUSE_MAC_PTHREADS_MUTEX 0 -#endif #if wxUSE_MAC_PTHREADS_MUTEX @@ -430,7 +413,7 @@ private: bool m_isOk ; }; -wxMutexInternal::wxMutexInternal( wxMutexType mutexType ) +wxMutexInternal::wxMutexInternal( wxMutexType WXUNUSED(mutexType) ) { m_isOk = false; m_critRegion = kInvalidID; @@ -1255,9 +1238,7 @@ bool wxThread::IsMain() void wxThread::Yield() { -#if TARGET_API_MAC_OSX CFRunLoopRunInMode( kCFRunLoopDefaultMode , 0 , true ) ; -#endif MPYield(); } @@ -1278,7 +1259,7 @@ unsigned long wxThread::GetCurrentId() return (unsigned long)MPCurrentTaskID(); } -bool wxThread::SetConcurrency( size_t level ) +bool wxThread::SetConcurrency( size_t WXUNUSED(level) ) { // Cannot be set in MacOS. return false; @@ -1698,7 +1679,7 @@ void wxThreadModule::OnExit() // GUI Serialization copied from MSW implementation // ---------------------------------------------------------------------------- -void WXDLLIMPEXP_BASE wxMutexGuiEnter() +void wxMutexGuiEnterImpl() { // this would dead lock everything... wxASSERT_MSG( !wxThread::IsMain(), @@ -1720,7 +1701,7 @@ void WXDLLIMPEXP_BASE wxMutexGuiEnter() gs_critsectGui->Enter(); } -void WXDLLIMPEXP_BASE wxMutexGuiLeave() +void wxMutexGuiLeaveImpl() { wxCriticalSectionLocker enter(*gs_critsectWaitingForGui);