Explorar o código

【fix】快捷键关闭标签,兼容在有窗口弹起的场景

tangchao hai 7 meses
pai
achega
dca811c32f
Modificáronse 1 ficheiros con 4 adicións e 0 borrados
  1. 4 0
      PDF Office/PDF Master/AppDelegate.swift

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

@@ -344,6 +344,10 @@ class AppDelegate: NSObject, NSApplicationDelegate, iRateDelegate{
             if browser.tabCount() == 1 {
                 windowControler?.window?.close()
             } else {
+                if let _ = windowControler?.window?.attachedSheet {
+                    NSSound.beep()
+                    return
+                }
                 browser.closeTab()
             }
         } else {