diff options
author | rubidium <rubidium@openttd.org> | 2010-05-13 10:14:29 +0000 |
---|---|---|
committer | rubidium <rubidium@openttd.org> | 2010-05-13 10:14:29 +0000 |
commit | 062dd0e24c283f210216ede06bbde0ed72c7ed25 (patch) | |
tree | a917e975f1f5d4c144ecad2c799cf58764a1f592 /src/train_gui.cpp | |
parent | a2d6961ab3c9aa43b95dfe9fa4699d290e5627e2 (diff) | |
download | openttd-062dd0e24c283f210216ede06bbde0ed72c7ed25.tar.xz |
(svn r19814) -Codechange: give some more unnamed enums a name, in case they consisted of unrelated values use static const (u)int
Diffstat (limited to 'src/train_gui.cpp')
-rw-r--r-- | src/train_gui.cpp | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/train_gui.cpp b/src/train_gui.cpp index 16291af14..bbd6841dc 100644 --- a/src/train_gui.cpp +++ b/src/train_gui.cpp @@ -126,10 +126,8 @@ struct CargoSummaryItem { } }; -enum { - TRAIN_DETAILS_MIN_INDENT = 32, ///< Minimum indent level in the train details window - TRAIN_DETAILS_MAX_INDENT = 72, ///< Maximum indent level in the train details window; wider than this and we start on a new line -}; +static const uint TRAIN_DETAILS_MIN_INDENT = 32; ///< Minimum indent level in the train details window +static const uint TRAIN_DETAILS_MAX_INDENT = 72; ///< Maximum indent level in the train details window; wider than this and we start on a new line /** Container for the cargo summary information. */ typedef SmallVector<CargoSummaryItem, 2> CargoSummary; @@ -307,7 +305,7 @@ void DrawTrainDetails(const Train *v, int left, int right, int y, int vscroll_po GetCargoSummaryOfArticulatedVehicle(v, &_cargo_summary); /* Draw sprites */ - int dx = 0; + uint dx = 0; int px = x; const Train *u = v; do { |