mirror of
https://github.com/isledecomp/isle.git
synced 2026-01-21 15:21:15 +00:00
This way, when preprocessing, only the relevant windows API structures will be generated.
25 lines
450 B
C++
25 lines
450 B
C++
#ifndef MXCRITICALSECTION_H
|
|
#define MXCRITICALSECTION_H
|
|
|
|
#ifndef WIN32_LEAN_AND_MEAN
|
|
#define WIN32_LEAN_AND_MEAN
|
|
#endif
|
|
|
|
#include <windows.h>
|
|
|
|
class MxCriticalSection
|
|
{
|
|
public:
|
|
__declspec(dllexport) MxCriticalSection();
|
|
__declspec(dllexport) ~MxCriticalSection();
|
|
__declspec(dllexport) static void SetDoMutex();
|
|
void Enter();
|
|
void Leave();
|
|
|
|
private:
|
|
CRITICAL_SECTION m_criticalSection;
|
|
HANDLE m_mutex;
|
|
};
|
|
|
|
#endif // MXCRITICALSECTION_H
|