Progress Bar in Cocoa
问题 I have a very simple application that contains a WebView. This webview loads an HTML5 app and it takes some time while the content is being built inside the webview. I would like to show a progress bar until the content finishes loading and show the webview when the content is ready. It takes roughly 10 seconds. ?? 回答1: Swift 2.2 override func viewDidLoad() { super.viewDidLoad() webView.frameLoadDelegate = self webView.addObserver(self, forKeyPath: "estimatedProgress", options: .New, context: