(svn r14784) -Change: don't close and reopen the vehicle order/detail windows, just refocus them instead.

This commit is contained in:
rubidium 2009-01-02 20:01:28 +00:00
parent 0c352ede7a
commit bde4b6020a
2 changed files with 2 additions and 5 deletions

View File

@ -1267,10 +1267,8 @@ static const WindowDesc _other_orders_desc = {
void ShowOrdersWindow(const Vehicle *v)
{
VehicleID veh = v->index;
DeleteWindowById(WC_VEHICLE_ORDERS, veh);
DeleteWindowById(WC_VEHICLE_DETAILS, veh);
DeleteWindowById(WC_VEHICLE_DETAILS, v->index);
if (BringWindowToFrontById(WC_VEHICLE_ORDERS, v->index) != NULL) return;
if (v->owner != _local_company) {
new OrdersWindow(&_other_orders_desc, v);

View File

@ -1553,7 +1553,6 @@ static const WindowDesc _vehicle_details_desc = {
static void ShowVehicleDetailsWindow(const Vehicle *v)
{
DeleteWindowById(WC_VEHICLE_ORDERS, v->index);
DeleteWindowById(WC_VEHICLE_DETAILS, v->index);
AllocateWindowDescFront<VehicleDetailsWindow>(&_vehicle_details_desc, v->index);
}