我有以下问题:
当我将c#+ xaml页面的方向从横向更改为纵向或反之亦然时,用户可以在重新计算和重新呈现布局之前在屏幕上看到大的蓝色部分.这些斑点看起来像是前一个定位状态的残羹剩饭.
我正在寻找一种方法来隐藏或平滑这种极其粗糙和颠簸的过渡.
我尝试使用ProgressRing添加一个方向更改处理程序来覆盖它1秒钟,但它没有帮助 - 处理程序在蓝点之后执行.这是我的动画StoryBoard的代码
<!-- The entire page respects the narrower 100-pixel margin convention for portrait -->
<VisualState x:Name="FullScreenPortrait">
<Storyboard>
<!-- Change the back button and the logo -->
<ObjectAnimationUsingKeyFrames Storyboard.TargetName="backButton" Storyboard.TargetProperty="Style">
<DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource PortraitBackButtonStyle}"/>
</ObjectAnimationUsingKeyFrames>
<ObjectAnimationUsingKeyFrames Storyboard.TargetName="headerLogoImage" Storyboard.TargetProperty="Width">
<DiscreteObjectKeyFrame KeyTime="0" Value="430"/>
</ObjectAnimationUsingKeyFrames>
<ObjectAnimationUsingKeyFrames Storyboard.TargetName="headerLogoImage" Storyboard.TargetProperty="Height">
<DiscreteObjectKeyFrame KeyTime="0" Value="49"/>
</ObjectAnimationUsingKeyFrames>
<!--Change section title and navButtons to be in two rows, by moving navButtons to the second row, first column-->
<ObjectAnimationUsingKeyFrames Storyboard.TargetName="navButtons" Storyboard.TargetProperty="(Grid.Row)">
<DiscreteObjectKeyFrame KeyTime="0" Value="1"/>
</ObjectAnimationUsingKeyFrames> …Run Code Online (Sandbox Code Playgroud)