Re: NSOpenPanel ->getting path while panel is up
Re: NSOpenPanel ->getting path while panel is up
- Subject: Re: NSOpenPanel ->getting path while panel is up
- From: Timothy Ritchey <email@hidden>
- Date: Thu, 25 Apr 2002 10:15:44 -0500
I was at one time trying to change the accessory view of an NSOpenPanel
as the user clicked on different files. I subclassed NSOpenPanel, and
then overrode:
RRImportPanel.m:
- (void)browser:(NSBrowser *)sender willDisplayCell:(id)cell
atRow:(int)row column:(int)column
{
// you can get the current path with: [_browser path];
// and do whatever you feel is necessary.
[super browser:sender willDisplayCell:cell atRow:row column:column];
}
I was never able to get the NSOpenPanel to resize correctly when I added
and removed different sized accessory views. It just kept jumping around.
HTH,
tim
On Thursday, April 25, 2002, at 01:09 AM, David Rehring wrote:
I've got an NSOpenPanel configured so the user can select a single
directory. I've added a accessory view with a 'Create New Folder...'
button
to the NSOpenPanel.
When the user clicks the button, I open another panel and get the name
of
the directory to create.
So far, everything works great.
The problem is, I can't get the panel to the directory that the user has
currently selected in the NSOpenPanel.
I've tried:
- (NSString *)directory;
- (NSURL *)URL;
- (NSArray *)filenames;
- (NSArray *)URLs;
Anyone know how to get the currently selected directory?
Later,
--
David Rehring Psychos do not explode when light hits
Senior Software Engineer them, no matter how crazy they are...
Atimi Software, Inc.
www.atimi.com And totally insane guy!
_______________________________________________
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.
_______________________________________________
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.