]> git.saurik.com Git - wxWidgets.git/blame - include/wx/generic/dirdlgg.h
added wxDataViewIndexListModel and sample
[wxWidgets.git] / include / wx / generic / dirdlgg.h
CommitLineData
d7a15103 1/////////////////////////////////////////////////////////////////////////////
74d8ead3 2// Name: wx/generic/dirdlgg.h
748fcded
VS
3// Purpose: wxGenericDirCtrl class
4// Builds on wxDirCtrl class written by Robert Roebling for the
5// wxFile application, modified by Harm van der Heijden.
6// Further modified for Windows.
7// Author: Robert Roebling, Harm van der Heijden, Julian Smart et al
d7a15103 8// Modified by:
748fcded 9// Created: 21/3/2000
8b17ba72 10// RCS-ID: $Id$
748fcded 11// Copyright: (c) Robert Roebling, Harm van der Heijden, Julian Smart
65571936 12// Licence: wxWindows licence
d7a15103
JS
13/////////////////////////////////////////////////////////////////////////////
14
15#ifndef _WX_DIRDLGG_H_
16#define _WX_DIRDLGG_H_
17
b5dbe15d
VS
18class WXDLLIMPEXP_FWD_CORE wxGenericDirCtrl;
19class WXDLLIMPEXP_FWD_CORE wxTextCtrl;
20class WXDLLIMPEXP_FWD_CORE wxTreeEvent;
10eb1f1e 21
74d8ead3 22// we may be included directly as well as from wx/dirdlg.h (FIXME)
63ec432b
MR
23extern WXDLLEXPORT_DATA(const wxChar) wxDirDialogNameStr[];
24extern WXDLLEXPORT_DATA(const wxChar) wxDirSelectorPromptStr[];
259a6e38 25
141d782d 26#ifndef wxDD_DEFAULT_STYLE
259a6e38 27#ifdef __WXWINCE__
ff3e84ff 28 #define wxDD_DEFAULT_STYLE wxDEFAULT_DIALOG_STYLE
259a6e38 29#else
ff3e84ff 30 #define wxDD_DEFAULT_STYLE (wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER)
74d8ead3 31#endif
259a6e38 32#endif
74d8ead3
VZ
33
34#include "wx/dialog.h"
35
d7a15103 36//-----------------------------------------------------------------------------
748fcded 37// wxGenericDirDialog
dc6c62a9
RR
38//-----------------------------------------------------------------------------
39
b50747ea 40class WXDLLEXPORT wxGenericDirDialog : public wxDirDialogBase
dc6c62a9
RR
41{
42public:
b50747ea 43 wxGenericDirDialog() : wxDirDialogBase() { }
e78d4a23
VZ
44
45 wxGenericDirDialog(wxWindow* parent,
46 const wxString& title = wxDirSelectorPromptStr,
957aea45 47 const wxString& defaultPath = wxEmptyString,
e78d4a23 48 long style = wxDD_DEFAULT_STYLE,
957aea45 49 const wxPoint& pos = wxDefaultPosition,
b50747ea
RR
50 const wxSize& sz = wxDefaultSize,//Size(450, 550),
51 const wxString& name = wxDirDialogNameStr);
52
53 bool Create(wxWindow* parent,
54 const wxString& title = wxDirSelectorPromptStr,
55 const wxString& defaultPath = wxEmptyString,
56 long style = wxDD_DEFAULT_STYLE,
57 const wxPoint& pos = wxDefaultPosition,
58 const wxSize& sz = wxDefaultSize,//Size(450, 550),
e78d4a23 59 const wxString& name = wxDirDialogNameStr);
748fcded
VS
60
61 //// Accessors
748fcded 62 void SetPath(const wxString& path);
74d8ead3 63 wxString GetPath() const;
d7a15103 64
748fcded 65 //// Overrides
74d8ead3 66 virtual int ShowModal();
141d782d 67 virtual void EndModal(int retCode);
74d8ead3
VZ
68
69 // this one is specific to wxGenericDirDialog
70 wxTextCtrl* GetInputCtrl() const { return m_input; }
d7a15103 71
748fcded
VS
72protected:
73 //// Event handlers
74 void OnCloseWindow(wxCloseEvent& event);
d7a15103 75 void OnOK(wxCommandEvent& event);
748fcded
VS
76 void OnTreeSelected(wxTreeEvent &event);
77 void OnTreeKeyDown(wxTreeEvent &event);
d7a15103 78 void OnNew(wxCommandEvent& event);
e13ea14e 79 void OnGoHome(wxCommandEvent& event);
42dcacf0 80 void OnShowHidden(wxCommandEvent& event);
d7a15103 81
748fcded
VS
82 wxGenericDirCtrl* m_dirCtrl;
83 wxTextCtrl* m_input;
84
dc6c62a9 85 DECLARE_EVENT_TABLE()
d6379fa3 86 DECLARE_DYNAMIC_CLASS(wxGenericDirDialog)
d7a15103
JS
87};
88
748fcded 89#endif // _WX_DIRDLGG_H_