X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/949c9f74c3ec1b3fba78079a5690034d1facfdb8..11fe6505b848a968f4c89cb3c3fd37a6a03bcaea:/src/cocoa/filedlg.mm?ds=sidebyside diff --git a/src/cocoa/filedlg.mm b/src/cocoa/filedlg.mm index 0070821f25..57a8a2fbaf 100644 --- a/src/cocoa/filedlg.mm +++ b/src/cocoa/filedlg.mm @@ -48,11 +48,17 @@ IMPLEMENT_CLASS(wxCocoaFileDialog, wxFileDialogBase) // wxFileDialog // ---------------------------------------------------------------------------- -wxFileDialog::wxFileDialog(wxWindow *parent, const wxString& message, - const wxString& defaultDir, const wxString& defaultFileName, - const wxString& wildCard, long style, const wxPoint& pos) -: wxFileDialogBase(parent, message, defaultDir, defaultFileName, - wildCard, style, pos) +wxFileDialog::wxFileDialog(wxWindow *parent, + const wxString& message, + const wxString& defaultDir, + const wxString& defaultFileName, + const wxString& wildCard, + long style, + const wxPoint& pos, + const wxSize& sz, + const wxString& name) + : wxFileDialogBase(parent, message, defaultDir, defaultFileName, + wildCard, style, pos, sz, name) { wxTopLevelWindows.Append(this); @@ -69,7 +75,7 @@ wxFileDialog::wxFileDialog(wxWindow *parent, const wxString& message, //If the user requests to save - use a NSSavePanel //else use a NSOpenPanel - if (m_dialogStyle & wxFD_SAVE) + if (HasFlag(wxFD_SAVE)) { SetNSPanel([NSSavePanel savePanel]); @@ -93,7 +99,7 @@ wxFileDialog::wxFileDialog(wxWindow *parent, const wxString& message, SetNSPanel([NSOpenPanel openPanel]); [m_cocoaNSWindow setTitle:wxNSStringWithWxString(message)]; - [(NSOpenPanel*)m_cocoaNSWindow setAllowsMultipleSelection:(m_dialogStyle & wxFD_MULTIPLE)]; + [(NSOpenPanel*)m_cocoaNSWindow setAllowsMultipleSelection:(HasFlag(wxFD_MULTIPLE))]; [(NSOpenPanel*)m_cocoaNSWindow setResolvesAliases:YES]; [(NSOpenPanel*)m_cocoaNSWindow setCanChooseFiles:YES]; [(NSOpenPanel*)m_cocoaNSWindow setCanChooseDirectories:NO]; @@ -196,7 +202,7 @@ int wxFileDialog::ShowModal() int nResult; - if (m_dialogStyle & wxFD_SAVE) + if (HasFlag(wxFD_SAVE)) { nResult = [GetNSSavePanel() runModalForDirectory:wxNSStringWithWxString(m_dir)