diff --git a/plugins/robots/common/twoDModel/src/engine/items/ballItem.cpp b/plugins/robots/common/twoDModel/src/engine/items/ballItem.cpp index f3ace55565..929d430ebb 100644 --- a/plugins/robots/common/twoDModel/src/engine/items/ballItem.cpp +++ b/plugins/robots/common/twoDModel/src/engine/items/ballItem.cpp @@ -119,9 +119,11 @@ QPainterPath BallItem::shape() const void BallItem::saveStartPosition() { - mStartPosition = pos(); - mStartRotation = rotation(); - emit x1Changed(x1()); + if (this->editable()) { + mStartPosition = pos(); + mStartRotation = rotation(); + emit x1Changed(x1()); + } } void BallItem::returnToStartPosition() diff --git a/plugins/robots/common/twoDModel/src/engine/items/skittleItem.cpp b/plugins/robots/common/twoDModel/src/engine/items/skittleItem.cpp index db6540a44a..29cbdb403d 100644 --- a/plugins/robots/common/twoDModel/src/engine/items/skittleItem.cpp +++ b/plugins/robots/common/twoDModel/src/engine/items/skittleItem.cpp @@ -112,9 +112,11 @@ void SkittleItem::deserialize(const QDomElement &element) void SkittleItem::saveStartPosition() { - mStartPosition = pos(); - mStartRotation = rotation(); - emit x1Changed(x1()); + if (this->editable()) { + mStartPosition = pos(); + mStartRotation = rotation(); + emit x1Changed(x1()); + } } void SkittleItem::returnToStartPosition()