Codechange: Remove FONT_HEIGHT_... macros. (#11481)
These make it look like we're dealing with a constant, but actually each is a call to `GetCharacterHeight(...)`.
This commit is contained in:
@@ -38,7 +38,7 @@ void DrawAircraftDetails(const Aircraft *v, const Rect &r)
|
||||
SetDParam(1, u->build_year);
|
||||
SetDParam(2, u->value);
|
||||
DrawString(r.left, r.right, y, STR_VEHICLE_INFO_BUILT_VALUE);
|
||||
y += FONT_HEIGHT_NORMAL;
|
||||
y += GetCharacterHeight(FS_NORMAL);
|
||||
|
||||
SetDParam(0, u->cargo_type);
|
||||
SetDParam(1, u->cargo_cap);
|
||||
@@ -46,7 +46,7 @@ void DrawAircraftDetails(const Aircraft *v, const Rect &r)
|
||||
SetDParam(3, u->Next()->cargo_cap);
|
||||
SetDParam(4, GetCargoSubtypeText(u));
|
||||
DrawString(r.left, r.right, y, (u->Next()->cargo_cap != 0) ? STR_VEHICLE_INFO_CAPACITY_CAPACITY : STR_VEHICLE_INFO_CAPACITY);
|
||||
y += FONT_HEIGHT_NORMAL + WidgetDimensions::scaled.vsep_normal;
|
||||
y += GetCharacterHeight(FS_NORMAL) + WidgetDimensions::scaled.vsep_normal;
|
||||
}
|
||||
|
||||
if (u->cargo_cap != 0) {
|
||||
@@ -58,7 +58,7 @@ void DrawAircraftDetails(const Aircraft *v, const Rect &r)
|
||||
SetDParam(1, cargo_count);
|
||||
SetDParam(2, u->cargo.GetFirstStation());
|
||||
DrawString(r.left, r.right, y, STR_VEHICLE_DETAILS_CARGO_FROM);
|
||||
y += FONT_HEIGHT_NORMAL;
|
||||
y += GetCharacterHeight(FS_NORMAL);
|
||||
feeder_share += u->cargo.GetFeederShare();
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user