我使用Xcode 6和swift语言创建了一个示例项目.
Xcode使用以下代码创建了AppDelegate.swift
import Cocoa
@NSApplicationMain
class AppDelegate: NSObject, NSApplicationDelegate {
func applicationDidFinishLaunching(aNotification: NSNotification) {
// Insert code here to initialize your application
}
func applicationWillTerminate(aNotification: NSNotification) {
// Insert code here to tear down your application
}
}
Run Code Online (Sandbox Code Playgroud)
@NSApplicationMain是什么意思,我的main.mm/main.m文件在main()的哪个位置?