浏览代码

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

tangchao 11 月之前
父节点
当前提交
15b87ded5e
共有 1 个文件被更改,包括 3 次插入0 次删除
  1. 3 0
      PDF Office/PDF Master/AppDelegate.swift

+ 3 - 0
PDF Office/PDF Master/AppDelegate.swift

@@ -780,6 +780,9 @@ extension AppDelegate : NSMenuDelegate,NSMenuItemValidation {
         }
         if action == #selector(closeDocument) {
             guard let _windowC = NSApp.mainWindow?.windowController as? KMBrowserWindowController else {
+                if NSApp.mainWindow?.windowController != nil {
+                    return true
+                }
                 return false
             }
             let isNewTab = _windowC.browser?.activeTabContents()?.isNewTab ?? false