|
@@ -113,14 +113,29 @@ class AppDelegate: NSObject, NSApplicationDelegate {
|
|
|
print("Received URL Scheme: \(url.scheme ?? "")")
|
|
|
print("Path: \(url.path)")
|
|
|
|
|
|
+ #if VERSION_DMG
|
|
|
// 执行相应的操作
|
|
|
- if url.scheme == "myapp" {
|
|
|
+ if url.scheme == "pdfmaster_DMG" {
|
|
|
+ KMPurchaseManager.manager.restorePurchases()
|
|
|
if url.path == "/open" {
|
|
|
// 执行打开操作
|
|
|
} else if url.path == "/close" {
|
|
|
// 执行关闭操作
|
|
|
}
|
|
|
}
|
|
|
+ #endif
|
|
|
+
|
|
|
+ #if VERSION_FREE
|
|
|
+ // 执行相应的操作
|
|
|
+ if url.scheme == "pdfmaster" {
|
|
|
+ KMPurchaseManager.manager.restorePurchases()
|
|
|
+ if url.path == "/open" {
|
|
|
+ // 执行打开操作
|
|
|
+ } else if url.path == "/close" {
|
|
|
+ // 执行关闭操作
|
|
|
+ }
|
|
|
+ }
|
|
|
+ #endif
|
|
|
}
|
|
|
}
|
|
|
|