浏览代码

【右侧面板】高亮注释修改属性不刷新问题修复

lizhe 1 月之前
父节点
当前提交
2c33df0987

+ 6 - 0
PDF Office/PDF Master/Class/PDFWindowController/Side/RightSide/AnnotationProperty/KMGeneralAnnotationViewController.swift

@@ -1716,6 +1716,9 @@ let KMColorPickerViewHeight: CGFloat = 64
                     opacity = annotationModel?.opacity() ?? 1
 //                    annotationModel?.setOpacity(opacity)
                     annotationModel?.setColor(textColor)
+                    if (annotationType == .highlight) {
+                        pdfView?.updateHighLightAnnotation(annotationModel?.annotation)
+                    }
                     if let model = self.annotationModel {
                         if (model.annotation == nil || CPDFListViewConfig.defaultManager.isSaveDefault) && self.isannotationMode {
                             if self.annotationType.isMarkup() {
@@ -1856,6 +1859,9 @@ let KMColorPickerViewHeight: CGFloat = 64
         } else {
             annotationModel?.setOpacity(opcity)
         }
+        if (annotationType == .highlight) {
+            pdfView?.updateHighLightAnnotation(annotationModel?.annotation)
+        }
         opacityComboBox.stringValue = "\(Int(opcity * 100))%"
         updateAnnotation(.opacity)