Re: Splash Screen Strategy?
Re: Splash Screen Strategy?
- Subject: Re: Splash Screen Strategy?
- From: matt neuburg <email@hidden>
- Date: Mon, 10 Feb 2003 09:07:20 -0800
On Mon, 10 Feb 2003 13:45:06 +0000, Steve <email@hidden> said:
>
My app has one main window with multiple controls and one main
>
controller. I'd like to open a splash screen before the main window
>
appears, and before the controller does a lot of setup work in its
>
awakeFromNib (which takes 3 or 4 seconds).
>
I could do this by making the main window non-visible, and moving all
>
my controller initialisation into a seperate routine which I call after
>
the splash screen has appeared.
>
Is there a neater or simpler way to do splash screens?
What is it about this approach that you consider non-neat or non-simple? Linearity (show the splash, do the initialization) is as simple as you can get. You could spawn a thread, or run a modal loop, but that's less simple.
>
Also, in IB I can't see how to remove a window's (or panel's) title bar
>
.. Do I have to do this programmatically?
Yes. See the NSWindow documentation. Look at the very first section, Constants. This lists the values employed to set how a window has or doesn't have peripheral elementes. The combination of these values is the styleMask. You hand this to the initializer when you construct the window. You can't change it once the window exists, which is why you'll have to build the window in code. This sounds scary but it isn't. Remember, your nib can always contain a window-less NSView containing everything that needs to go in the window, so in code you construct the window and slap this NSView right into it as its contentView. m.
matt neuburg, phd = email@hidden,
http://www.tidbits.com/matt
pantes anthropoi tou eidenai oregontai phusei
Subscribe to TidBITS! It's free and smart.
http://www.tidbits.com/
_______________________________________________
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.