浏览代码

ComPDFKit.Demo(win) - 调整CPDFViewer的IsRendering判断处理

TangJinZhou 1 周之前
父节点
当前提交
5238d28c32
共有 1 个文件被更改,包括 5 次插入4 次删除
  1. 5 4
      Demo/Examples/Compdfkit.Controls/PDFView/PDFViewControl/PDFViewControl.xaml.cs

+ 5 - 4
Demo/Examples/Compdfkit.Controls/PDFView/PDFViewControl/PDFViewControl.xaml.cs

@@ -125,7 +125,7 @@ namespace ComPDFKit.Controls.PDFControl
 
         private void PDFViewControl_OnRenderFinish(object sender, EventArgs e)
         {
-           SetCursorStatus();
+            SetCursorStatus();
         }
 
         private void PDFViewTool_DrawChanged(object sender, EventArgs e)
@@ -689,7 +689,6 @@ namespace ComPDFKit.Controls.PDFControl
                     }
                 }
 
-
                 if (currentMode == ToolType.CreateAnnot)
                 {
                     List<C_ANNOTATION_TYPE> annotTypes = new List<C_ANNOTATION_TYPE>
@@ -713,6 +712,7 @@ namespace ComPDFKit.Controls.PDFControl
                     }
                 }
             }
+
             GetCPDFViewer().Cursor = newCursor;
         }
 
@@ -720,8 +720,9 @@ namespace ComPDFKit.Controls.PDFControl
         {
             if (GetCPDFViewer().IsRendering)
             {
-               GetCPDFViewer().Cursor = Cursors.Wait;
-               return;
+                GetCPDFViewer().Cursor = Cursors.Wait;
+                FocusPDFViewTool.ContextMenu?.Items.Clear();
+                return;
             }
 
             if (isAutomaticScroll)