// // AppDelegate+OpenApp.swift // MoviaBox // // Created by 佳尔 on 2025/4/25. // import UIKit #if canImport(FacebookCore) import FacebookCore #endif extension SceneDelegate { ///URL打开APP func scene(_ scene: UIScene, openURLContexts URLContexts: Set) { guard let url = URLContexts.first?.url else { return } #if canImport(FacebookCore) ApplicationDelegate.shared.application(UIApplication.shared, open: url, sourceApplication: nil, annotation: [UIApplication.OpenURLOptionsKey.annotation]) #endif } ///UniversalLink 打开app func scene(_ scene: UIScene, continue userActivity: NSUserActivity) { guard let webpageURL = userActivity.webpageURL else { return } guard let query = webpageURL.query else { return } spLog(message: query) } }