summaryrefslogtreecommitdiff
path: root/src/vehicle.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/vehicle.cpp')
-rw-r--r--src/vehicle.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/vehicle.cpp b/src/vehicle.cpp
index 6df16caf6..9e2292751 100644
--- a/src/vehicle.cpp
+++ b/src/vehicle.cpp
@@ -778,6 +778,8 @@ void Vehicle::HandlePathfindingResult(bool path_found)
/* Clear the flag as the PF's problem was solved. */
ClrBit(this->vehicle_flags, VF_PATHFINDER_LOST);
+ SetWindowWidgetDirty(WC_VEHICLE_VIEW, this->index, WID_VV_START_STOP);
+ InvalidateWindowClassesData(GetWindowClassForVehicleType(this->type));
/* Delete the news item. */
DeleteVehicleNews(this->index, STR_NEWS_VEHICLE_IS_LOST);
return;
@@ -788,6 +790,8 @@ void Vehicle::HandlePathfindingResult(bool path_found)
/* It is first time the problem occurred, set the "lost" flag. */
SetBit(this->vehicle_flags, VF_PATHFINDER_LOST);
+ SetWindowWidgetDirty(WC_VEHICLE_VIEW, this->index, WID_VV_START_STOP);
+ InvalidateWindowClassesData(GetWindowClassForVehicleType(this->type));
/* Notify user about the event. */
AI::NewEvent(this->owner, new ScriptEventVehicleLost(this->index));
if (_settings_client.gui.lost_vehicle_warn && this->owner == _local_company) {