【发布时间】:2012-01-30 08:39:48
【问题描述】:
在每个 iOS 应用程序中都有一个 App Delegate 类,这意味着应用程序中的一个类必须实现应用程序事件的委托方法,例如 didFinishLaunching: 等等。通常类名中包含“AppDelegate”。
App Delegate 类是 iOS 上 UIApplicationDelegate 或 Mac 上 NSApplicationDelegate 的子类。
class AppDelegate: UIApplicationDelegate {
}
假设我想在与为我创建和命名的原始 Xcode 不同的类中实现 App Delegate 方法。我该怎么做?
【问题讨论】: