Bug 57212 - TranslateTo auto-animating on Y axis
Summary: TranslateTo auto-animating on Y axis
Alias: None
Product: Forms
Classification: Xamarin
Component: Forms ()
Version: 2.3.4
Hardware: PC Windows
: --- normal
Target Milestone: ---
Assignee: Paul DiPietro [MSFT]
Depends on:
Reported: 2017-06-06 21:00 UTC by Clay
Modified: 2017-06-20 14:53 UTC (History)
3 users (show)

Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.

Please create a new report on Developer Community or GitHub with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:

Description Clay 2017-06-06 21:00:32 UTC
# Steps to reproduce
MyLabel.TranslateTo(MyLabel.X, MyLabel.Y);

# Expected behavior
The label should just sit there

# Actual behavior
The label moves down on the Y axis
Comment 1 Paul DiPietro [MSFT] 2017-06-13 17:02:36 UTC
Perhaps a bit naive, but can you elaborate? The docs explicitly state that TranslateTo "animates an element's TranslationX and TranslationY properties from their current values to the new values," so what is the scenario where it is automatically animating?
Comment 2 Clay 2017-06-13 17:08:49 UTC
If you have a label called MyLabel like I show above it has properties right?  

So lets say MyLabel.X evaluates to 0.
Then lets say MyLabel.Y evaluates to 20.

If I Now say MyLabel.TranlateTo(0, 20) it shouldn't move, correct?  Because the label is already at that location.

But If I then use MyLabel.TranslateTo(MyLabel.X, MyLabel.Y) it moves down on the Y axis.  Why is it doing this for Y?
Comment 3 Paul DiPietro [MSFT] 2017-06-20 14:53:08 UTC
I believe what's occurring here is that the TranslateX and TranslateY values are separate from the X and Y values, so the original X/Y are being used when you try to use them, and that this is to the best of my knowledge intended by design. It would make sense to update the X/Y values when using TranslateTo if that is your intention.