1 /////////////////////////////////////////////////////////////////////////////
4 // Author: Robert Roebling
7 // Copyright: (c) 1998 Robert Roebling, Julian Smart and Markus Holzem
8 // Licence: wxWindows licence
9 /////////////////////////////////////////////////////////////////////////////
12 #ifndef __GTKFILEDLGH__
13 #define __GTKFILEDLGH__
19 #include "wx/dialog.h"
21 //-------------------------------------------------------------------------
23 //-------------------------------------------------------------------------
25 extern const char *wxFileSelectorPromptStr
;
26 extern const char *wxFileSelectorDefaultWildcardStr
;
28 class wxFileDialog
: public wxDialog
31 DECLARE_DYNAMIC_CLASS(wxFileDialog
)
37 wxFileDialog(wxWindow
*parent
, const wxString
& message
= wxFileSelectorPromptStr
,
38 const wxString
& defaultDir
= "", const wxString
& defaultFile
= "",
39 const wxString
& wildCard
= wxFileSelectorDefaultWildcardStr
,
40 long style
= 0, const wxPoint
& pos
= wxDefaultPosition
);
42 inline void SetMessage(const wxString
& message
) { m_message
= message
; }
43 inline void SetPath(const wxString
& path
) { m_path
= path
; }
44 inline void SetDirectory(const wxString
& dir
) { m_dir
= dir
; }
45 inline void SetFilename(const wxString
& name
) { m_fileName
= name
; }
46 inline void SetWildcard(const wxString
& wildCard
) { m_wildCard
= wildCard
; }
47 inline void SetStyle(long style
) { m_dialogStyle
= style
; }
48 inline void SetFilterIndex(int filterIndex
) { m_filterIndex
= filterIndex
; }
50 inline wxString
GetMessage(void) const { return m_message
; }
51 inline wxString
GetPath(void) const { return m_path
; }
52 inline wxString
GetDirectory(void) const { return m_dir
; }
53 inline wxString
GetFilename(void) const { return m_fileName
; }
54 inline wxString
GetWildcard(void) const { return m_wildCard
; }
55 inline long GetStyle(void) const { return m_dialogStyle
; }
56 inline int GetFilterIndex(void) const { return m_filterIndex
; }
66 wxString m_path
; // Full path
74 #define wxOVERWRITE_PROMPT 4
75 #define wxHIDE_READONLY 8
77 // File selector - backward compatibility
79 char* wxFileSelector(const char *message
= wxFileSelectorPromptStr
, const char *default_path
= NULL
,
80 const char *default_filename
= NULL
, const char *default_extension
= NULL
,
81 const char *wildcard
= wxFileSelectorDefaultWildcardStr
, int flags
= 0,
82 wxWindow
*parent
= NULL
, int x
= -1, int y
= -1);
84 char* wxLoadFileSelector(const char *what
, const char *extension
, const char *default_name
= NULL
,
85 wxWindow
*parent
= NULL
);
87 char* wxSaveFileSelector(const char *what
, const char *extension
, const char *default_name
= NULL
,
88 wxWindow
*parent
= NULL
);