Only use red text colour for expenditure sums (#1095)
This commit is contained in:
parent
8461ad721b
commit
ae294ad80e
|
@ -3,6 +3,7 @@
|
|||
- Fix: [#1035] Incorrect colour selection when building buildings.
|
||||
- Fix: [#1070] Crash when naming stations after exhausting natural names.
|
||||
- Fix: [#1094] Repeated clicking on construction window not always working.
|
||||
- Fix: [#1095] Individual expenses are drawn in red, not just the expenditure sums.
|
||||
- Change: [#298] Planting clusters of trees now costs money and influences ratings outside of editor mode.
|
||||
- Change: [#1079] Allow rotating buildings in town list by keyboard shortcut.
|
||||
|
||||
|
|
|
@ -1827,24 +1827,16 @@ namespace OpenLoco::Ui::Windows::CompanyWindow
|
|||
currency48_t expenditures = company.expenditures[columnIndex][j];
|
||||
sum += expenditures;
|
||||
|
||||
string_id mainFormat = StringIds::black_stringid;
|
||||
string_id currFormat = StringIds::plus_currency48;
|
||||
if (expenditures < 0)
|
||||
{
|
||||
mainFormat = StringIds::red_stringid;
|
||||
currFormat = StringIds::currency48;
|
||||
}
|
||||
|
||||
if (expenditures != 0)
|
||||
{
|
||||
auto args = FormatArguments::common(currFormat, expenditures);
|
||||
auto args = FormatArguments::common(StringIds::currency48, expenditures);
|
||||
|
||||
Gfx::drawString_494C78(
|
||||
*context,
|
||||
x,
|
||||
y,
|
||||
Colour::black,
|
||||
mainFormat,
|
||||
StringIds::black_stringid,
|
||||
&args);
|
||||
}
|
||||
y += 10;
|
||||
|
|
Loading…
Reference in New Issue