improve:PPT翻页打断
改进打断逻辑
This commit is contained in:
@@ -744,41 +744,40 @@ namespace Ink_Canvas.Helpers
|
||||
{
|
||||
}
|
||||
|
||||
try
|
||||
if (skipAnimations && currentPosition > 0 && totalSlides > 0 && currentPosition < totalSlides)
|
||||
{
|
||||
view.Next();
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
LogHelper.WriteLogToFile($"调用下一页失败: {ex}", LogHelper.LogType.Warning);
|
||||
}
|
||||
|
||||
if (skipAnimations && currentPosition > 0 && totalSlides > 0)
|
||||
{
|
||||
int positionAfterNext = currentPosition;
|
||||
try
|
||||
{
|
||||
positionAfterNext = view.CurrentShowPosition;
|
||||
view.GotoSlide(currentPosition + 1, MsoTriState.msoFalse);
|
||||
return true;
|
||||
}
|
||||
catch
|
||||
{
|
||||
}
|
||||
|
||||
if (positionAfterNext == currentPosition && currentPosition < totalSlides)
|
||||
catch (Exception ex)
|
||||
{
|
||||
LogHelper.WriteLogToFile($"跳过转场动画跳转到下一页失败: {ex}", LogHelper.LogType.Warning);
|
||||
try
|
||||
{
|
||||
view.GotoSlide(currentPosition + 1, MsoTriState.msoTrue);
|
||||
view.Next();
|
||||
return true;
|
||||
}
|
||||
catch (Exception ex)
|
||||
catch
|
||||
{
|
||||
LogHelper.WriteLogToFile($"强制跳转到下一页失败: {ex}", LogHelper.LogType.Warning);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
else
|
||||
{
|
||||
try
|
||||
{
|
||||
view.Next();
|
||||
return true;
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
LogHelper.WriteLogToFile($"调用下一页失败: {ex}", LogHelper.LogType.Warning);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -1946,7 +1946,7 @@
|
||||
TextWrapping="Wrap" Foreground="#a1a1aa" />
|
||||
<ui:SimpleStackPanel Orientation="Horizontal"
|
||||
HorizontalAlignment="Left" Margin="0,6,0,0">
|
||||
<TextBlock Foreground="#fafafa" Text="点击翻页时跳过当前页动画,直接切到下一张"
|
||||
<TextBlock Foreground="#fafafa" Text="点击翻页时跳过转场动画,直接切到下一张"
|
||||
VerticalAlignment="Center" FontSize="14" Margin="0,0,16,0" />
|
||||
<ui:ToggleSwitch OnContent="" OffContent=""
|
||||
Name="ToggleSwitchSkipAnimationsWhenGoNext"
|
||||
@@ -1955,7 +1955,7 @@
|
||||
Toggled="ToggleSwitchSkipAnimationsWhenGoNext_OnToggled" />
|
||||
</ui:SimpleStackPanel>
|
||||
<TextBlock
|
||||
Text="# 开启该选项后,点击“下一页”按钮时如果仍停留在同一页,会强制直接切到下一张幻灯片,从而跳过该页的动画。"
|
||||
Text="# 开启该选项后,点击下一页按钮时会跳过幻灯片之间的转场动画,直接跳转到下一张幻灯片。不会影响幻灯片内的元素动画。"
|
||||
TextWrapping="Wrap" Foreground="#a1a1aa" />
|
||||
</ui:SimpleStackPanel>
|
||||
<Line HorizontalAlignment="Center" X1="0" Y1="0" X2="400" Y2="0" Stroke="#3f3f46"
|
||||
|
||||
Reference in New Issue
Block a user