From 0dbddcc2b4b375e8ae122b47d9c5941013b9d2d7 Mon Sep 17 00:00:00 2001 From: Mikael Sand Date: Sun, 27 Aug 2017 17:31:03 +0300 Subject: [PATCH] Fix viewbox scale and translate order/interaction on ios. --- ios/Utils/RNSVGViewBox.m | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ios/Utils/RNSVGViewBox.m b/ios/Utils/RNSVGViewBox.m index 29651cb8..dee14d8c 100644 --- a/ios/Utils/RNSVGViewBox.m +++ b/ios/Utils/RNSVGViewBox.m @@ -91,8 +91,8 @@ // The transform applied to content contained by the element is given by // translate(translate-x, translate-y) scale(scale-x, scale-y). - CGAffineTransform transform = CGAffineTransformMakeScale(scaleX, scaleY); - return CGAffineTransformTranslate(transform, translateX, translateY); + CGAffineTransform transform = CGAffineTransformMakeTranslation(translateX, translateY); + return CGAffineTransformScale(transform, scaleX, scaleY); } @end