Преглед на файлове

Merge branch 'develop' of git.kdan.cc:Mac_PDF/PDF_Office into develop

tangchao преди 1 година
родител
ревизия
794a46e83c
променени са 1 файла, в които са добавени 5 реда и са изтрити 3 реда
  1. 5 3
      PDF Office/PDF Office/Class/PDFWindowController/Side/LeftSide/ViewPanel/KMPDFViewPanelSetViewController.swift

+ 5 - 3
PDF Office/PDF Office/Class/PDFWindowController/Side/LeftSide/ViewPanel/KMPDFViewPanelSetViewController.swift

@@ -242,9 +242,11 @@ class KMPDFViewPanelSetViewController: NSViewController {
     }
     
     @objc func displayModeChangedNotification(_ notification: Notification) -> Void {
-        let pdfview = notification.object as! CPDFListView
-        if(pdfview.document == self.listView?.document) {
-            self.reloadListViewModel()
+        if notification.object is CPDFListView {
+            let pdfview = notification.object as! CPDFListView
+            if(pdfview.document == self.listView?.document) {
+                self.reloadListViewModel()
+            }
         }
     }
 }