1
0
mirror of https://github.com/OpenTTD/OpenTTD.git synced 2025-08-30 01:49:10 +00:00

(svn r18217) -Codechange: make the livery window big font aware

This commit is contained in:
rubidium
2009-11-22 13:01:07 +00:00
parent 88e80d4c76
commit a95655b7c8

View File

@@ -624,8 +624,16 @@ public:
break;
case SCLW_WIDGET_SEC_COL_DROPDOWN:
if (!_loaded_newgrf_features.has_2CC) size->width = 0;
break;
if (!_loaded_newgrf_features.has_2CC) {
size->width = 0;
break;
}
/* Fall through */
case SCLW_WIDGET_PRI_COL_DROPDOWN: {
for (const StringID *id = _colour_dropdown; id != endof(_colour_dropdown); id++) {
size->width = max(size->width, GetStringBoundingBox(*id).width + 34);
}
} break;
}
}