mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2026-01-19 13:03:11 +01:00
Merge pull request #453 from adrian17/widget-click-fix
Fix disabled widgets being clickable and reenable third tab of Cheats
This commit is contained in:
@@ -531,8 +531,10 @@ static void input_leftmousedown(int x, int y, rct_window *w, int widgetIndex)
|
||||
}
|
||||
break;
|
||||
default:
|
||||
if (!widget_is_enabled(w, widgetIndex))
|
||||
break;
|
||||
if (!widget_is_enabled(w, widgetIndex))
|
||||
break;
|
||||
if (widget_is_disabled(w, widgetIndex))
|
||||
break;
|
||||
|
||||
sound_play_panned(SOUND_CLICK_1, w->x + (widget->left + widget->right) / 2);
|
||||
|
||||
|
||||
@@ -238,9 +238,9 @@ static void* window_cheats_page_events[] = {
|
||||
};
|
||||
|
||||
static uint32 window_cheats_page_enabled_widgets[] = {
|
||||
(1 << WIDX_CLOSE) | (1 << WIDX_TAB_1) | (1 << WIDX_TAB_2) | (1 << WIDX_HIGH_MONEY) | (1 << WIDX_PARK_ENTRANCE_FEE),
|
||||
(1 << WIDX_CLOSE) | (1 << WIDX_TAB_1) | (1 << WIDX_TAB_2) | (1 << WIDX_HAPPY_GUESTS) | (1 << WIDX_TRAM_GUESTS),
|
||||
(1 << WIDX_CLOSE) | (1 << WIDX_TAB_1) | (1 << WIDX_TAB_2) | (1 << WIDX_FREEZE_CLIMATE) | (1 << WIDX_OPEN_CLOSE_PARK) | (1 << WIDX_DECREASE_GAME_SPEED) | (1 << WIDX_INCREASE_GAME_SPEED),
|
||||
(1 << WIDX_CLOSE) | (1 << WIDX_TAB_1) | (1 << WIDX_TAB_2) | (1 << WIDX_TAB_3) | (1 << WIDX_HIGH_MONEY) | (1 << WIDX_PARK_ENTRANCE_FEE),
|
||||
(1 << WIDX_CLOSE) | (1 << WIDX_TAB_1) | (1 << WIDX_TAB_2) | (1 << WIDX_TAB_3) | (1 << WIDX_HAPPY_GUESTS) | (1 << WIDX_TRAM_GUESTS),
|
||||
(1 << WIDX_CLOSE) | (1 << WIDX_TAB_1) | (1 << WIDX_TAB_2) | (1 << WIDX_TAB_3) | (1 << WIDX_FREEZE_CLIMATE) | (1 << WIDX_OPEN_CLOSE_PARK) | (1 << WIDX_DECREASE_GAME_SPEED) | (1 << WIDX_INCREASE_GAME_SPEED),
|
||||
};
|
||||
|
||||
static void window_cheats_draw_tab_images(rct_drawpixelinfo *dpi, rct_window *w);
|
||||
|
||||
Reference in New Issue
Block a user