(svn r3359) - Autoreplace GUI: When starting or stopping a replacement, redraw the replace window after the command has completed, rather than after calling the command.

This commit is contained in:
2006-01-02 19:55:09 +00:00
parent 5353d05865
commit eeeebf9f6d
2 changed files with 7 additions and 4 deletions

View File

@@ -940,14 +940,12 @@ static void ReplaceVehicleWndProc(Window *w, WindowEvent *e)
EngineID veh_from = WP(w, replaceveh_d).sel_engine[0];
EngineID veh_to = WP(w, replaceveh_d).sel_engine[1];
DoCommandP(0, 3, veh_from + (veh_to << 16), NULL, CMD_REPLACE_VEHICLE);
SetWindowDirty(w);
break;
}
case 6: { /* Stop replacing */
EngineID veh_from = WP(w, replaceveh_d).sel_engine[0];
DoCommandP(0, 3, veh_from + (INVALID_ENGINE << 16), NULL, CMD_REPLACE_VEHICLE);
SetWindowDirty(w);
break;
}