summaryrefslogtreecommitdiff
path: root/src/train_cmd.cpp
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2011-02-09 20:45:07 +0000
committerrubidium <rubidium@openttd.org>2011-02-09 20:45:07 +0000
commit15514a3011c6563a39a7ce0a1ead561fd5b0784f (patch)
tree03bbc2bfa0f5ad0b857faf52ab5aa2248a5bafd1 /src/train_cmd.cpp
parent69789f3008968de7d0740792cb26a179a3b30436 (diff)
downloadopenttd-15514a3011c6563a39a7ce0a1ead561fd5b0784f.tar.xz
(svn r22043) -Fix: invalidate the right windows when a part of a train is flipped in the depot
Diffstat (limited to 'src/train_cmd.cpp')
-rw-r--r--src/train_cmd.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/train_cmd.cpp b/src/train_cmd.cpp
index 9746fd403..fd0abdc28 100644
--- a/src/train_cmd.cpp
+++ b/src/train_cmd.cpp
@@ -1806,11 +1806,11 @@ CommandCost CmdReverseTrainDirection(TileIndex tile, DoCommandFlag flags, uint32
if (flags & DC_EXEC) {
ToggleBit(v->flags, VRF_REVERSE_DIRECTION);
- SetWindowDirty(WC_VEHICLE_DEPOT, v->tile);
- SetWindowDirty(WC_VEHICLE_DETAILS, v->index);
- /* We cancel any 'skip signal at dangers' here */
- v->force_proceed = TFP_NONE;
- SetWindowDirty(WC_VEHICLE_VIEW, v->index);
+
+ SetWindowDirty(WC_VEHICLE_DEPOT, front->tile);
+ SetWindowDirty(WC_VEHICLE_DETAILS, front->index);
+ SetWindowDirty(WC_VEHICLE_VIEW, front->index);
+ SetWindowClassesDirty(WC_TRAINS_LIST);
}
} else {
/* turn the whole train around */