Is this logical?
Is this logical?
- Subject: Is this logical?
- From: Georg Tuparev <email@hidden>
- Date: Sat, 24 May 2003 01:45:35 +0200
Folks,
Here is what I am doing:
1. I am working on a document based application. All possible document
viewers/editors are provided by plugins. Therefore, I marked the
document extension to be "*" (Target Settings -> Document types)
2. I am loading all plugins (some of them potentially third party) to
determine the full list of document types the application can handle.
3. If I start the application and drop a file on the App Icon (in the
Dock),
- (BOOL)application:(NSApplication *)theApplication openFile:(NSString
*)filename
gets called. If the file has an extension that is not supported by any
of the plugins, the method returns NO.
4. Nevertheless, the designated NSDocument object' method
- (BOOL)loadDataRepresentation:(NSData *)data ofType:(NSString *)aType
or
-readFromFile:ofType:
are called. Only then if I return NO again, there is no document opened.
Is this logical? Although not specifically stated in the docs, I was
always under the impression that if application: openFile: returns NO,
there will be no further attempt to open the document in questions. Did
I misunderstood something?
TIA
Georg Tuparev
Tuparev Technologies
Klipper 13
1186 VR Amstelveen
The Netherlands
Mobile: +31-6-55798196
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.