Merge pull request #2795 from AaronVanGeffen/invalidate_ride_window

Repopulate ride list when invalidating the ride construction window
This commit is contained in:
Ted John 2016-01-23 14:51:48 +00:00
commit d621fafb3e
1 changed files with 7 additions and 0 deletions

View File

@ -254,6 +254,7 @@ static void window_new_ride_select(rct_window *w);
static ride_list_item _lastTrackDesignCountRideType;
static int _lastTrackDesignCount;
static bool _trackSelectionByType;
/**
*
@ -372,6 +373,7 @@ static void window_new_ride_populate_list()
nextListItem->type = 255;
nextListItem->entry_index = 255;
_trackSelectionByType = gConfigInterface.select_by_track_type;
}
/**
@ -651,6 +653,11 @@ static void window_new_ride_update(rct_window *w)
if (w->new_ride.selected_ride_id != -1 && w->new_ride.selected_ride_countdown-- == 0)
window_new_ride_select(w);
if (_trackSelectionByType != gConfigInterface.select_by_track_type) {
window_new_ride_populate_list();
widget_invalidate(w, WIDX_RIDE_LIST);
}
}
/**