• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: How do I implement a splash window
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How do I implement a splash window


  • Subject: Re: How do I implement a splash window
  • From: PGM <email@hidden>
  • Date: Sun, 23 Apr 2006 20:47:06 -0400

In principle, just putting a window to the front should not prevent your application from doing other stuff. For my own program everything loads perfectly in the background behind my splashpanel. In case you are interested, I call the following code inside the init-method of my NSApp subclass:

if([[[[NSUserDefaultsController sharedUserDefaultsController] values] valueForKey:@"showSplashScreenAtLaunch"] boolValue]){
//Show the panel only if set in preferences
[[SplashPanelController sharedInstance] showPanel:self];


double interval = 1.5; //the real interval may be longer as the Timer only fires when the app has finished loading
splashTimer = [[NSTimer scheduledTimerWithTimeInterval:interval
target:self
selector:@selector(hidePanel)
userInfo:nil
repeats: NO] retain];
}


the showPanel and hidePanel methods are from the splashPanelController, which I based upon the "Fancy About Panel" example from Apple. If your app only takes 2 or 3 seconds to load, I think that showing a progressBar would redundant as the user has hardly any time to enjoy it.

Hope this helps, PGM



On Apr 22, 2006, at 5:05 PM, desktoast music productions wrote:

Hi again,
On cocoadev.com and other forums I found a lot on how to create a splash
image. But though I am able to create one now, I still wonder where (and
how) to implement it. Because it is created programmatically, I implemented
it in the awakeFromNib of my NSDocumentController subclass (which is also my
app’s delegate) - just to see how it looks on screen, like that:


- (void)awakeFromNib {
WDVSplashWindow *splash = [[WDVSplashWindow alloc]
initWithImage:[NSImage imageNamed:@"Splash1"]];
[splash orderFront:nil];
}
This way, the splash shows up immediately. But, of course, from then on
nothing else happens. No main Window, now data loading from file.
Could anybody please give me a hint, where to implement a splash, so it
shows up for 2-3 seconds, WHILE my dcoument is loading?s
Second – is there a way of showing the status of that loading progress on
the splash image (like “Loading member data...” etc.)?


Thank you,
Peter
-- peter schwaiger
desktoast music productions
http://www.autlawmusic.com


_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
email@hidden


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
  • Follow-Ups:
    • Re: How do I implement a splash window
      • From: Ondra Cada <email@hidden>
References: 
 >How do I implement a splash window (From: desktoast music productions <email@hidden>)

  • Prev by Date: Re: Should Cocoa Apps have splash screens at all ?
  • Next by Date: Re: Core Data Binding question: How to implement unidirectional or read-only binding
  • Previous by thread: How do I implement a splash window
  • Next by thread: Re: How do I implement a splash window
  • Index(es):
    • Date
    • Thread