Re: So... we can't use UIWebView (with a delegate) on a page that's pushed onto a UINavigationController stack?
Re: So... we can't use UIWebView (with a delegate) on a page that's pushed onto a UINavigationController stack?
- Subject: Re: So... we can't use UIWebView (with a delegate) on a page that's pushed onto a UINavigationController stack?
- From: Jens Alfke <email@hidden>
- Date: Thu, 16 Jun 2011 19:26:31 -0700
On Jun 16, 2011, at 7:15 PM, G S wrote:
> The delegate for the UIWebView is set up in the XIB file; it's pretty
> hokey to have to intervene in code to then disassociate the view from
> its delegate.
If the delegate object is being dealloced, it needs to clear the delegate reference to it. I don’t see this as hokey (well, any more hokey than ref-counting in general.)
> Does anyone know if I'm interpreting this situation correctly? I
> guess the workaround is to set the UIWebView's delegate property to
> nil in the UIWebView owner's "viewWillDisappear" method or something.
I’m not sure exactly what you mean, but I think you’re on the right track. If some other object knows that the delegate is going to be dealloced, it can clear the delegate property on the webview for it.
—Jens
Attachment:
smime.p7s
Description: S/MIME cryptographic signature
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden