当鼠标在按钮上时,我有简单的 WPF 按钮动画来更改 Width 属性:
<Button Width="100" Height="60" Content="Click Me" x:Name="Button1">
<Button.Triggers>
<EventTrigger RoutedEvent="MouseEnter">
<BeginStoryboard>
<Storyboard>
<DoubleAnimation Storyboard.TargetProperty="Width" To="200" Duration="0:0:0:1" ></DoubleAnimation>
</Storyboard>
</BeginStoryboard>
</EventTrigger>
</Button.Triggers>
</Button>
但是在动画之后,宽度应该回到“60”。怎么做?