This is a migrated thread and some comments may be shown as answers.

Change transition direction

1 Answer 96 Views
Animation
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Alessandro
Top achievements
Rank 1
Alessandro asked on 15 Jul 2014, 05:36 PM
Hello, currently i have this code for page transitions :

RadSlideTransition anim = new RadSlideTransition();
anim.Orientation = System.Windows.Controls.Orientation.Horizontal;

RadPhoneApplicationFrame frame = new RadPhoneApplicationFrame{Transition = anim};
RootFrame = frame;


This always shows the new page coming from the right and sliding to the left.

I use a swipe control so the user can swipe the page to left or right and i would like to change the direction of the page transition according to the user swipe direction.

Is there a way to acomplish that ? i tried with every transition control from telerik and couldnt change the animation.

The closes i got was trying something like:
anim.ForwardOutAnimation = anim.ForwardOutAnimation.CreateOpposite();

But this created a weird animation because the animation started at the same point of the original and then the page would "jump" to the left and start the animation to the right.



1 Answer, 1 is accepted

Sort by
0
Rosy Topchiyska
Telerik team
answered on 18 Jul 2014, 09:57 AM
Hello Alessandro,

Thank you for contacting us.

From the provided information I can not completely understand what is your scenario. I have attached a sample project that demonstrates how to play different animations depending on whether the user navigates to a new page or goes back. I have used the Page.OnNavigatedTo() method where depending on the NavigationEventArgs.NavigationMode I create proper animation for the page. If this is not your scenario, could you please elaborate a bit more on what exactly you wish to accomplish or you can send us a sample project.

I hope this helps. Please, let us know if you have further questions.

Regards,
Rosy Topchiyska
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
Tags
Animation
Asked by
Alessandro
Top achievements
Rank 1
Answers by
Rosy Topchiyska
Telerik team
Share this question
or