src/depot_gui.cpp
changeset 8414 8c2ecc2dc12c
parent 8385 aedd7656cfd1
child 8453 0410aa90bfdf
equal deleted inserted replaced
8413:41a5f63e6062 8414:8c2ecc2dc12c
   412 	GetDepotVehiclePtData gdvp;
   412 	GetDepotVehiclePtData gdvp;
   413 	Vehicle *v = NULL;
   413 	Vehicle *v = NULL;
   414 	int mode = GetVehicleFromDepotWndPt(w, x, y, &v, &gdvp);
   414 	int mode = GetVehicleFromDepotWndPt(w, x, y, &v, &gdvp);
   415 
   415 
   416 	/* share / copy orders */
   416 	/* share / copy orders */
   417 	if (_thd.place_mode && mode <= 0) {
   417 	if (_thd.place_mode != VHM_NONE && mode <= 0) {
   418 		_place_clicked_vehicle = (WP(w, depot_d).type == VEH_TRAIN ? gdvp.head : v);
   418 		_place_clicked_vehicle = (WP(w, depot_d).type == VEH_TRAIN ? gdvp.head : v);
   419 		return;
   419 		return;
   420 	}
   420 	}
   421 
   421 
   422 	if (WP(w, depot_d).type == VEH_TRAIN) v = gdvp.wagon;
   422 	if (WP(w, depot_d).type == VEH_TRAIN) v = gdvp.wagon;