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

how to disable animation for pane when ispinned=false

9 Answers 199 Views
Docking
This is a migrated thread and some comments may be shown as answers.
silver
Top achievements
Rank 1
silver asked on 15 Jul 2010, 10:24 PM
I have set IsPinned=false in the docking rad pane, but upon load it is showing animation and then hiding it. Is there any way i can disable that animation? I am using RadControls for WPF Q2 2010 version# 2010.2.714.40

Appreciate your help,
Thanks!

9 Answers, 1 is accepted

Sort by
0
Konstantina
Telerik team
answered on 21 Jul 2010, 07:50 AM
Hi silver,

Thank you for contacting us.

To achieve that you will have to remove from the AnimationSelector the animations that you don't want to display. Here is the default value:


<telerikAnimation:AnimationSelector>
                    <!-- ToolWindow, Compass, RootCompass and DragCue animations -->
                    <telerikAnimation:AnimationGroup AnimationName="Move">
                        <telerikAnimation:MoveAnimation />
                        <telerikAnimation:ResizeAnimation />
                        <telerikAnimation:FadeAnimation Direction="In" />
                        <telerikAnimation:ScaleAnimation Direction="In" 
                                                         MinScale="0.7" 
                                                         MaxScale="1.0" 
                                                         TargetElementName="VisualRoot" />
                    </telerikAnimation:AnimationGroup>
  
                    <telerikAnimation:AnimationGroup AnimationName="Show">
                        <telerikAnimation:FadeAnimation Direction="In" />
                        <telerikAnimation:ScaleAnimation Direction="In" 
                                                         MinScale="0.95" 
                                                         MaxScale="1.0" 
                                                         TargetElementName="VisualRoot" />
                    </telerikAnimation:AnimationGroup>
                    <telerikAnimation:AnimationGroup AnimationName="Hide" 
                                                     SpeedRatio="0.7">
                        <telerikAnimation:FadeAnimation Direction="Out" />
                        <telerikAnimation:ScaleAnimation Direction="Out" 
                                                         MinScale="0.7" 
                                                         MaxScale="1.0" 
                                                         TargetElementName="VisualRoot" />
                    </telerikAnimation:AnimationGroup>
  
                    <!-- AutoHideArea animations -->
  
                    <!-- Left AutoHideArea animations -->
                    <telerikAnimation:AnimationGroup AnimationName="LeftIn">
                        <telerikDockingAnimations:AutoHideAreaAnimation SlideMode="Top"
                                                                        TargetElementName="PopupChild" 
                                                                        Orientation="Horizontal"
                                                                        Direction="In" />
                        <telerikAnimation:FadeAnimation TargetElementName="PopupChild"
                                Direction="In" />
                    </telerikAnimation:AnimationGroup>
  
                    <telerikAnimation:AnimationGroup AnimationName="LeftOut">
                        <telerikDockingAnimations:AutoHideAreaAnimation TargetElementName="PopupChild" 
                                                                        SlideMode="Top" 
                                                                        Orientation="Horizontal" 
                                                                        Direction="Out" />
                        <telerikAnimation:FadeAnimation TargetElementName="PopupChild"
                                                        Direction="Out" />
                    </telerikAnimation:AnimationGroup>
  
                    <!-- Top AutoHideArea animations -->
  
                    <telerikAnimation:AnimationGroup AnimationName="TopIn">
                        <telerikDockingAnimations:AutoHideAreaAnimation Orientation="Vertical"
                                                                        TargetElementName="PopupChild" 
                                                                        Direction="In" />
                        <telerikAnimation:FadeAnimation TargetElementName="PopupChild"
                                                        Direction="In" />
                    </telerikAnimation:AnimationGroup>
  
                    <telerikAnimation:AnimationGroup AnimationName="TopOut">
                        <telerikDockingAnimations:AutoHideAreaAnimation TargetElementName="PopupChild" 
                                                                        Orientation="Vertical"
                                                                        Direction="Out" />
                        <telerikAnimation:FadeAnimation TargetElementName="PopupChild"
                                                        Direction="Out" />
                    </telerikAnimation:AnimationGroup>
  
                    <!-- Right AutoHideArea animations -->
  
                    <telerikAnimation:AnimationGroup AnimationName="RightIn">
                        <telerikDockingAnimations:AutoHideAreaAnimation SlideMode="Bottom"
                                                                        TargetElementName="PopupChild" 
                                                                        Orientation="Horizontal"
                                                                        Direction="In" />
                        <telerikAnimation:FadeAnimation TargetElementName="PopupChild"
                                                        Direction="In" />
                    </telerikAnimation:AnimationGroup>
  
                    <telerikAnimation:AnimationGroup AnimationName="RightOut">
                        <telerikDockingAnimations:AutoHideAreaAnimation TargetElementName="PopupChild" SlideMode="Bottom"
                                                                        Orientation="Horizontal" 
                                                                        Direction="Out" />
                        <telerikAnimation:FadeAnimation TargetElementName="PopupChild"
                                                        Direction="Out" />
                    </telerikAnimation:AnimationGroup>
  
                    <!-- Bottom AutoHideArea animations -->
  
                    <telerikAnimation:AnimationGroup AnimationName="BottomIn">
                        <telerikDockingAnimations:AutoHideAreaAnimation SlideMode="Bottom"
                                Orientation="Vertical" TargetElementName="PopupChild" Direction="In" />
                        <telerikAnimation:FadeAnimation TargetElementName="PopupChild"
                                Direction="In" />
                    </telerikAnimation:AnimationGroup>
                    <telerikAnimation:AnimationGroup AnimationName="BottomOut">
                        <telerikDockingAnimations:AutoHideAreaAnimation
                                TargetElementName="PopupChild" Direction="Out"
                                Orientation="Vertical" SlideMode="Bottom" />
                        <telerikAnimation:FadeAnimation TargetElementName="PopupChild"
                                Direction="Out" />
                    </telerikAnimation:AnimationGroup>
                </telerikAnimation:AnimationSelector>

The animation with directions (up, down, left, etc) are the ones for the panes in the auto-hide area. You have to set the attached property AnimationSelector of the Docking control.

Hope this helps.

If you need further assistance please feel free to contact us again.

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
0
EM
Top achievements
Rank 1
answered on 30 Nov 2010, 08:49 PM
Hello,

Is it possible to get an example of disabling the above animations temporarily using code behind?  I'm adding a pane dynamically from code.  The pane is supposed to show collapsed (unpinned), which it does correctly.  However, visually it first shows up in the pinned (fully visible) state, the animation immediately kicks in and it goes into unpinned (collapsed) state.  The idea is to disable the animation so visually, the pane goes directly to the unpinned (collapsed) state and it doesn't cause a flicker noticeable by the user.

I've tried this code below to disable animations overall prior to adding the pane to the group in the split container, to no avail (dockingControl is a type of RadDocking).   The animation still shows.

        public void DisableDockingAnimations()
        {

            AnimationManager.SetIsAnimationEnabled(dockingControl, false);
        }

        public void EnableDockingAnimations()
        {
            AnimationManager.SetIsAnimationEnabled(dockingControl, true);
        }
        public void DisableDockingAnimations()
        {

            AnimationManager.SetIsAnimationEnabled(dockingControl, false);
        }

        public void EnableDockingAnimations()
        {
            AnimationManager.SetIsAnimationEnabled(dockingControl, true);
        }
public void DisableDockingAnimations()
{
 
    AnimationManager.SetIsAnimationEnabled(dockingControl, false);
}
 
public void EnableDockingAnimations()
{
    AnimationManager.SetIsAnimationEnabled(dockingControl, true);
}


Regards,

Etienne
0
Konstantina
Telerik team
answered on 03 Dec 2010, 02:17 PM
Hello Etienne,

To remove the animation from code behind you will have to use the AnimationManager.SetAnimationSelector and the corresponding AnimationManager.GetAnimationSelector.

Hope this information helps. Please let us know if you have further questions.

Best wishes,
Konstantina
the Telerik team
Browse the videos here>> to help you get started with RadControls for WPF
0
Patrick
Top achievements
Rank 1
answered on 08 Apr 2011, 01:38 PM
Hi,

I have the same issue. Are you able to provide some actual sample code?

Thanks heaps.
0
Konstantina
Telerik team
answered on 11 Apr 2011, 03:23 PM
Hi Patrick,

If we use the code which Etienne pasted the method for removing the animation should look like:

public void DisableDockingAnimations() 
     AnimationManager.SetAnimationSelector(dockingControl, null); 
}

Hope this will help. Please let us know if you have further questions.

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
0
Patrick
Top achievements
Rank 1
answered on 12 Apr 2011, 04:18 AM
Hi,

I am executing the following line of code as your sugguested where dockingControl is of type RadDocking. I then add my RadPanes via code but they still popout and collapse when they are added.

Can you please confirm that dockingControl should be of type RadDocking?

Do you have any other sugguestions for making this work?

Source Code:
AnimationManager.SetAnimationSelector(dockingControl, null); 

Thanks heaps.
0
Konstantina
Telerik team
answered on 14 Apr 2011, 10:33 AM
Hello Patrick,

Yes, the dockingControl is of type RadDocking. Regrettably, this is the best that can be achieved for now. We are aware of the issue and we have logged it in PITS. You can view it here. You can vote for it, track its status and see when it is going to be implemented.

Greetings,
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
0
Tim
Top achievements
Rank 1
answered on 23 Feb 2017, 07:47 AM

Hi,

The PITS link doesn't work any more.

Has this been solved?

0
Georgi
Telerik team
answered on 24 Feb 2017, 06:55 AM
Hello Ivo,

We are sorry for the inconvenience caused. Indeed the PITS system is obsoleted and for better experience we have migrated to the FeedBackPortal.

Nevertheless the issue for the flickering of unpinned panes on startup is fixed and the fix is available in the 2012 Q2 SP1 release, as for reference you can check the release notes here (look for the "Initial animation of Unpinned panes is disabled (when the pane has its IsPinned property set to false)" item).

Hope this would help. Also if you are experiencing the same issue with later release or have any other questions or concerns, please don't hesitate to write us.

Regards,
Georgi
Telerik by Progress
Want to extend the target reach of your WPF applications, leveraging iOS, Android, and UWP? Try UI for Xamarin, a suite of polished and feature-rich components for the Xamarin framework, which allow you to write beautiful native mobile apps using a single shared C# codebase.
Tags
Docking
Asked by
silver
Top achievements
Rank 1
Answers by
Konstantina
Telerik team
EM
Top achievements
Rank 1
Patrick
Top achievements
Rank 1
Tim
Top achievements
Rank 1
Georgi
Telerik team
Share this question
or