[Winodows Phone 7 control details] Silverlight toolkit for Windows Phone 7.1 control-6

Source: Internet
Author: User

7. navigationtransition

This control is used to implement page switching.

1. First add the Toolkit declaration in XAML:

xmlns:toolkit="clr-namespace:Microsoft.Phone.Controls;assembly=Microsoft.Phone.Controls.Toolkit"

2. manually add this control to XAML:

<Toolkit: transitionservice. navigationintransition>
<Toolkit: navigationintransition> <! -- Enter the page animation effect -->
<Toolkit: navigationintransition. Backward>
<Toolkit: rotatetransition mode = "in180clockwise"/> <! -- 180 ° flip effect -->
</Toolkit: navigationintransition. Backward>
<Toolkit: navigationintransition. Forward>
<Toolkit: rotatetransition mode = "in180clockwise"/>
</Toolkit: navigationintransition. Forward>
</Toolkit: navigationintransition>
</Toolkit: transitionservice. navigationintransition>
<Toolkit: transitionservice. navigationouttransition>
<Toolkit: navigationouttransition> <! -- Exit the page animation effect -->
<Toolkit: navigationouttransition. Backward>
<Toolkit: rotatetransition mode = "out180clockwise"/>
</Toolkit: navigationouttransition. Backward>
<Toolkit: navigationouttransition. Forward>
<Toolkit: rotatetransition mode = "out180clockwise"/>
</Toolkit: navigationouttransition. Forward>
</Toolkit: navigationouttransition>
</Toolkit: transitionservice. navigationouttransition>
<! -- Layoutroot is the root grid where all page content is placed -->

There are five animation effects for this control, and each animation has multiple modes: rolltransition (which has no mode setting), rotatetransition, slidetransition, swiveltransition, turnstiletransition

In addition, the animation effects for entering and exiting pages can be set to different effects.

3. Most important changes:

Modify the rootframe in the initializephoneapplication () function in APP. XAML. cs. If you do not change the value, there is no animation effect.

// Rootframe = new phoneapplicationframe ();
Rootframe = new transitionframe (); // required

Because the effect is too fast to capture, it cannot ~

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.