Re: How to get an NSWindow from an NSDocument?
Re: How to get an NSWindow from an NSDocument?
- Subject: Re: How to get an NSWindow from an NSDocument?
- From: mmalcolm crawford <email@hidden>
- Date: Mon, 23 May 2005 17:30:10 -0700
On May 23, 2005, at 1:55 PM, Scott Ellsworth wrote:
The following code is part of a Core Data app that can also read
and write "Tab Delimited Sector" and "Sector" files, but since
those are lossy, I want an 'untitled' window to show up when you
open one.
- (BOOL)readFromURL:(NSURL *)absoluteURL ofType:(NSString *)
typeName error:(NSError **)outError{
Modulo my gaffe regarding file wrappers, this seems like an "unusual"
approach to take -- assuming you're subclassing NSPersistentDocument?
You almost certainly should be overriding - (BOOL)
configurePersistentStoreCoordinatorForURL:(NSURL *)url ofType:
(NSString *)fileType error:(NSError **)error (and - (id)initWithType:
(NSString *)type error:(NSError **)error) and setting up an in-memory
store...
mmalc
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden