(svn r19812) -Codechange: give some unnamed enums a name or, in case they consisted of unrelated values use static const (u)int

This commit is contained in:
rubidium
2010-05-13 09:44:44 +00:00
parent 793b0f0736
commit 398418b8fa
52 changed files with 170 additions and 251 deletions

View File

@@ -58,12 +58,10 @@ struct TileIndexDiffC {
};
/** Minimal and maximal map width and height */
enum {
MIN_MAP_SIZE_BITS = 6, ///< Minimal size of map is equal to 2 ^ MIN_MAP_SIZE_BITS
MAX_MAP_SIZE_BITS = 11, ///< Maximal size of map is equal to 2 ^ MAX_MAP_SIZE_BITS
MIN_MAP_SIZE = 1 << MIN_MAP_SIZE_BITS, ///< Minimal map size = 64
MAX_MAP_SIZE = 1 << MAX_MAP_SIZE_BITS, ///< Maximal map size = 2048
};
static const uint MIN_MAP_SIZE_BITS = 6; ///< Minimal size of map is equal to 2 ^ MIN_MAP_SIZE_BITS
static const uint MAX_MAP_SIZE_BITS = 11; ///< Maximal size of map is equal to 2 ^ MAX_MAP_SIZE_BITS
static const uint MIN_MAP_SIZE = 1 << MIN_MAP_SIZE_BITS; ///< Minimal map size = 64
static const uint MAX_MAP_SIZE = 1 << MAX_MAP_SIZE_BITS; ///< Maximal map size = 2048
/**
* Approximation of the length of a straight track, relative to a diagonal