#include "wx/filename.h"
#include "wx/evtloop.h"
+#include "wx/modalhook.h"
#include "wx/osx/private.h"
IMPLEMENT_CLASS(wxDirDialog, wxDialog)
-wxDirDialog::wxDirDialog(wxWindow *parent, const wxString& message,
+void wxDirDialog::Init()
+{
+ m_sheetDelegate = nil;
+}
+
+void wxDirDialog::Create(wxWindow *parent, const wxString& message,
const wxString& defaultPath, long style, const wxPoint& WXUNUSED(pos),
const wxSize& WXUNUSED(size), const wxString& WXUNUSED(name))
{
int wxDirDialog::ShowModal()
{
+ WX_HOOK_MODAL_DIALOG();
+
wxCFEventLoopPauseIdleEvents pause;
NSOpenPanel *oPanel = OSXCreatePanel();
if (returnCode == NSOKButton )
{
NSOpenPanel* oPanel = (NSOpenPanel*)panel;
- SetPath( wxCFStringRef::AsString([[oPanel filenames] objectAtIndex:0]));
+ SetPath( wxCFStringRef::AsStringWithNormalizationFormC([[oPanel filenames] objectAtIndex:0]));
result = wxID_OK;
}
SetReturnCode(result);