开发者

Callback for when a UIWebView is closed in iOS SDK

In my app, I load a开发者_如何学JAVA WebView and then from that load another in an embedded browser. I would like to execute a function on the first WebView when the user closes the embedded browser. Anyone know how I can achieve this? What I need ideally (and believe does not exist) is a callback function when a user closes an embedded browser.

Thanks, Neha.


Basic concept is listed below

// set up notification for when embedded browser is closed
[[NSNotificationCenter defaultCenter] addObserver:self 
          selector:@selector(myMethod) 
          name:@"embeddedBrowserClosed" object:nil];

// post notification when browser is closed
[[NSNotificationCenter defaultCenter] 
          postNotificationName:@"embeddedBrowserClosed"]

See more here at this Blog Posting

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜