Getting a splash screen to show
Getting a splash screen to show
- Subject: Getting a splash screen to show
- From: Steve Mills <email@hidden>
- Date: Wed, 15 May 2013 10:26:30 -0500
Please don't waste my time arguing that splash screens are bad. It's all been hashed out before.
How am I supposed to force the splash screen to be visible? It's created and shown in applicationWillFinishLaunching. The app is document based. Other modal dialogs *could* appear and go away before the splash screen appears, so order is important. If a modal dlog *does* appear beforehand (e.g. registration), then the splash screen will display. If not, something is preventing the splash screen from showing. This got me thinking it was event manager related, so I added this after showing the splash screen:
[[NSApplication sharedApplication] nextEventMatchingMask:NSAnyEventMask untilDate:nil inMode:NSDefaultRunLoopMode dequeue:NO];
That fixed it. Well, it fixed it until I tried launching the app and letting Cocoa restore documents that were open when I quit. Again, no splash screen. Why is this so hard to do?
--
Steve Mills
office: 952-818-3871
home: 952-401-6255
cell: 612-803-6157
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden