User input while reading document
User input while reading document
- Subject: User input while reading document
- From: "Randy Widell" <email@hidden>
- Date: Sun, 7 Sep 2008 23:28:50 -0400
I am writing an application that supports a couple of different document
types. One of the document types is a subset of another, so I am using the
same document class for both. When opening the subset type, however, I need
the user to specify a few things about how to import the data. As for the
superset type, the file may be encrypted, so the user would need to enter a
password.
What is not clear to me is how I would go about prompting the user during
readFromURL. What is clear, is that application modal dialogs are bad
apparently, and I am cool that. So, that leaves document modal sheets.
However, document modal sheets need a window.
So, I am thinking that readFromURL will just do the bare minimum to
determine what the document class needs to know from the user. I would then
use windowControllerDidLoadNib to determine when the document's main window
and its sheets are valid, bring up the necessary sheet based on what
readFromURL determined, and then call the appropriate function to do the
rest of work reading the file.
Is this a fundamentally sound design? Is there a better way to do this?
_______________________________________________
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