diff --git a/src/core/Boxes/boundingbox.cpp b/src/core/Boxes/boundingbox.cpp index 25c398429..63b8de3c2 100644 --- a/src/core/Boxes/boundingbox.cpp +++ b/src/core/Boxes/boundingbox.cpp @@ -732,6 +732,11 @@ void BoundingBox::scale(const qreal scaleXBy, const qreal scaleYBy) { mTransformAnimator->scale(scaleXBy, scaleYBy); } +void BoundingBox::scaleBy(const qreal scale) +{ + mTransformAnimator->setScale(scale, scale); +} + void BoundingBox::rotateBy(const qreal rot) { mTransformAnimator->rotateRelativeToSavedValue(rot); } diff --git a/src/core/Boxes/boundingbox.h b/src/core/Boxes/boundingbox.h index 99497db56..baf172b01 100644 --- a/src/core/Boxes/boundingbox.h +++ b/src/core/Boxes/boundingbox.h @@ -284,6 +284,7 @@ class CORE_EXPORT BoundingBox : public eBoxOrSound { void rotateBy(const qreal rot); void scale(const qreal scaleBy); void scale(const qreal scaleXBy, const qreal scaleYBy); + void scaleBy(const qreal scale); void saveTransformPivotAbsPos(const QPointF &absPivot); void startPosTransform(); diff --git a/src/core/canvasselectedboxesactions.cpp b/src/core/canvasselectedboxesactions.cpp index d4c7ce72b..5a237649a 100644 --- a/src/core/canvasselectedboxesactions.cpp +++ b/src/core/canvasselectedboxesactions.cpp @@ -318,7 +318,7 @@ void Canvas::scaleSelectedBoxesStartAndFinish(const qreal scaleBy) if (mDocument.fLocalPivot) { for(const auto &box : mSelectedBoxes) { box->startScaleTransform(); - box->scale(scaleBy); + box->scaleBy(scaleBy); box->finishTransform(); } } else {