mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-08-12 09:09:09 +00:00
Fix 884b9e66
: No need to include extra pixel for pressed state.
This commit is contained in:
@@ -3341,7 +3341,7 @@ std::unique_ptr<NWidgetBase> MakeCompanyButtonRows(WidgetID widget_first, Widget
|
|||||||
|
|
||||||
Dimension sprite_size = GetSpriteSize(SPR_COMPANY_ICON, nullptr, ZOOM_LVL_OUT_4X);
|
Dimension sprite_size = GetSpriteSize(SPR_COMPANY_ICON, nullptr, ZOOM_LVL_OUT_4X);
|
||||||
sprite_size.width += WidgetDimensions::unscaled.matrix.Horizontal();
|
sprite_size.width += WidgetDimensions::unscaled.matrix.Horizontal();
|
||||||
sprite_size.height += WidgetDimensions::unscaled.matrix.Vertical() + 1; // 1 for the 'offset' of being pressed
|
sprite_size.height += WidgetDimensions::unscaled.matrix.Vertical();
|
||||||
|
|
||||||
for (WidgetID widnum = widget_first; widnum <= widget_last; widnum++) {
|
for (WidgetID widnum = widget_first; widnum <= widget_last; widnum++) {
|
||||||
/* Ensure there is room in 'hor' for another button. */
|
/* Ensure there is room in 'hor' for another button. */
|
||||||
|
Reference in New Issue
Block a user