From 6c9ef6af1b72b74b9ab94cc1c1349c3cd70c8be6 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Wed, 6 May 2015 23:13:00 +0300 Subject: Add strong types bool type UseResman. --- src/enums/simpletypes.h | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) (limited to 'src/enums') diff --git a/src/enums/simpletypes.h b/src/enums/simpletypes.h index 652ddf630..217028f56 100644 --- a/src/enums/simpletypes.h +++ b/src/enums/simpletypes.h @@ -28,13 +28,13 @@ #define defBoolEnum(name) \ enum class name : bool \ { \ - False = false, \ - True = true \ + MFalse = false, \ + MTrue = true \ }; \ - const name name##_true = name::True; \ - const name name##_false = name::False + const name name##_true = name::MTrue; \ + const name name##_false = name::MFalse #define fromBool(val, name) \ - (val) ? name::True : name::False + (val) ? name::MTrue : name::MFalse #else // ADVGCC @@ -47,6 +47,7 @@ #endif // ADVGCC + defBoolEnum(Identified); defBoolEnum(Damaged); defBoolEnum(Favorite); @@ -64,5 +65,6 @@ defBoolEnum(AllowSort); defBoolEnum(NpcNames); defBoolEnum(Enable); defBoolEnum(ForceDisplay); +defBoolEnum(UseResman); #endif // ENUMS_SIMPLETYPES_H -- cgit v1.2.3-70-g09d2