Browse Source

ComPDFKit.Tool(win) - 修复Viewer模式点击超链接不跳转的问题

TangJinZhou 4 months ago
parent
commit
ce4f6ee781
1 changed files with 6 additions and 2 deletions
  1. 6 2
      Demo/Examples/ComPDFKit.Tool/CPDFViewerTool.xaml.cs

+ 6 - 2
Demo/Examples/ComPDFKit.Tool/CPDFViewerTool.xaml.cs

@@ -1,5 +1,4 @@
-using ComPDFKit.Import;
-using ComPDFKit.PDFAnnotation;
+using ComPDFKit.PDFAnnotation;
 using ComPDFKit.PDFDocument;
 using ComPDFKit.PDFDocument.Action;
 using ComPDFKit.PDFPage;
@@ -455,6 +454,11 @@ namespace ComPDFKit.Tool
             }
             else if ((currentModel == ToolType.Pan || currentModel == ToolType.Viewer))
             {
+                if (AnnotHitTest() && cacheHitTestAnnot.CurrentType == C_ANNOTATION_TYPE.C_ANNOTATION_LINK)
+                {
+                    LinkAnnotAction(cacheHitTestAnnot);
+                }
+
                 if (DrawDownSelectImage(true))
                 {
                     mouseEventObject.hitTestType = MouseHitTestType.ImageSelect;