diff options
author | belugas <belugas@openttd.org> | 2008-07-31 03:13:35 +0000 |
---|---|---|
committer | belugas <belugas@openttd.org> | 2008-07-31 03:13:35 +0000 |
commit | 434493b6603f75ca78e524b68672af581f69bdca (patch) | |
tree | 01ee7610124ac3576d6c01e0db9e84bc6d568d38 /src | |
parent | 195f40b1231e8cc17e03d208144ab76085b4dd9f (diff) | |
download | openttd-434493b6603f75ca78e524b68672af581f69bdca.tar.xz |
(svn r13889) -Codechange: Replace numbers with Colours enum on transparency gui.
-Fix: "true" is not a color. COLOUR_PALE_GREEN should look better, at least in the code ;)
Diffstat (limited to 'src')
-rw-r--r-- | src/transparency_gui.cpp | 34 |
1 files changed, 17 insertions, 17 deletions
diff --git a/src/transparency_gui.cpp b/src/transparency_gui.cpp index 8f9954e01..8b6d234db 100644 --- a/src/transparency_gui.cpp +++ b/src/transparency_gui.cpp @@ -57,11 +57,11 @@ public: /* Do not draw button for invisible loading indicators */ for (uint i = 0; i < 8; i++) { if (i < TTW_WIDGET_BRIDGES - TTW_WIDGET_SIGNS) { - DrawFrameRect(i * 22, 38, i * 22 + 19, 46, true, HasBit(_invisibility_opt, i) ? FR_LOWERED : FR_NONE); + DrawFrameRect(i * 22, 38, i * 22 + 19, 46, COLOUR_PALE_GREEN, HasBit(_invisibility_opt, i) ? FR_LOWERED : FR_NONE); } else if (i == TTW_WIDGET_BRIDGES - TTW_WIDGET_SIGNS) { - DrawFrameRect(i * 22, 38, i * 22 + 41, 46, true, HasBit(_invisibility_opt, i) ? FR_LOWERED : FR_NONE); + DrawFrameRect(i * 22, 38, i * 22 + 41, 46, COLOUR_PALE_GREEN, HasBit(_invisibility_opt, i) ? FR_LOWERED : FR_NONE); } else { // i > TTW_WIDGET_BRIDGES - TTW_WIDGET_SIGNS - DrawFrameRect((i + 1) * 22, 38, (i + 1) * 22 + 19, 46, true, HasBit(_invisibility_opt, i) ? FR_LOWERED : FR_NONE); + DrawFrameRect((i + 1) * 22, 38, (i + 1) * 22 + 19, 46, COLOUR_PALE_GREEN, HasBit(_invisibility_opt, i) ? FR_LOWERED : FR_NONE); } } } @@ -99,23 +99,23 @@ public: }; static const Widget _transparency_widgets[] = { -{ WWT_CLOSEBOX, RESIZE_NONE, 7, 0, 10, 0, 13, STR_00C5, STR_018B_CLOSE_WINDOW}, -{ WWT_CAPTION, RESIZE_NONE, 7, 11, 206, 0, 13, STR_TRANSPARENCY_TOOLB, STR_018C_WINDOW_TITLE_DRAG_THIS}, -{WWT_STICKYBOX, RESIZE_NONE, 7, 207, 218, 0, 13, STR_NULL, STR_STICKY_BUTTON}, +{ WWT_CLOSEBOX, RESIZE_NONE, COLOUR_DARK_GREEN, 0, 10, 0, 13, STR_00C5, STR_018B_CLOSE_WINDOW}, +{ WWT_CAPTION, RESIZE_NONE, COLOUR_DARK_GREEN, 11, 206, 0, 13, STR_TRANSPARENCY_TOOLB, STR_018C_WINDOW_TITLE_DRAG_THIS}, +{WWT_STICKYBOX, RESIZE_NONE, COLOUR_DARK_GREEN, 207, 218, 0, 13, STR_NULL, STR_STICKY_BUTTON}, /* transparency widgets: * transparent signs, trees, houses, industries, player's buildings, bridges, unmovable structures, catenary and loading indicators */ -{ WWT_IMGBTN, RESIZE_NONE, 7, 0, 21, 14, 35, SPR_IMG_SIGN, STR_TRANSPARENT_SIGNS_DESC}, -{ WWT_IMGBTN, RESIZE_NONE, 7, 22, 43, 14, 35, SPR_IMG_PLANTTREES, STR_TRANSPARENT_TREES_DESC}, -{ WWT_IMGBTN, RESIZE_NONE, 7, 44, 65, 14, 35, SPR_IMG_TOWN, STR_TRANSPARENT_HOUSES_DESC}, -{ WWT_IMGBTN, RESIZE_NONE, 7, 66, 87, 14, 35, SPR_IMG_INDUSTRY, STR_TRANSPARENT_INDUSTRIES_DESC}, -{ WWT_IMGBTN, RESIZE_NONE, 7, 88, 109, 14, 35, SPR_IMG_COMPANY_LIST, STR_TRANSPARENT_BUILDINGS_DESC}, -{ WWT_IMGBTN, RESIZE_NONE, 7, 110, 152, 14, 35, SPR_IMG_BRIDGE, STR_TRANSPARENT_BRIDGES_DESC}, -{ WWT_IMGBTN, RESIZE_NONE, 7, 153, 174, 14, 35, SPR_IMG_TRANSMITTER, STR_TRANSPARENT_STRUCTURES_DESC}, -{ WWT_IMGBTN, RESIZE_NONE, 7, 175, 196, 14, 35, SPR_BUILD_X_ELRAIL, STR_TRANSPARENT_CATENARY_DESC}, -{ WWT_IMGBTN, RESIZE_NONE, 7, 197, 218, 14, 35, SPR_IMG_TRAINLIST, STR_TRANSPARENT_LOADING_DESC}, - -{ WWT_PANEL, RESIZE_NONE, 7, 0, 218, 36, 48, 0x0, STR_TRANSPARENT_INVISIBLE_DESC}, +{ WWT_IMGBTN, RESIZE_NONE, COLOUR_DARK_GREEN, 0, 21, 14, 35, SPR_IMG_SIGN, STR_TRANSPARENT_SIGNS_DESC}, +{ WWT_IMGBTN, RESIZE_NONE, COLOUR_DARK_GREEN, 22, 43, 14, 35, SPR_IMG_PLANTTREES, STR_TRANSPARENT_TREES_DESC}, +{ WWT_IMGBTN, RESIZE_NONE, COLOUR_DARK_GREEN, 44, 65, 14, 35, SPR_IMG_TOWN, STR_TRANSPARENT_HOUSES_DESC}, +{ WWT_IMGBTN, RESIZE_NONE, COLOUR_DARK_GREEN, 66, 87, 14, 35, SPR_IMG_INDUSTRY, STR_TRANSPARENT_INDUSTRIES_DESC}, +{ WWT_IMGBTN, RESIZE_NONE, COLOUR_DARK_GREEN, 88, 109, 14, 35, SPR_IMG_COMPANY_LIST, STR_TRANSPARENT_BUILDINGS_DESC}, +{ WWT_IMGBTN, RESIZE_NONE, COLOUR_DARK_GREEN, 110, 152, 14, 35, SPR_IMG_BRIDGE, STR_TRANSPARENT_BRIDGES_DESC}, +{ WWT_IMGBTN, RESIZE_NONE, COLOUR_DARK_GREEN, 153, 174, 14, 35, SPR_IMG_TRANSMITTER, STR_TRANSPARENT_STRUCTURES_DESC}, +{ WWT_IMGBTN, RESIZE_NONE, COLOUR_DARK_GREEN, 175, 196, 14, 35, SPR_BUILD_X_ELRAIL, STR_TRANSPARENT_CATENARY_DESC}, +{ WWT_IMGBTN, RESIZE_NONE, COLOUR_DARK_GREEN, 197, 218, 14, 35, SPR_IMG_TRAINLIST, STR_TRANSPARENT_LOADING_DESC}, + +{ WWT_PANEL, RESIZE_NONE, COLOUR_DARK_GREEN, 0, 218, 36, 48, 0x0, STR_TRANSPARENT_INVISIBLE_DESC}, { WIDGETS_END}, }; |