• 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
Overriding "oapp" effect
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Overriding "oapp" effect


  • Subject: Overriding "oapp" effect
  • From: Donald Brown <email@hidden>
  • Date: Mon, 05 Nov 2001 21:41:56 -0600

I want my app to have an option where a user can select one or more
documents to open when the application is double-clicked (but not when a
document is double-clicked on, and certainly not when a user selects New
from the file menu). I've come up with a possible method, but it doesn't
seem elegant.

Set a flag so I know the period between the applicationWillFinishLaunching
and applicationDidFinishLaunching notifications. If this flag is set, and
applicationShouldOpenUntitledFile is called, open the user-picked document
and return NO.

(If I decide to implement it on a rapp, do something similar with
applicationShouldHandleReopen, but that's straightforward)

Is this the way to do this, or am I missing a more straightforward way of
trapping the original opening?

Donald

--
Donald Brown
email@hidden
http://www.eamontales.com

We have met the enemy and he is us - Pogo


  • Prev by Date: Re: Weird SIGBUS errors
  • Next by Date: Widgets/Palettes
  • Previous by thread: Re: NSUsersDefault and users
  • Next by thread: Widgets/Palettes
  • Index(es):
    • Date
    • Thread