fix:issue #111
This commit is contained in:
@@ -1325,7 +1325,14 @@ namespace Ink_Canvas {
|
|||||||
|
|
||||||
if (currentMode != 0) {
|
if (currentMode != 0) {
|
||||||
SaveStrokes();
|
SaveStrokes();
|
||||||
RestoreStrokes(true);
|
// 检查是否在PPT放映模式,如果不在则不恢复可能包含PPT墨迹的备份
|
||||||
|
if (BtnPPTSlideShowEnd.Visibility == Visibility.Visible) {
|
||||||
|
RestoreStrokes(true);
|
||||||
|
} else {
|
||||||
|
// 不在PPT模式时,清空备份以避免显示已结束PPT的墨迹
|
||||||
|
TimeMachineHistories[0] = null;
|
||||||
|
timeMachine.ClearStrokeHistory();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (BtnSwitchTheme.Content.ToString() == "浅色")
|
if (BtnSwitchTheme.Content.ToString() == "浅色")
|
||||||
@@ -1779,7 +1786,17 @@ namespace Ink_Canvas {
|
|||||||
|
|
||||||
SaveStrokes(true);
|
SaveStrokes(true);
|
||||||
ClearStrokes(true);
|
ClearStrokes(true);
|
||||||
RestoreStrokes();
|
|
||||||
|
// 检查是否在PPT放映模式,如果不在则不恢复可能包含PPT墨迹的备份
|
||||||
|
if (BtnPPTSlideShowEnd.Visibility == Visibility.Visible) {
|
||||||
|
LogHelper.WriteLogToFile("退出白板:当前在PPT放映模式,恢复备份墨迹", LogHelper.LogType.Trace);
|
||||||
|
RestoreStrokes();
|
||||||
|
} else {
|
||||||
|
// 不在PPT模式时,清空备份以避免显示已结束PPT的墨迹
|
||||||
|
LogHelper.WriteLogToFile("退出白板:当前不在PPT放映模式,清空备份以避免显示已结束PPT的墨迹", LogHelper.LogType.Trace);
|
||||||
|
TimeMachineHistories[0] = null;
|
||||||
|
timeMachine.ClearStrokeHistory();
|
||||||
|
}
|
||||||
|
|
||||||
// 退出白板时清空图片
|
// 退出白板时清空图片
|
||||||
inkCanvas.Children.Clear();
|
inkCanvas.Children.Clear();
|
||||||
@@ -1820,7 +1837,15 @@ namespace Ink_Canvas {
|
|||||||
|
|
||||||
SaveStrokes();
|
SaveStrokes();
|
||||||
ClearStrokes(true);
|
ClearStrokes(true);
|
||||||
RestoreStrokes(true);
|
|
||||||
|
// 检查是否在PPT放映模式,如果不在则不恢复可能包含PPT墨迹的备份
|
||||||
|
if (BtnPPTSlideShowEnd.Visibility == Visibility.Visible) {
|
||||||
|
RestoreStrokes(true);
|
||||||
|
} else {
|
||||||
|
// 不在PPT模式时,清空备份以避免显示已结束PPT的墨迹
|
||||||
|
TimeMachineHistories[0] = null;
|
||||||
|
timeMachine.ClearStrokeHistory();
|
||||||
|
}
|
||||||
|
|
||||||
// 退出白板时清空图片
|
// 退出白板时清空图片
|
||||||
inkCanvas.Children.Clear();
|
inkCanvas.Children.Clear();
|
||||||
@@ -1857,7 +1882,15 @@ namespace Ink_Canvas {
|
|||||||
|
|
||||||
SaveStrokes(true);
|
SaveStrokes(true);
|
||||||
ClearStrokes(true);
|
ClearStrokes(true);
|
||||||
RestoreStrokes();
|
|
||||||
|
// 检查是否在PPT放映模式,如果不在则不恢复可能包含PPT墨迹的备份
|
||||||
|
if (BtnPPTSlideShowEnd.Visibility == Visibility.Visible) {
|
||||||
|
RestoreStrokes();
|
||||||
|
} else {
|
||||||
|
// 不在PPT模式时,清空备份以避免显示已结束PPT的墨迹
|
||||||
|
TimeMachineHistories[0] = null;
|
||||||
|
timeMachine.ClearStrokeHistory();
|
||||||
|
}
|
||||||
|
|
||||||
BtnSwitch.Content = "屏幕";
|
BtnSwitch.Content = "屏幕";
|
||||||
if (BtnSwitchTheme.Content.ToString() == "浅色") {
|
if (BtnSwitchTheme.Content.ToString() == "浅色") {
|
||||||
|
|||||||
@@ -918,6 +918,9 @@ namespace Ink_Canvas {
|
|||||||
|
|
||||||
ClearStrokes(true);
|
ClearStrokes(true);
|
||||||
|
|
||||||
|
// 清空备份历史记录,防止退出白板时恢复已结束PPT的墨迹
|
||||||
|
TimeMachineHistories[0] = null;
|
||||||
|
|
||||||
if (GridTransparencyFakeBackground.Background != Brushes.Transparent)
|
if (GridTransparencyFakeBackground.Background != Brushes.Transparent)
|
||||||
BtnHideInkCanvas_Click(BtnHideInkCanvas, null);
|
BtnHideInkCanvas_Click(BtnHideInkCanvas, null);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user