aboutsummaryrefslogtreecommitdiff
path: root/graphics
diff options
context:
space:
mode:
authorMax Horn2010-11-16 08:23:13 +0000
committerMax Horn2010-11-16 08:23:13 +0000
commitabe1959d36816b6c0703c1c3802764818585d0b6 (patch)
tree01fd7fe8a0f5bbad700d052c78f954862a11dc5f /graphics
parent5af8a76b489c315f4389f888489030bdcff52ae3 (diff)
downloadscummvm-rg350-abe1959d36816b6c0703c1c3802764818585d0b6.tar.gz
scummvm-rg350-abe1959d36816b6c0703c1c3802764818585d0b6.tar.bz2
scummvm-rg350-abe1959d36816b6c0703c1c3802764818585d0b6.zip
COMMON: Simplify DECLARE_SINGLETON macro
This makes it possible to write DECLARE_SINGLETON(foo); instead of DECLARE_SINGLETON(foo) without causing a warning about an extra semicolon. The extra semicolon helps some editors at parsing the C++ code. svn-id: r54258
Diffstat (limited to 'graphics')
-rw-r--r--graphics/cursorman.cpp2
-rw-r--r--graphics/font.h4
-rw-r--r--graphics/fontman.cpp15
3 files changed, 10 insertions, 11 deletions
diff --git a/graphics/cursorman.cpp b/graphics/cursorman.cpp
index 35e771b2f4..fe90545280 100644
--- a/graphics/cursorman.cpp
+++ b/graphics/cursorman.cpp
@@ -27,7 +27,7 @@
#include "common/system.h"
#include "common/stack.h"
-DECLARE_SINGLETON(Graphics::CursorManager)
+DECLARE_SINGLETON(Graphics::CursorManager);
namespace Graphics {
diff --git a/graphics/font.h b/graphics/font.h
index 0e65e9418c..101fd6eac6 100644
--- a/graphics/font.h
+++ b/graphics/font.h
@@ -149,10 +149,10 @@ public:
#define FORWARD_DECLARE_FONT(n) \
extern const NewFont *n; \
- extern void create_##n();
+ extern void create_##n()
#define INIT_FONT(n) \
- create_##n();
+ create_##n()
} // End of namespace Graphics
diff --git a/graphics/fontman.cpp b/graphics/fontman.cpp
index c6972cfaab..35ea14b199 100644
--- a/graphics/fontman.cpp
+++ b/graphics/fontman.cpp
@@ -23,16 +23,15 @@
*/
#include "graphics/fontman.h"
-//#include "gui/consolefont.h"
-DECLARE_SINGLETON(Graphics::FontManager)
+DECLARE_SINGLETON(Graphics::FontManager);
namespace Graphics {
const ScummFont *g_scummfont = 0;
-FORWARD_DECLARE_FONT(g_sysfont)
-FORWARD_DECLARE_FONT(g_sysfont_big)
-FORWARD_DECLARE_FONT(g_consolefont)
+FORWARD_DECLARE_FONT(g_sysfont);
+FORWARD_DECLARE_FONT(g_sysfont_big);
+FORWARD_DECLARE_FONT(g_consolefont);
FontManager::FontManager() {
// This assert should *never* trigger, because
@@ -41,9 +40,9 @@ FontManager::FontManager() {
// reset to 0 in the desctructor of this class).
assert(g_scummfont == 0);
g_scummfont = new ScummFont;
- INIT_FONT(g_sysfont)
- INIT_FONT(g_sysfont_big)
- INIT_FONT(g_consolefont)
+ INIT_FONT(g_sysfont);
+ INIT_FONT(g_sysfont_big);
+ INIT_FONT(g_consolefont);
}
FontManager::~FontManager() {