Skip to content

Commit 0016360

Browse files
committed
Opps, forgot to add files into the commit
1 parent 18e998d commit 0016360

File tree

3 files changed

+27
-27
lines changed

3 files changed

+27
-27
lines changed

src/xrCore/Threading/ScopeLock.cpp

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
#include "stdafx.h"
2+
#include "ScopeLock.hpp"
3+
#include "Threading/Lock.hpp"
4+
#include "xrDebug.h"
5+
6+
ScopeLock::ScopeLock(Lock* SyncObject) : syncObject(SyncObject)
7+
{
8+
R_ASSERT(syncObject);
9+
syncObject->Enter();
10+
}
11+
12+
ScopeLock::~ScopeLock()
13+
{
14+
syncObject->Leave();
15+
}

src/xrCore/Threading/ScopeLock.h

Lines changed: 0 additions & 27 deletions
This file was deleted.

src/xrCore/Threading/ScopeLock.hpp

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
#pragma once
2+
3+
#include "Common/Noncopyable.hpp"
4+
5+
class XRCORE_API ScopeLock : Noncopyable
6+
{
7+
Lock* syncObject;
8+
9+
public:
10+
ScopeLock(Lock* SyncObject);
11+
~ScopeLock();
12+
};

0 commit comments

Comments
 (0)