diff options
author | rubidium <rubidium@openttd.org> | 2009-01-02 20:01:28 +0000 |
---|---|---|
committer | rubidium <rubidium@openttd.org> | 2009-01-02 20:01:28 +0000 |
commit | 80a35db52c8e2f88482fb63b5dee17c81be541f9 (patch) | |
tree | daaeb66b2873456797115cc1cf75e2f8b6212e44 /src/order_gui.cpp | |
parent | 7ab7c4e6ff0d20e01ef0f95cd9cbe88608199125 (diff) | |
download | openttd-80a35db52c8e2f88482fb63b5dee17c81be541f9.tar.xz |
(svn r14784) -Change: don't close and reopen the vehicle order/detail windows, just refocus them instead.
Diffstat (limited to 'src/order_gui.cpp')
-rw-r--r-- | src/order_gui.cpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/order_gui.cpp b/src/order_gui.cpp index 7c58aa293..e31114b45 100644 --- a/src/order_gui.cpp +++ b/src/order_gui.cpp @@ -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); |