diff options
author | frosch <frosch@openttd.org> | 2011-03-08 19:41:58 +0000 |
---|---|---|
committer | frosch <frosch@openttd.org> | 2011-03-08 19:41:58 +0000 |
commit | 9cf92e2bd250a0ff4fc3fa167057f1e79891d9ef (patch) | |
tree | 1bac62f70b166a9ad3d22353ccf08186f9c1925b /src/order_gui.cpp | |
parent | 31f46c078615df78eefca7166d58e53dccdbf7b2 (diff) | |
download | openttd-9cf92e2bd250a0ff4fc3fa167057f1e79891d9ef.tar.xz |
(svn r22226) -Codechange: When autoreplace invalidates vehicle windows because the Vehicle index changed, use a better eye-catcher-'data' than 0 to identify them.
Diffstat (limited to 'src/order_gui.cpp')
-rw-r--r-- | src/order_gui.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/order_gui.cpp b/src/order_gui.cpp index 6c40f9852..c4f4b7d9c 100644 --- a/src/order_gui.cpp +++ b/src/order_gui.cpp @@ -811,9 +811,10 @@ public: VehicleOrderID to = GB(data, 8, 8); switch (data) { - case 0: + case -666: /* Autoreplace replaced the vehicle */ this->vehicle = Vehicle::Get(this->window_number); + /* This case is _not_ called asynchronously. Get out directly, rest can be done later */ break; case -1: |