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

How to use Transition Control inside canvas?

6 Answers 148 Views
TransitionControl
This is a migrated thread and some comments may be shown as answers.
Alfonso
Top achievements
Rank 1
Alfonso asked on 25 Jun 2010, 09:18 AM
Dear expert,

We have a Canvas which contain several controls, after some interval(let's say 1 minites), the children of the Canvas will be removed and readd some other different controls to that Canvas. We really want to implement the transition effect at the time Children changing(Slide and zoom effect).

Can such transition effect be implemented use Transition Control?

I have seen the code of the demo http://demos.telerik.com/silverlight/#TransitionControl/FirstLook , and I have also seen the Transitions been used in TabControl
http://blogs.telerik.com/SilverlightTeam/Posts/10-05-12/using_transitions_with_radtransitioncontrol_and_transitionpresenter_in_radtabcontrol.aspx
But still very confused, seems there is no document to help to use this Transition Control.

Any advice on this? It will be great if you can provide some simple demo about this.I am sure this scenario will be used widespreadly.

Many thanks,

Alfonso

6 Answers, 1 is accepted

Sort by
0
Pana
Telerik team
answered on 28 Jun 2010, 09:45 AM
Hello Alfonso,

The RadTransitionControl uses transitions to display animation when its content changes. If you have canvases with somewhat content in them you will have to set the Content of the RadTransitionControl to be the new Canvas. Then the RadTransitionControl will display animation with transition from the old canvas to the new one.

Another idea would be to use the code from the blogpost, remove the tabs strip (so the RadTabControl will display content but will not have tabs on top) and then put the Canvases in different RadTabItems in the RadTabControl. Then changing the selected RadTabItem will display the Canvas in the new selected RadTabItem.

Greetings,
Panayot
the Telerik team
0
Alfonso
Top achievements
Rank 1
answered on 29 Jun 2010, 01:55 AM
For the second approach, how to remove the tab strip? Thanks.
0
Alfonso
Top achievements
Rank 1
answered on 29 Jun 2010, 04:03 AM
For the first approach, I switch two canvas as the content of the Transition Control, however, the mouse down event can only be fired when user click one of the children of the canvas(which is the current content of the Transition Control). Why will this happen? Thanks for your great help.
0
Pana
Telerik team
answered on 01 Jul 2010, 07:07 AM
Hi Alfonso,

To remove the tab strip you will have to edit the RadTabControl in Blend. You will have to create a copy of the default style for the TabControl and edit its ControlTemplate.

As for the MouseEvent probably it gets fired because the Canvas is transparent and does not gets hits while its children does. You can try to set somewhat background on the canvas that will get hit by the hit test and fire the MouseDown event.

Regards,
Panayot
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Ulrich Fiege
Top achievements
Rank 1
answered on 03 Sep 2010, 01:03 PM
hello, i have following situation. We are using a layout grid inside a mainpage. When side changes the
new side is added as child into mainpage. How can i use the transition when in radmenu a new page is selected and
loaded as child into mainpage?
thank you ...

0
Konstantina
Telerik team
answered on 08 Sep 2010, 02:33 PM
Hi Ulrich,

You could refer to this blog post. In it is explained how you can use the TransitionControl to navigate between pages. You could refer to point 2.

Hope it will be useful. If you need further help please let us know.

Best wishes,
Konstantina
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Tags
TransitionControl
Asked by
Alfonso
Top achievements
Rank 1
Answers by
Pana
Telerik team
Alfonso
Top achievements
Rank 1
Ulrich Fiege
Top achievements
Rank 1
Konstantina
Telerik team
Share this question
or