Integrate高德 SDK with simulator-safe build flags, add map views for operating area and punch points, refactor main tabs and key feature screens to UIKit with Diffable lists, and document Swift concurrency defaults in AGENTS.md. Co-authored-by: Cursor <cursoragent@cursor.com>
51 lines
1.4 KiB
Swift
51 lines
1.4 KiB
Swift
//
|
||
// SceneDelegate.swift
|
||
// suixinkan_ios
|
||
//
|
||
// Created by hanqiu on 2026/6/26.
|
||
//
|
||
|
||
import UIKit
|
||
|
||
/// 窗口 Scene 代理,负责创建根窗口并挂载 `RootViewController`。
|
||
class SceneDelegate: UIResponder, UIWindowSceneDelegate {
|
||
|
||
var window: UIWindow?
|
||
|
||
/// Scene 连接时初始化窗口、重置 UI 测试状态并展示根控制器。
|
||
func scene(
|
||
_ scene: UIScene,
|
||
willConnectTo session: UISceneSession,
|
||
options connectionOptions: UIScene.ConnectionOptions
|
||
) {
|
||
guard let windowScene = scene as? UIWindowScene else { return }
|
||
|
||
AppUITestLaunchState.resetIfNeeded()
|
||
|
||
let window = UIWindow(windowScene: windowScene)
|
||
window.rootViewController = RootViewController()
|
||
window.makeKeyAndVisible()
|
||
self.window = window
|
||
}
|
||
|
||
/// Scene 断开连接,当前无额外资源释放。
|
||
func sceneDidDisconnect(_ scene: UIScene) {
|
||
}
|
||
|
||
/// Scene 进入活跃态,当前无额外处理。
|
||
func sceneDidBecomeActive(_ scene: UIScene) {
|
||
}
|
||
|
||
/// Scene 即将失活,当前无额外处理。
|
||
func sceneWillResignActive(_ scene: UIScene) {
|
||
}
|
||
|
||
/// Scene 即将进入前台,当前无额外处理。
|
||
func sceneWillEnterForeground(_ scene: UIScene) {
|
||
}
|
||
|
||
/// Scene 进入后台,当前无额外处理。
|
||
func sceneDidEnterBackground(_ scene: UIScene) {
|
||
}
|
||
}
|