(svn r4802) - Codechange: replace _stringwidth_base and associated magic numbers with a FontSize enum, using the numbers (which are SpriteIDs) in only the places needed.

This commit is contained in:
peter1138
2006-05-09 13:23:04 +00:00
parent 52bab5e9bd
commit fd778ecafa
4 changed files with 87 additions and 66 deletions

View File

@@ -1002,9 +1002,9 @@ void UpdateViewportSignPos(ViewportSign *sign, int left, int top, StringID str)
sign->left = left - w / 2;
// zoomed out version
_stringwidth_base = 0xE0;
_cur_fontsize = FS_SMALL;
w = GetStringWidth(buffer) + 3;
_stringwidth_base = 0;
_cur_fontsize = FS_NORMAL;
sign->width_2 = w;
}