diff options
author | stormcone <48624099+stormcone@users.noreply.github.com> | 2020-07-02 12:35:28 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-07-02 12:35:28 +0200 |
commit | 816fada2b18140b579e6b1d46740f46e2daeae83 (patch) | |
tree | c798974a7c19e4a97c4bcfcd35ef369990310355 /src | |
parent | 94d5fcab4bd61183bf735e317423d90179ba8035 (diff) | |
download | openttd-816fada2b18140b579e6b1d46740f46e2daeae83.tar.xz |
Fix #8250: [NRT] Company infrastructure window always omits last road/tramtype
Diffstat (limited to 'src')
-rw-r--r-- | src/company_gui.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/company_gui.cpp b/src/company_gui.cpp index f4fe7f803..dd8a17ce0 100644 --- a/src/company_gui.cpp +++ b/src/company_gui.cpp @@ -1882,7 +1882,7 @@ struct CompanyInfrastructureWindow : Window switch (widget) { case WID_CI_RAIL_DESC: { - uint lines = 1; + uint lines = 1; // Starts at 1 because a line is also required for the section title size->width = max(size->width, GetStringBoundingBox(STR_COMPANY_INFRASTRUCTURE_VIEW_RAIL_SECT).width); @@ -1905,7 +1905,7 @@ struct CompanyInfrastructureWindow : Window case WID_CI_ROAD_DESC: case WID_CI_TRAM_DESC: { - uint lines = 0; + uint lines = 1; // Starts at 1 because a line is also required for the section title size->width = max(size->width, GetStringBoundingBox(widget == WID_CI_ROAD_DESC ? STR_COMPANY_INFRASTRUCTURE_VIEW_ROAD_SECT : STR_COMPANY_INFRASTRUCTURE_VIEW_TRAM_SECT).width); |