improve:白板翻页性能
This commit is contained in:
@@ -512,11 +512,19 @@ namespace Ink_Canvas
|
||||
if (pageIndex == CurrentWhiteboardIndex)
|
||||
{
|
||||
ClearStrokes(true);
|
||||
if (CurrentWhiteboardIndex != WhiteboardTotalCount)
|
||||
for (var i = CurrentWhiteboardIndex; i <= WhiteboardTotalCount; i++)
|
||||
|
||||
var oldTotal = WhiteboardTotalCount;
|
||||
if (CurrentWhiteboardIndex != oldTotal)
|
||||
{
|
||||
for (var i = CurrentWhiteboardIndex; i < oldTotal; i++)
|
||||
TimeMachineHistories[i] = TimeMachineHistories[i + 1];
|
||||
}
|
||||
else
|
||||
{
|
||||
CurrentWhiteboardIndex--;
|
||||
}
|
||||
|
||||
TimeMachineHistories[oldTotal] = null;
|
||||
WhiteboardTotalCount--;
|
||||
RestoreStrokes();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user