Fix land tool size staying in window after unselect land ownership tool

This commit is contained in:
Michael Steenbeek 2015-04-29 12:03:18 +02:00
parent d50a297981
commit 67656a46a9
1 changed files with 7 additions and 4 deletions

View File

@ -369,14 +369,17 @@ static void window_map_mouseup()
*/
static void window_map_mousedown(int widgetIndex, rct_window*w, rct_widget* widget)
{
// The normal map window doesn't have widget 8 or 9.
// I assume these widgets refer to the Scenario Editor's map window.
if (widgetIndex == 8) {
// These widgets all refer to the Scenario Editor's map window.
if (widgetIndex == WIDX_MAP_SIZE_SPINNER_UP) {
RCT2_CALLPROC_X(0x0068D641, 0, 0, 0, widgetIndex, (int)w, 0, 0);
}
else if (widgetIndex == 9) {
else if (widgetIndex == WIDX_MAP_SIZE_SPINNER_DOWN) {
RCT2_CALLPROC_X(0x0068D6B4, 0, 0, 0, widgetIndex, (int)w, 0, 0);
}
else if (widgetIndex == WIDX_SET_LAND_RIGHTS)
{
RCT2_GLOBAL(RCT2_ADDRESS_LAND_TOOL_SIZE, sint16) = 1;
}
}
/**