Browse Source

【编辑】进入添加图片模式,点击图片后再点击空白区域,导入图片-取消导入,此时图片取消选中,属性面板应该自动隐藏

lizhe 1 year ago
parent
commit
78ab1ea3c5

+ 4 - 2
PDF Office/PDF Master/Class/PDFWindowController/ViewController/KMMainViewController+UI.swift

@@ -84,7 +84,9 @@ extension KMMainViewController: KMToolbarControllerDelegate {
             self.heightOffset.constant = CGFloat(heightOffset)
         }
         self.refreshListViewToolMode()
-        if self.listView.annotationType == .editTextImage {
+        if self.listView.annotationType == .editTextImage ||
+            self.listView.annotationType == .addText ||
+            self.listView.annotationType == .addImage {
             self.closeRightPane()
         }
         self.listView.annotationType = .unkown
@@ -173,7 +175,7 @@ extension KMMainViewController: KMToolbarControllerDelegate {
                 self.rightSideViewController.isHidden = true
                 self.listView.setShouAddEdit([])
                 self.listView.change([.text, .image])
-                self.listView.annotationType = .unkown
+                self.listView.annotationType = .editTextImage
                 self.closeRightPane()
             } else if self.listView.annotationType == .addText {
 //                self.rightSideViewController.view.isHidden = false