Change: Use power-of-2 scaling for some dimensions in GUI.
These are related to drawing sprites that are normally drawn on the landscape, and should therefore still follow power-of-2 scaling to fit correctly.
This commit is contained in:
@@ -786,7 +786,7 @@ static inline void DrawCloseBox(const Rect &r, Colours colour)
|
||||
Dimension d = GetSpriteSize(SPR_CLOSEBOX, &offset);
|
||||
d.width -= offset.x;
|
||||
d.height -= offset.y;
|
||||
int s = ScaleGUITrad(1); /* Offset to account for shadow of SPR_CLOSEBOX */
|
||||
int s = ScaleSpriteTrad(1); /* Offset to account for shadow of SPR_CLOSEBOX */
|
||||
DrawSprite(SPR_CLOSEBOX, (colour != COLOUR_WHITE ? TC_BLACK : TC_SILVER) | (1U << PALETTE_TEXT_RECOLOUR), CenterBounds(r.left, r.right, d.width - s) - offset.x, CenterBounds(r.top, r.bottom, d.height - s) - offset.y);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user