FileChooser "New Folder" button

The FileChooser implementation doesn’t seem to be consistent across Mac and Windows. Our application would benefit from having a “New Folder” FileChooser button on the Mac, which it doesn’t. On the other hand, FileChooser on Windows has a “Make New Folder” button on the lower left. Am I overlooking something? If not, it would be great if FileChooser had a flag that could be set/unset for this attribute.

We are using the 1.50 release on Mac and close to the tip (around 11/2009) on Windows.

For those dialogs, it really just lets the OS get on and do whatever it normally does.

Yes it does! Are you looking at an open dialog rather than a save one or something?

Sorry, I left out some crucial info. We are using FileChooser::browseForDirectory(). (We’re asking the user to select a directory before performing an operation.) On Mac, browseForDirectory() only lets you browse existing directories and does not provide a “New Folder” button. This is what we’re after. Thanks!

Well, you’d better write to Steve Jobs and ask him! Presumably OSX only shows a new folder button on a ‘save’ box, which seems pretty reasonable to me.

I’ll head over to Yerba Buena center and bend his ear about it first thing after the big announcement tomorrow. :wink:

I did, he said “what?”

Sorry for bringing this back on topic, but it’s not accurate. OS X does provide a way to show a “New Folder” button in an Open dialog. NSOpenPanel inherits from NSSavePanel, which implements setCanCreateDirectories.

The following will work:, line 114 (add after creating the panel)

if (selectsDirectory) {
        [panel setCanCreateDirectories:YES];


Oh, right - I looked for a method like that but didn’t find anything. Thanks, I’ll add that!