Uli's Web Site
Tied up in Bindings
I just spent about an hour tracking down a memory leak in my application, just to find the culprit was my use of Cocoa Bindings. I had hooked up a simple text field to an NSString instance variable.
In my case, the target was File's Owner in my NIB file. Since bindings apparently retain the object to which they are hooked up, the File's owner was waiting for the text field to release it, while the text field would not release its bound target until the File's Owner released it.
Delegates are, by convention not retained by the object delegating to them. So whose nutty idea was it to make bindings retain their targets???
Is it me, or does anybody else get the impression that bindings are a really sucky implementation of a concept that sounded jolly good on paper ... ?
Created: 2004-12-09 @524 Last change: 2004-12-09 @528 | Home | Admin | Edit|
© Copyright 2003-2020 by M. Uli Kusterer, all rights reserved.