]>
Commit | Line | Data |
---|---|---|
c801d85f | 1 | ///////////////////////////////////////////////////////////////////////////// |
80fdcdb9 | 2 | // Name: wx/gtk/filedlg.h |
c801d85f KB |
3 | // Purpose: |
4 | // Author: Robert Roebling | |
58614078 | 5 | // Copyright: (c) 1998 Robert Roebling |
65571936 | 6 | // Licence: wxWindows licence |
c801d85f KB |
7 | ///////////////////////////////////////////////////////////////////////////// |
8 | ||
f1d5aa4e PC |
9 | #ifndef _WX_GTKFILEDLG_H_ |
10 | #define _WX_GTKFILEDLG_H_ | |
c801d85f | 11 | |
0cf3e587 | 12 | #include "wx/gtk/filectrl.h" // for wxGtkFileChooser |
4e1901b7 | 13 | |
c801d85f | 14 | //------------------------------------------------------------------------- |
f74172ab | 15 | // wxFileDialog |
c801d85f KB |
16 | //------------------------------------------------------------------------- |
17 | ||
700d08c1 | 18 | class WXDLLIMPEXP_CORE wxFileDialog: public wxFileDialogBase |
c801d85f | 19 | { |
0e1399b3 VZ |
20 | public: |
21 | wxFileDialog() { } | |
22 | ||
23 | wxFileDialog(wxWindow *parent, | |
24 | const wxString& message = wxFileSelectorPromptStr, | |
f74172ab VZ |
25 | const wxString& defaultDir = wxEmptyString, |
26 | const wxString& defaultFile = wxEmptyString, | |
0e1399b3 | 27 | const wxString& wildCard = wxFileSelectorDefaultWildcardStr, |
ff3e84ff VZ |
28 | long style = wxFD_DEFAULT_STYLE, |
29 | const wxPoint& pos = wxDefaultPosition, | |
30 | const wxSize& sz = wxDefaultSize, | |
31 | const wxString& name = wxFileDialogNameStr); | |
e3f54c8f VZ |
32 | bool Create(wxWindow *parent, |
33 | const wxString& message = wxFileSelectorPromptStr, | |
34 | const wxString& defaultDir = wxEmptyString, | |
35 | const wxString& defaultFile = wxEmptyString, | |
36 | const wxString& wildCard = wxFileSelectorDefaultWildcardStr, | |
37 | long style = wxFD_DEFAULT_STYLE, | |
38 | const wxPoint& pos = wxDefaultPosition, | |
39 | const wxSize& sz = wxDefaultSize, | |
40 | const wxString& name = wxFileDialogNameStr); | |
9ff9d30c | 41 | virtual ~wxFileDialog(); |
f8bc53eb JS |
42 | |
43 | virtual wxString GetPath() const; | |
9755e73b | 44 | virtual void GetPaths(wxArrayString& paths) const; |
f8bc53eb | 45 | virtual wxString GetFilename() const; |
9755e73b | 46 | virtual void GetFilenames(wxArrayString& files) const; |
f8bc53eb JS |
47 | virtual int GetFilterIndex() const; |
48 | ||
9755e73b VS |
49 | virtual void SetMessage(const wxString& message); |
50 | virtual void SetPath(const wxString& path); | |
51 | virtual void SetDirectory(const wxString& dir); | |
52 | virtual void SetFilename(const wxString& name); | |
53 | virtual void SetWildcard(const wxString& wildCard); | |
54 | virtual void SetFilterIndex(int filterIndex); | |
f8bc53eb | 55 | |
4e1901b7 | 56 | virtual int ShowModal(); |
4e1901b7 | 57 | |
8ce68f7f | 58 | virtual bool SupportsExtraControl() const { return true; } |
a552d120 | 59 | |
926df8a1 VZ |
60 | // Implementation only. |
61 | void GTKSelectionChanged(const wxString& filename); | |
62 | ||
4e1901b7 | 63 | |
6f02a879 | 64 | protected: |
5b2e23bf RR |
65 | // override this from wxTLW since the native |
66 | // form doesn't have any m_wxwindow | |
67 | virtual void DoSetSize(int x, int y, | |
68 | int width, int height, | |
69 | int sizeFlags = wxSIZE_AUTO); | |
70 | ||
71 | ||
f8bc53eb | 72 | private: |
268331f0 | 73 | void OnFakeOk( wxCommandEvent &event ); |
f1d5aa4e | 74 | void OnSize(wxSizeEvent&); |
48200154 | 75 | virtual void AddChildGTK(wxWindowGTK* child); |
0cf3e587 VZ |
76 | |
77 | wxGtkFileChooser m_fc; | |
f1d5aa4e PC |
78 | |
79 | DECLARE_DYNAMIC_CLASS(wxFileDialog) | |
80 | DECLARE_EVENT_TABLE() | |
c801d85f KB |
81 | }; |
82 | ||
f1d5aa4e | 83 | #endif // _WX_GTKFILEDLG_H_ |