mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2026-01-27 00:34:46 +01:00
Clean up translucent palettes
This commit is contained in:
@@ -297,8 +297,9 @@ static void window_dropdown_paint(rct_window *w, rct_drawpixelinfo *dpi)
|
||||
b = t;
|
||||
|
||||
if (w->colours[0] & COLOUR_FLAG_TRANSLUCENT) {
|
||||
gfx_filter_rect(dpi, l, t, r, b, _9DEDF4[w->colours[0]] + 1);
|
||||
gfx_filter_rect(dpi, l, t + 1, r, b + 1, _9DEDF4[w->colours[0]] + 2);
|
||||
translucent_window_palette palette = TranslucentWindowPalettes[BASE_COLOUR(w->colours[0])];
|
||||
gfx_filter_rect(dpi, l, t, r, b, palette.highlight);
|
||||
gfx_filter_rect(dpi, l, t + 1, r, b + 1, palette.shadow);
|
||||
} else {
|
||||
gfx_fill_rect(dpi, l, t, r, b, ColourMapA[w->colours[0]].mid_dark);
|
||||
gfx_fill_rect(dpi, l, t + 1, r, b + 1, ColourMapA[w->colours[0]].lightest);
|
||||
|
||||
@@ -810,10 +810,10 @@ void window_themes_scrollpaint(rct_window *w, rct_drawpixelinfo *dpi, int scroll
|
||||
if (i + 1 < get_colour_scheme_tab_count()) {
|
||||
int colour = w->colours[1];
|
||||
if (colour & COLOUR_FLAG_TRANSLUCENT) {
|
||||
FILTER_PALETTE_ID palette = _9DEDF4[colour];
|
||||
translucent_window_palette windowPalette = TranslucentWindowPalettes[BASE_COLOUR(colour)];
|
||||
|
||||
gfx_filter_rect(dpi, 0, y + _row_height - 2, window_themes_widgets[WIDX_THEMES_LIST].right, y + _row_height - 2, palette + 1);
|
||||
gfx_filter_rect(dpi, 0, y + _row_height - 1, window_themes_widgets[WIDX_THEMES_LIST].right, y + _row_height - 1, palette + 2);
|
||||
gfx_filter_rect(dpi, 0, y + _row_height - 2, window_themes_widgets[WIDX_THEMES_LIST].right, y + _row_height - 2, windowPalette.highlight);
|
||||
gfx_filter_rect(dpi, 0, y + _row_height - 1, window_themes_widgets[WIDX_THEMES_LIST].right, y + _row_height - 1, windowPalette.shadow);
|
||||
}
|
||||
else {
|
||||
colour = ColourMapA[w->colours[1]].mid_dark;
|
||||
|
||||
Reference in New Issue
Block a user