• 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: Best practice for terminating at launch time?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Best practice for terminating at launch time?


  • Subject: Re: Best practice for terminating at launch time?
  • From: Graham Cox <email@hidden>
  • Date: Wed, 11 Feb 2009 14:07:45 +1100


On 11 Feb 2009, at 1:28 pm, Rob Keniger wrote:


On 11/02/2009, at 10:46 AM, Graham Cox wrote:

OK, that's fine for the termination part - thanks!

The problem with the code you outline though is that the call to - runModal runs the event loop which allows the untitled document to continue to open behind the alert. I'd like to discover a way to avoid that if possible.


Ah, I forgot the important part. I set a flag before displaying the dialog and test it in -applicationShouldOpenUntitledFile:. If the flag is set, return NO from that method.


Yes, I tried that. It solves the case of the untitled document but not if the user launched the app with a file, which opens behind the alert.

I need a hook earlier than applicationWillFinishLaunching:, but there doesn't seem to be one, unless I'm just being dense here.

--Graham


_______________________________________________

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


  • Follow-Ups:
    • Re: Best practice for terminating at launch time?
      • From: Rob Keniger <email@hidden>
References: 
 >Best practice for terminating at launch time? (From: Graham Cox <email@hidden>)
 >Re: Best practice for terminating at launch time? (From: Rob Keniger <email@hidden>)
 >Re: Best practice for terminating at launch time? (From: Graham Cox <email@hidden>)
 >Re: Best practice for terminating at launch time? (From: Rob Keniger <email@hidden>)

  • Prev by Date: Re: Best practice for terminating at launch time?
  • Next by Date: Re: Best practice for terminating at launch time?
  • Previous by thread: Re: Best practice for terminating at launch time?
  • Next by thread: Re: Best practice for terminating at launch time?
  • Index(es):
    • Date
    • Thread