Kaynağa Gözat

【fix】【内容编辑】显示悬浮菜单时,切换到工具模块,悬浮菜单未消失

tangchao 7 ay önce
ebeveyn
işleme
e2223a11c2

+ 3 - 1
PDF Office/PDF Master/Class/PDFWindowController/ViewController/KMMainViewController+Action.swift

@@ -3576,7 +3576,9 @@ extension KMMainViewController : KMMainToolbarControllerDelegate {
     }
     
     func mainToolDidClicked(_ toolController: KMToolbarController, _ beforeType: KMToolbarViewType, _ type: KMToolbarViewType, _ item: KMToolbarItemView , _ pages: [Int]) {
-        if beforeType == .editPDF {}
+        if beforeType == .editPDF {
+            self.editPDFHanddler.enterEditPDF()
+        }
         
         if(type != .Page) {
             if (hasEnterPageEdit()) {

+ 3 - 0
PDF Office/PDF Master/Class/PDFWindowController/ViewController/KMMainViewController.swift

@@ -1198,6 +1198,9 @@ import Cocoa
                 self.exitDigitalSign()
             }
         }
+        if toolbarItem.itemIdentifier != KMDocumentEditToolbarItemIdentifier {
+            self.editPDFHanddler.clearData()
+        }
     }
     
     // MARK: - Private Methods