How does the Animation Class manage translation coordinates?
Picture the following.
You have a
Label that is offset on the
x axis by
200 via its
left property. Then a swipe gesture triggers an animation on the Label, which translates its
x axis by
Now, it makes sense to me that if translate is called again on the same
Label that it will translate from its original offset. Which is what happens.
However I thought if I update the
left property immediately after the first transition, any following transition would work from the new parameter. But it doesn’t. Translate always references back to the
Labels’ original coordinate.
From what I can tell this is set in stone during the
navigatedTo event. I say that because that’s when I’m seeting the
x axis offest that’s always referenced.
Is there some deeper level method (beyond view.set(“left”, x) for resetting a views coordinates for future translate calls to reference?
Otherwise I’m thinking I’ll either need to store an accumulative
translated value somewhere, so I know what future values to pass into translate.
Or after each animation, create a new
Label that’s coordinates are set to the existing
Labels’ and swop them over. Which just sounds stupid.
I’m sure there’s a real simple solution here, but I can’t see it (or find it in the docs).