summaryrefslogtreecommitdiff
path: root/src/company_type.h
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2010-05-13 09:44:44 +0000
committerrubidium <rubidium@openttd.org>2010-05-13 09:44:44 +0000
commit398418b8fa23ab59f5fc027a7dd6aeba9da4d7bb (patch)
tree54de30f4702263ee1489af162d6da840e35c0a87 /src/company_type.h
parent793b0f0736ac543fb1f6a7e9a4bfd678891e7374 (diff)
downloadopenttd-398418b8fa23ab59f5fc027a7dd6aeba9da4d7bb.tar.xz
(svn r19812) -Codechange: give some unnamed enums a name or, in case they consisted of unrelated values use static const (u)int
Diffstat (limited to 'src/company_type.h')
-rw-r--r--src/company_type.h14
1 files changed, 5 insertions, 9 deletions
diff --git a/src/company_type.h b/src/company_type.h
index a40a16ac0..77d73ed1f 100644
--- a/src/company_type.h
+++ b/src/company_type.h
@@ -37,16 +37,12 @@ enum Owner {
};
DECLARE_POSTFIX_INCREMENT(Owner)
-enum {
- MAX_LENGTH_PRESIDENT_NAME_BYTES = 31, ///< The maximum length of a president name in bytes including '\0'
- MAX_LENGTH_PRESIDENT_NAME_PIXELS = 94, ///< The maximum length of a president name in pixels
- MAX_LENGTH_COMPANY_NAME_BYTES = 31, ///< The maximum length of a company name in bytes including '\0'
- MAX_LENGTH_COMPANY_NAME_PIXELS = 150, ///< The maximum length of a company name in pixels
-};
+static const uint MAX_LENGTH_PRESIDENT_NAME_BYTES = 31; ///< The maximum length of a president name in bytes including '\0'
+static const uint MAX_LENGTH_PRESIDENT_NAME_PIXELS = 94; ///< The maximum length of a president name in pixels
+static const uint MAX_LENGTH_COMPANY_NAME_BYTES = 31; ///< The maximum length of a company name in bytes including '\0'
+static const uint MAX_LENGTH_COMPANY_NAME_PIXELS = 150; ///< The maximum length of a company name in pixels
-enum {
- MAX_HISTORY_MONTHS = 24, ///< The maximum number of months kept as performance's history
-};
+static const uint MAX_HISTORY_MONTHS = 24; ///< The maximum number of months kept as performance's history
/** Define basic enum properties */
template <> struct EnumPropsT<Owner> : MakeEnumPropsT<Owner, byte, OWNER_BEGIN, OWNER_END, INVALID_OWNER> {};