Mercurial > hg > openttd
diff src/train_cmd.cpp @ 17489:7e48879a9608 draft
(svn r22244) -Codechange: Make vehicle windows handle command-/GUI-scope invalidations themself (from autoreplace and refitting).
author | frosch <frosch@openttd.org> |
---|---|
date | Sun, 13 Mar 2011 21:33:02 +0000 (2011-03-13) |
parents | aad8b54a8fa6 |
children | d5ff867052a5 |
line wrap: on
line diff
--- a/src/train_cmd.cpp +++ b/src/train_cmd.cpp @@ -264,7 +264,7 @@ if (this->IsFrontEngine()) { this->UpdateAcceleration(); SetWindowDirty(WC_VEHICLE_DETAILS, this->index); - InvalidateWindowData(WC_VEHICLE_REFIT, this->index); // Important, do not invalidate immediately. The refit window tests commands. + InvalidateWindowData(WC_VEHICLE_REFIT, this->index); } } @@ -1092,7 +1092,7 @@ if (!head->IsFrontEngine()) return; /* Update the refit button and window */ - InvalidateWindowData(WC_VEHICLE_REFIT, head->index); // Important, do not invalidate immediately. The refit window tests commands. + InvalidateWindowData(WC_VEHICLE_REFIT, head->index); SetWindowWidgetDirty(WC_VEHICLE_VIEW, head->index, VVW_WIDGET_REFIT_VEH); /* If we don't have a unit number yet, set one. */