Re: Where is it better to register with NSNotificationCenter in class?
Re: Where is it better to register with NSNotificationCenter in class?
- Subject: Re: Where is it better to register with NSNotificationCenter in class?
- From: Dave Hersey <email@hidden>
- Date: Tue, 25 Mar 2008 01:14:12 -0400
I think you're seeing a debugger anomaly when stepping through things.
Try logging self before and after.
NSLog(@"self = %p", self);
- d
On Mar 25, 2008, at 1:04 AM, Samvel wrote:
On Mar 24, 2008, at 11:56 PM, Jens Alfke wrote:
On 24 Mar '08, at 9:51 PM, Samvel wrote:
I run into troubles trying to register my object with
NSNotificationCenter in class
-(id) init;
That's a fine place to do it.
//... (at this point self has lost it's original value having
some '<value')
I don't understand what that comment means. Nothing should have
happened to 'self' at that point. Can you be more specific?
Before line where registration with NSNotificationCenter is
performed self contains pointer to actual object in memory. I can
see it with debugger. Right after registering with
NSNotificationCenter self is highlighted with red color in debugger
and showing <value as its Value.
—Jens
_______________________________________________
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