From 56e6282f2f56d741634e30bba86fcfbd941bc285 Mon Sep 17 00:00:00 2001 From: belugas Date: Sun, 4 Nov 2007 00:08:57 +0000 Subject: (svn r11374) -Codechange: Give meaning to the magical number that specifies the color of the text in a DrawString call. Patch heavily based on BiBB's work (FS#1383) --- src/newgrf_gui.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/newgrf_gui.cpp') diff --git a/src/newgrf_gui.cpp b/src/newgrf_gui.cpp index e1479d125..17e80656f 100644 --- a/src/newgrf_gui.cpp +++ b/src/newgrf_gui.cpp @@ -143,7 +143,7 @@ static void NewGRFAddDlgWndProc(Window *w, WindowEvent *e) /* Draw selection background */ if (h) GfxFillRect(3, y, w->width - 15, y + 9, 156); - DoDrawStringTruncated(text, 4, y, h ? 0xC : 0x6, w->width - 18); + DoDrawStringTruncated(text, 4, y, h ? TC_WHITE : TC_ORANGE, w->width - 18); y += 10; } n++; @@ -370,7 +370,7 @@ static void NewGRFWndProc(Window *w, WindowEvent *e) DrawSprite(SPR_SQUARE, pal, 5, y + 2); if (c->error != NULL) DrawSprite(SPR_WARNING_SIGN, 0, 20, y + 2); txtoffset = c->error != NULL ? 35 : 25; - DoDrawStringTruncated(text, txtoffset, y + 3, WP(w, newgrf_d).sel == c ? 0xC : 0x10, w->width - txtoffset - 10); + DoDrawStringTruncated(text, txtoffset, y + 3, WP(w, newgrf_d).sel == c ? TC_WHITE : TC_BLACK, w->width - txtoffset - 10); y += 14; } } -- cgit v1.2.3-70-g09d2