中心旋转

This commit is contained in:
TurnMeOn committed 2017-12-25 13:48:30 +08:00
1 parent dc29c9c70b
commit f6feb29b29
1 file changed
+1 -1
+1 -1
View File
@@ -32,7 +32,7 @@ Car::Car(ParkingLotManager * manager, QGraphicsItem *parent, int dir, Car::Color
}
m_pic = m_pic.scaled(M_WID, M_LEN);
this->setPixmap(m_pic);
setTransformOriginPoint(0, M_LEN/2); //设置旋转中心
setTransformOriginPoint(M_WID, M_LEN/2); //设置旋转中心
connect(posAni,QPropertyAnimation::finished,this,followPath);
connect(this, &Car::queueHead, manager, &ParkingLotManager::requestIn);
connect(this, &Car::exit, manager, &ParkingLotManager::leave);