Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Open Handler, when is it called?



> Les R. Titze <email@hidden> wrote:
>
>> I had to work around this issue in my code to determine when to show a new
>> untitled document.
>
> After thinking about it overnight (cook slowly...), I realize that my real
> problem is that my application does two different things on startup. If a
> document was double-clicked, it should just open the document. Otherwise, it
> should show a login window.

The best way to determine whether the user double-clicked on the application
or a document is to add both an OpenDocument and OpenApplication handler.
You'll always get an OpenDocument from double-clicking a document, and
you'll always get an OpenApplication from double-clicking the application.

--
Glenn L. Austin
Computer Wizard and Race Car Driver
<email@hidden>
<http://www.austin-home.com/glenn/>


References: 
 >Re: Open Handler, when is it called? (From: Steve Roy <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.