New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expander fix closing animation #2769

Merged
merged 4 commits into from Dec 18, 2016

Conversation

Projects
None yet
2 participants
@Anapher
Contributor

Anapher commented Dec 17, 2016

Fix the closing animation of the expander, it was not executed because the expander was directly collapsed. The closing animation duration was also made smaller because 250 ms was too long (changed to 100 ms, better in my feeling).

Alkalinee and others added some commits Aug 5, 2016

Alkalinee Alkalinee
Fix Expander closing animation
Fix the closing animation of the expander, it was not executed because
the expander was directly collapsed. The closing animation duration was
also made smaller because 250 ms was too long (in my feeling)

@punker76 punker76 added this to the 1.4.0 milestone Dec 18, 2016

@punker76 punker76 merged commit 9f6799e into MahApps:develop Dec 18, 2016

1 check passed

continuous-integration/teamcity Finished TeamCity Build MahApps.Metro PullRequest :: MahApps.Metro PullRequests : Tests passed: 62
Details
@punker76

This comment has been minimized.

Show comment
Hide comment
@punker76

punker76 Dec 18, 2016

Member

@Alkalinee Thx! I revert the duration for the collapse animation to 250. But you can simply change it now by yourself in your app like this

<!--  quick change of the collapse storyboard duration  -->
<Storyboard x:Key="MetroExpanderCollapseStoryboard">
    <DoubleAnimation Duration="0:0:0.1"
                        Storyboard.TargetName="ExpandSite"
                        Storyboard.TargetProperty="(UIElement.Opacity)"
                        To="0" />
    <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ExpandSite" Storyboard.TargetProperty="(UIElement.Visibility)">
        <DiscreteObjectKeyFrame KeyTime="0:0:0.1" Value="{x:Static Visibility.Collapsed}" />
    </ObjectAnimationUsingKeyFrames>
</Storyboard>
Member

punker76 commented Dec 18, 2016

@Alkalinee Thx! I revert the duration for the collapse animation to 250. But you can simply change it now by yourself in your app like this

<!--  quick change of the collapse storyboard duration  -->
<Storyboard x:Key="MetroExpanderCollapseStoryboard">
    <DoubleAnimation Duration="0:0:0.1"
                        Storyboard.TargetName="ExpandSite"
                        Storyboard.TargetProperty="(UIElement.Opacity)"
                        To="0" />
    <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ExpandSite" Storyboard.TargetProperty="(UIElement.Visibility)">
        <DiscreteObjectKeyFrame KeyTime="0:0:0.1" Value="{x:Static Visibility.Collapsed}" />
    </ObjectAnimationUsingKeyFrames>
</Storyboard>
@punker76

This comment has been minimized.

Show comment
Hide comment
@punker76

punker76 Dec 22, 2016

Member

@Alkalinee I revert the dynamic resource search for the Storyboard, cause if you don't put the MahApps resources to the App.xaml you will get a XamlParseException. So for now it's not so easy to change the duration for this Storyboard. I'll investigate for next releases what we can do...

Member

punker76 commented Dec 22, 2016

@Alkalinee I revert the dynamic resource search for the Storyboard, cause if you don't put the MahApps resources to the App.xaml you will get a XamlParseException. So for now it's not so easy to change the duration for this Storyboard. I'll investigate for next releases what we can do...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment