Re: First responder after alert
Re: First responder after alert
- Subject: Re: First responder after alert
- From: Daniel Jalkut <email@hidden>
- Date: Tue, 28 Jun 2005 09:28:45 -0700
Andy - you might want to put the makeFirstResponder call on an
"performSelector:withObject:afterDelay" delay. I've had good luck
with that when dealing with responder-related timing issues like this.
Daniel
On Jun 28, 2005, at 8:01 AM, Andy Bettis wrote:
Hi,
I have an alert displaying function:
- (void) display
{
NSRunAlertPanel(mTitle,mMessage,@"OK",nil,nil);
if (mField) {
BOOL result = [mWindow makeFirstResponder:mField];
}
}
Which is intended to set a field on the frontmost window as the
first responder after the alert has gone away. However this only
works on the second call, the first time I call it the current
first responder isn't changed. If I use the debugger to track the
processing it all works fine, which makes me think it's a timing/
event/messaging problem. Can anyone suggest a way of setting the
first responder effectively?
Many thanks
Rev. Andy
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
sweater.com
This email sent to email@hidden
_______________________________________________
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