You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jun 2, 2018. It is now read-only.
First, great library, Zachary (and Alexsander); it's really a fantastic contribution and much appreciated.
Yesterday I discovered that the view controllers in a navigation stack presented modally were not being deallocated upon dismissal. After the requisite hair-pulling and self-accusations, it looks as though the culprit may instead be UIWebViews that use UIWebView+BlocksKit.
One view controller modally presents a second view controller with an embedded UIWebView with a didFinishLoadBock. The second view controller will not be deallocated when it is dismissed. You can see this when profiling with the Allocations Instrument. However, if the UIWebView's delegate is not set, deallocation works as expected (of course, the didFinishLoadBlock isn't called). See the comments in SecondViewController.m for more details. As far as I can tell, this happens on both the device and simulator from iOS4.2 through 5.1. The example uses v1.0.6a of the static lib on the downloads page.
I haven't had a chance to look at the underlying BlocksKit and A2DynamicDelegate code yet, but I thought you might have some insight. Meanwhile, I'm (sadly) ripping out BlocksKit from my project until I can get a handle on this.
With any luck, it's simply my own oversight or misuse of the library. (And, if so, I hope someone can set me straight!).
The text was updated successfully, but these errors were encountered:
That is quite the nasty retain cycle. It's already fixed in BlocksKit/A2DD
trunk. We'll be releasing them both as 2.0 version(s) shortly. Sorry for
any inconvenience, I hope you're able to use BlocksKit again soon enough.
Thanks so much! The documentation and sample code is greatly appreciated.
Excellent! I'm glad it was helpful, and thanks for acting on the bug report so quickly. I look forward to using BlocksKit again soon; things are certainly much less tidy and more complex without it. Any ETA on that release? It might help my planning a bit.
First, great library, Zachary (and Alexsander); it's really a fantastic contribution and much appreciated.
Yesterday I discovered that the view controllers in a navigation stack presented modally were not being deallocated upon dismissal. After the requisite hair-pulling and self-accusations, it looks as though the culprit may instead be UIWebViews that use UIWebView+BlocksKit.
I've distilled the problem down to a very simple example (with no navigation controller, etc.) in this repo: https://github.com/mwkirk/BlocksKitWebViewTest
One view controller modally presents a second view controller with an embedded UIWebView with a didFinishLoadBock. The second view controller will not be deallocated when it is dismissed. You can see this when profiling with the Allocations Instrument. However, if the UIWebView's delegate is not set, deallocation works as expected (of course, the didFinishLoadBlock isn't called). See the comments in SecondViewController.m for more details. As far as I can tell, this happens on both the device and simulator from iOS4.2 through 5.1. The example uses v1.0.6a of the static lib on the downloads page.
I haven't had a chance to look at the underlying BlocksKit and A2DynamicDelegate code yet, but I thought you might have some insight. Meanwhile, I'm (sadly) ripping out BlocksKit from my project until I can get a handle on this.
With any luck, it's simply my own oversight or misuse of the library. (And, if so, I hope someone can set me straight!).
The text was updated successfully, but these errors were encountered: