123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960 |
- //
- // KMBOTAManagerClass.swift
- // PDF Master
- //
- // Created by lxy on 2022/11/15.
- //
- import Cocoa
- let thumbnailMethodKey = "KMThumbnailMethodKey"
- let outlineMethodKey = "KMOutlineMethoddKey"
- let bookMarkMethodKey = "KMBookMarkMethodKey"
- let anntationMethodKey = "KMAnntationMethodKey"
- let searchMethodKey = "KMSearchMethodKey"
- let formMethodKey = "KMFormMethodKey"
- let signatureMethodKey = "KMSignatureMethodKey"
- class KMBOTAManagerClass: NSObject {
- static let shard = KMBOTAManagerClass()
- var thumbnailMethod = true
- var outlineMethod = true
- var bookMarkMethod = true
- var anntationMethod = true
- var searchMethod = true
- var formMethod = false
- var signatureMethod = false
-
- private override init() {
- super.init()
- }
-
- override func copy() -> Any {
- return self
- }
-
- override func mutableCopy() -> Any {
- return self
- }
-
- func getMethodShow(key:String) -> Bool {
- if UserDefaults.standard.object(forKey:key) != nil {
- let value = UserDefaults.standard.bool(forKey: key)
- return value
- } else {
- if key == formMethodKey || key == signatureMethodKey {
- return false
- }
- return true
- }
- }
-
- func setLeftMethod(show:Bool, key:String) {
- UserDefaults.standard.set(show, forKey: key)
- UserDefaults.standard.synchronize()
- }
-
-
- }
|