I have a property in one of my classes:

NSString * suggestedDiskImageName;
@property (retain, readwrite) NSString * suggestedDiskImageName;
@synthesize suggestedDiskImageName;

Which is just like a dozen others that I declare, except for some reason that is beyond comprehension after my HOUR LONG investigation, when I do:

1) nonNilInstance.suggestedDiskImageName = someValue;
2) [nonNilInstance setSuggestedDiskImageName:someValue];
3) [nonNilInstance setValue:someValue forKey:@"suggestedDiskImageName"];


All of them fail to trigger will/didChangeValueForKey (which I'm overriding to see changes to all properties in my class). It actually changes the value, but it doesn't send the KVC methods. Every other single property works, but this one does not. I've tried multiple values, I've tried renaming the property, I've tried using a different instance variable, I've tried reordering the instance variables, property declarations, and synthesize declarations just incase it was some stupid thing like that, I've even tried calling the code from different locations in my project.......... it always fails!

It's completely boggling my mind.


The only thing that worked was to create an implementation of setSuggestedDiskImageName: and manually call will/didChangeValueForKey.




What on Earth can I do?


--
Seth Willits



_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to