First set the WebView policy WebView and your start URL as a class variable:
let url = NSURL(string: "http://www.google.com/")!
Then override delegate methods to intercept navigation.
override func webView(webView: WebView!, decidePolicyForNewWindowAction actionInformation: [NSObject : AnyObject]!, request: NSURLRequest!, newFrameName frameName: String!, decisionListener listener: WebPolicyDecisionListener!) { println(__LINE__)
source share