Re: event/notification for focus?
Re: event/notification for focus?
- Subject: Re: event/notification for focus?
- From: Luc Vandal <email@hidden>
- Date: Thu, 07 Apr 2005 16:02:57 -0400
> Or as Mike outline NSWindowDidUpdate may be the best way to know when to check if the responder may have changed.
Ok, at least now I know that the first responder can change! ;) Here's what I did so far:
[center addObserver:self
selector:@selector(windowUpdated:)
name:NSWindowDidUpdateNotification object:nil];
- (void)windowUpdated:(NSNotification*)notification
{
NSResponder* resp = [[self window] firstResponder];
if( resp != m_resp )
{
m_resp = resp;
}
}
The only problem is that resp is always null. Where should I get the firstResponder instead?
Thanks for your help guys!
Luc
On 7-Apr-05, at 2:48 PM, Shawn Erickson wrote:
Or as Mike outline NSWindowDidUpdate may be the best way to know when to check if the responder may have changed.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden