Re: forcing a dialog to be the active (front) window
Re: forcing a dialog to be the active (front) window
- Subject: Re: forcing a dialog to be the active (front) window
- From: John Spicer <email@hidden>
- Date: Fri, 23 Jul 2004 09:45:40 -0500
Still not having any luck with this. I was wondering if it's because I
started with a doc application template.
Could this possibly have any effect?
I have tried what's shown below with no difference. Also tried this:
[medicalAlertPanel orderFrontRegardless];
But it makes no difference.
Basically, the window does **not** become the active window till it's
clicked upon, after the nib file is loaded (it's in a separate nib
file, I'm using what I think is standard code to load it):
- (IBAction) showAlertPanel:(id)sender
{
if (AlertPanel == nil)
{
if (![NSBundle loadNibNamed:@"Alerts.nib" owner:self])
{
NSLog (@"Load of Alerts.nib failed");
return;
}
}
// [medicalAlertPanel makeKeyAndOrderFront: nil]; <- tried this plus
next line
// [medicalAlertPanel orderFrontRegardless]; <- and even together
with no change
}
I'm clueless on this one. Anyone have some ideas to try, or even yet,
can tell me **exactly** what I'm doing wrong?
On Jul 22, 2004, at 7:58 PM, Andreas Mayer wrote:
>
Am 23.07.2004 um 00:07 Uhr schrieb Jim Ways:
>
>
> [thePanel makeKeyAndOrderFront: @"1"];
>
>
>
> seems to work for some reason, im still new to cocoa
>
> but its worth a try =)
>
>
This really shouldn't make a difference. The argument is just the
>
sender and in this case I believe it's only there so that the method
>
signature is that of an action method
>
(<http://developer.apple.com/documentation/Cocoa/Conceptual/
>
BasicEventHandling/Concepts/ActionEventMsg.html>).
>
>
Using a constant string as sender argument is - umm - strange. I'd
>
recommend using nil or self instead.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.