Re: Implementing a welcome window in document based apps?
Re: Implementing a welcome window in document based apps?
- Subject: Re: Implementing a welcome window in document based apps?
- From: Sherm Pendley <email@hidden>
- Date: Mon, 17 Oct 2005 04:57:46 -0400
On Oct 17, 2005, at 3:43 AM, Colin Cornaby wrote:
I have a lobby style window that pops up when my application
launches (like a welcome window with options) in my document based
app. The window is part of my application's main nib, and is set to
be visible at launch time. This works fine, it shows up when the
application starts and the application seems to automatically not
create a new document at run time.
I'd like to be able to bind "Visible at launch time" to
NSUserDefaults in order to allow the user to tell my application to
no longer show that window on startup. I can't directly bind to it,
so I was looking for a way progmatically set it on the fly.
In IB, make your welcome window *not* visible at launch time, then in
your application delegate, show it if the default says to:
- (void) applicationDidFinishLaunching:
{
if ([[NSUserDefaults standardUserDefaults]
boolForKey:@"ShowWelcomeWindow"])
{
[welcomeWindow makeKeyAndOrderFront:nil];
}
}
sherm--
Cocoa programming in Perl: http://camelbones.sourceforge.net
Hire me! My resume: http://www.dot-app.org
_______________________________________________
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