summaryrefslogtreecommitdiff
path: root/Source/Core/Common
diff options
context:
space:
mode:
authorJordan Woyak <jordan.woyak@gmail.com>2010-11-15 05:29:10 +0000
committerJordan Woyak <jordan.woyak@gmail.com>2010-11-15 05:29:10 +0000
commit73ed235fd19c4c19c3b6d56ce6d9631980487b0d (patch)
tree65ae6f7d314b3adf857fa5a8754a777e4435197d /Source/Core/Common
parentb4ffd640b7a5f66309bcf22e9008e0059f66ca98 (diff)
Changed macro for disallowing copy-ctor and =operator into an inheritable class. Removed IrPointer.ini (no longer used)
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6421 8ced0084-cf51-0410-be5f-012b33b47a6e
Diffstat (limited to 'Source/Core/Common')
-rw-r--r--Source/Core/Common/Src/Common.h14
-rw-r--r--Source/Core/Common/Src/LogManager.h3
2 files changed, 10 insertions, 7 deletions
diff --git a/Source/Core/Common/Src/Common.h b/Source/Core/Common/Src/Common.h
index 842230ed66..6cc7cf0581 100644
--- a/Source/Core/Common/Src/Common.h
+++ b/Source/Core/Common/Src/Common.h
@@ -38,11 +38,15 @@ extern const char *netplay_dolphin_ver;
#define STACKALIGN
-// A macro to disallow the copy constructor and operator= functions
-// This should be used in the private: declarations for a class
-#define DISALLOW_COPY_AND_ASSIGN(TypeName) \
- TypeName(const TypeName&); \
- void operator=(const TypeName&)
+// An inheritable class to disallow the copy constructor and operator= functions
+class NonCopyable
+{
+protected:
+ NonCopyable() {}
+private:
+ NonCopyable(const NonCopyable&);
+ void operator=(const NonCopyable&);
+};
#include "Log.h"
#include "CommonTypes.h"
diff --git a/Source/Core/Common/Src/LogManager.h b/Source/Core/Common/Src/LogManager.h
index e0157b246d..7e247925c4 100644
--- a/Source/Core/Common/Src/LogManager.h
+++ b/Source/Core/Common/Src/LogManager.h
@@ -106,7 +106,7 @@ namespace Common {
class CriticalSection;
}
-class LogManager
+class LogManager : NonCopyable
{
private:
LogContainer* m_Log[LogTypes::NUMBER_OF_LOGS];
@@ -117,7 +117,6 @@ private:
LogManager();
~LogManager();
- DISALLOW_COPY_AND_ASSIGN(LogManager);
public:
static u32 GetMaxLevel() { return MAX_LOGLEVEL; }