diff options
author | glx <glx@openttd.org> | 2019-12-14 17:22:38 +0100 |
---|---|---|
committer | Niels Martin Hansen <nielsm@indvikleren.dk> | 2019-12-21 20:13:03 +0100 |
commit | 3a14cea068d130e11b5d9dde11d4451dd7dec453 (patch) | |
tree | 7afd5a1160872aeba8a630c2915a8168cbc483dd /src/town_gui.cpp | |
parent | 68f22134cb35267d6fa01134a385d3854fda1787 (diff) | |
download | openttd-3a14cea068d130e11b5d9dde11d4451dd7dec453.tar.xz |
Codechange: Replace FOR_ALL_COMPANIES with range-based for loops
Diffstat (limited to 'src/town_gui.cpp')
-rw-r--r-- | src/town_gui.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/town_gui.cpp b/src/town_gui.cpp index a0f04314d..2f5a72a36 100644 --- a/src/town_gui.cpp +++ b/src/town_gui.cpp @@ -149,8 +149,7 @@ public: uint exclusive_left = rtl ? right - icon_width - exclusive_width - 2 : left + icon_width + 2; /* Draw list of companies */ - const Company *c; - FOR_ALL_COMPANIES(c) { + for (const Company *c : Company::Iterate()) { if ((HasBit(this->town->have_ratings, c->index) || this->town->exclusivity == c->index)) { DrawCompanyIcon(c->index, icon_left, y + icon_y_offset); |