From cb50b454e7e734309f6c6aee3e58b2a5a743c3bf Mon Sep 17 00:00:00 2001 From: Max Horn Date: Sat, 3 Jun 2006 15:01:37 +0000 Subject: Use full path in #include guard, to avoid name clashes; also, to declare constants, enum is preferred over #define (causes less hard-to-debug errors) svn-id: r22885 --- gui/Actions.h | 11 +++++++---- gui/Key.h | 4 ++-- 2 files changed, 9 insertions(+), 6 deletions(-) (limited to 'gui') diff --git a/gui/Actions.h b/gui/Actions.h index 3e9bd4d8f8..5f90a2f864 100644 --- a/gui/Actions.h +++ b/gui/Actions.h @@ -20,16 +20,15 @@ * */ -#ifndef ACTIONS_H -#define ACTIONS_H +#ifndef GUI_ACTIONS_H +#define GUI_ACTIONS_H #include "common/stdafx.h" #include "common/scummsys.h" #include "common/system.h" #include "gui/Key.h" -namespace GUI { -#define MAX_ACTIONS 20 +namespace GUI { typedef int ActionType; @@ -69,6 +68,10 @@ protected: Actions(); protected: + enum { + MAX_ACTIONS = 20 + }; + static Actions* _instance; OSystem *_mainSystem; Key _key_action[MAX_ACTIONS + 1]; diff --git a/gui/Key.h b/gui/Key.h index 0dafa96849..4a1891f550 100644 --- a/gui/Key.h +++ b/gui/Key.h @@ -20,8 +20,8 @@ * */ -#ifndef KEY_H -#define KEY_H +#ifndef GUI_KEY_H +#define GUI_KEY_H #include "common/stdafx.h" #include "common/scummsys.h" -- cgit v1.2.3