|
@@ -122,7 +122,7 @@ import Cocoa
|
|
|
var mwcFlags: MwcFlags = MwcFlags()
|
|
|
var document: CPDFDocument?
|
|
|
var myDocument: NSDocument?
|
|
|
- weak var browserWindowController: KMBrowserWindowController?
|
|
|
+ weak var browserWindowController: KMBrowserWindowController? //慎直接使用这个方法
|
|
|
|
|
|
var cropSettingWindowController: KMCropSettingWindowController!
|
|
|
var currentWindowController: NSWindowController!
|
|
@@ -1969,7 +1969,9 @@ import Cocoa
|
|
|
if event.keyCode == 53 {
|
|
|
if let data = self?.interactionMode, data == .presentation { // 幻灯片模式下
|
|
|
if let data = self?.canExitPresentation(), data {
|
|
|
- self?.browserWindowController?.exitFullscreen()
|
|
|
+ let mainDocument = self?.myDocument as? KMMainDocument
|
|
|
+ let browserWindowController = mainDocument?.browser?.windowController as? KMBrowserWindowController
|
|
|
+ browserWindowController?.exitFullscreen()
|
|
|
}
|
|
|
return nil
|
|
|
}
|