summaryrefslogtreecommitdiff
path: root/Xamarin.Forms.Platform.WinRT
diff options
context:
space:
mode:
authorkingces95 <kingces95@users.noreply.github.com>2016-04-13 16:16:04 (GMT)
committerRui Marinho <me@ruimarinho.net>2016-04-13 16:16:04 (GMT)
commita67a1daad040f67edbad37adb22188fbdc5da195 (patch)
treecf2745657d27254093376c1eb2831044f93294d6 /Xamarin.Forms.Platform.WinRT
parent5809eb5d4e7cd5f596ed7ad0c0265605b9c9600e (diff)
downloadxamarin-forms-a67a1daad040f67edbad37adb22188fbdc5da195.zip
xamarin-forms-a67a1daad040f67edbad37adb22188fbdc5da195.tar.gz
xamarin-forms-a67a1daad040f67edbad37adb22188fbdc5da195.tar.bz2
Suppress translation if scale is zero (#82)
Diffstat (limited to 'Xamarin.Forms.Platform.WinRT')
-rw-r--r--Xamarin.Forms.Platform.WinRT/VisualElementTracker.cs4
1 files changed, 2 insertions, 2 deletions
diff --git a/Xamarin.Forms.Platform.WinRT/VisualElementTracker.cs b/Xamarin.Forms.Platform.WinRT/VisualElementTracker.cs
index 0c3f759..760b9b3 100644
--- a/Xamarin.Forms.Platform.WinRT/VisualElementTracker.cs
+++ b/Xamarin.Forms.Platform.WinRT/VisualElementTracker.cs
@@ -457,8 +457,8 @@ namespace Xamarin.Forms.Platform.WinRT
{
CenterOfRotationX = anchorX,
CenterOfRotationY = anchorY,
- GlobalOffsetX = translationX / scale,
- GlobalOffsetY = translationY / scale,
+ GlobalOffsetX = scale == 0 ? 0 : translationX / scale,
+ GlobalOffsetY = scale == 0 ? 0 : translationY / scale,
RotationX = -rotationX,
RotationY = -rotationY,
RotationZ = -rotation