// Set() functions
void Set( WX_NSColor aColor );
-
+
+ // reroute the inherited ones
+ void Set(unsigned char red, unsigned char green, unsigned char blue)
+ { wxColourBase::Set(red,green,blue); }
+
+ // implemented in colourcmn.cpp
+ bool Set(const wxChar *str)
+ { return wxColourBase::Set(str); }
+
+ bool Set(const wxString &str)
+ { return wxColourBase::Set(str); }
+
+ void Set(unsigned long colRGB)
+ { wxColourBase::Set(colRGB); }
+
protected:
// puts the object in an invalid, uninitialized state
void Init();
wxTopLevelWindows.Append(this);
m_message = message;
- m_dialogStyle = style;
+
+ SetWindowStyle(style);
m_parent = parent;
m_path = defaultPath;
//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]);
[GetNSSavePanel() setPrompt:@"Open"];
}
- if (m_dialogStyle & wxDD_NEW_DIR_BUTTON) //m_dialogStyle & wxDD_NEW_DIR_BUTTON
+ if (HasFlag(wxDD_NEW_DIR_BUTTON)) //m_dialogStyle & wxDD_NEW_DIR_BUTTON
{
[(NSOpenPanel*)m_cocoaNSWindow setCanCreateDirectories:YES];
}
int nResult;
- if (m_dialogStyle & wxFD_SAVE)
+ if (HasFlag(wxFD_SAVE))
{
nResult = [GetNSSavePanel()
runModalForDirectory:wxNSStringWithWxString(m_dir)
// 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);
//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]);
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];
int nResult;
- if (m_dialogStyle & wxFD_SAVE)
+ if (HasFlag(wxFD_SAVE))
{
nResult = [GetNSSavePanel()
runModalForDirectory:wxNSStringWithWxString(m_dir)