]> git.saurik.com Git - wxWidgets.git/blob - include/wx/gtk/filedlg.h
Fix wxPropertyGrid::GetPropertyRect when the last item is collapsed.
[wxWidgets.git] / include / wx / gtk / filedlg.h
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: wx/gtk/filedlg.h
3 // Purpose:
4 // Author: Robert Roebling
5 // Copyright: (c) 1998 Robert Roebling
6 // Licence: wxWindows licence
7 /////////////////////////////////////////////////////////////////////////////
8
9 #ifndef _WX_GTKFILEDLG_H_
10 #define _WX_GTKFILEDLG_H_
11
12 #include "wx/gtk/filectrl.h" // for wxGtkFileChooser
13
14 //-------------------------------------------------------------------------
15 // wxFileDialog
16 //-------------------------------------------------------------------------
17
18 class WXDLLIMPEXP_CORE wxFileDialog: public wxFileDialogBase
19 {
20 public:
21 wxFileDialog() { }
22
23 wxFileDialog(wxWindow *parent,
24 const wxString& message = wxFileSelectorPromptStr,
25 const wxString& defaultDir = wxEmptyString,
26 const wxString& defaultFile = wxEmptyString,
27 const wxString& wildCard = wxFileSelectorDefaultWildcardStr,
28 long style = wxFD_DEFAULT_STYLE,
29 const wxPoint& pos = wxDefaultPosition,
30 const wxSize& sz = wxDefaultSize,
31 const wxString& name = wxFileDialogNameStr);
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);
41 virtual ~wxFileDialog();
42
43 virtual wxString GetPath() const;
44 virtual void GetPaths(wxArrayString& paths) const;
45 virtual wxString GetFilename() const;
46 virtual void GetFilenames(wxArrayString& files) const;
47 virtual int GetFilterIndex() const;
48
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);
55
56 virtual int ShowModal();
57
58 virtual bool SupportsExtraControl() const { return true; }
59
60 // Implementation only.
61 void GTKSelectionChanged(const wxString& filename);
62
63
64 protected:
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
72 private:
73 void OnFakeOk( wxCommandEvent &event );
74 void OnSize(wxSizeEvent&);
75 virtual void AddChildGTK(wxWindowGTK* child);
76
77 wxGtkFileChooser m_fc;
78
79 DECLARE_DYNAMIC_CLASS(wxFileDialog)
80 DECLARE_EVENT_TABLE()
81 };
82
83 #endif // _WX_GTKFILEDLG_H_