]>
Commit | Line | Data |
---|---|---|
e1d3601a PC |
1 | ///////////////////////////////////////////////////////////////////////////// |
2 | // Name: src/common/dirctrlcmn.cpp | |
3 | // Purpose: wxGenericDirCtrl common code | |
4 | // Author: Harm van der Heijden, Robert Roebling, Julian Smart | |
5 | // Modified by: | |
6 | // Created: 12/12/98 | |
7 | // RCS-ID: $Id$ | |
8 | // Copyright: (c) Harm van der Heijden, Robert Roebling and Julian Smart | |
9 | // Licence: wxWindows licence | |
10 | ///////////////////////////////////////////////////////////////////////////// | |
11 | ||
12 | // For compilers that support precompilation, includes "wx.h". | |
13 | #include "wx/wxprec.h" | |
14 | ||
15 | #ifdef __BORLANDC__ | |
16 | #pragma hdrstop | |
17 | #endif | |
18 | ||
19 | #if wxUSE_DIRDLG || wxUSE_FILEDLG | |
20 | ||
21 | #include "wx/generic/dirctrlg.h" | |
22 | ||
f313deaa PC |
23 | extern WXDLLEXPORT_DATA(const char) wxDirDialogNameStr[] = "wxDirCtrl"; |
24 | extern WXDLLEXPORT_DATA(const char) wxDirDialogDefaultFolderStr[] = "/"; | |
25 | extern WXDLLEXPORT_DATA(const char) wxDirSelectorPromptStr[] = "Select a directory"; | |
26 | ||
e1d3601a PC |
27 | //----------------------------------------------------------------------------- |
28 | // XTI | |
29 | //----------------------------------------------------------------------------- | |
30 | ||
31 | wxDEFINE_FLAGS( wxGenericDirCtrlStyle ) | |
32 | wxBEGIN_FLAGS( wxGenericDirCtrlStyle ) | |
33 | // new style border flags, we put them first to | |
34 | // use them for streaming out | |
35 | wxFLAGS_MEMBER(wxBORDER_SIMPLE) | |
36 | wxFLAGS_MEMBER(wxBORDER_SUNKEN) | |
37 | wxFLAGS_MEMBER(wxBORDER_DOUBLE) | |
38 | wxFLAGS_MEMBER(wxBORDER_RAISED) | |
39 | wxFLAGS_MEMBER(wxBORDER_STATIC) | |
40 | wxFLAGS_MEMBER(wxBORDER_NONE) | |
41 | ||
42 | // old style border flags | |
43 | wxFLAGS_MEMBER(wxSIMPLE_BORDER) | |
44 | wxFLAGS_MEMBER(wxSUNKEN_BORDER) | |
45 | wxFLAGS_MEMBER(wxDOUBLE_BORDER) | |
46 | wxFLAGS_MEMBER(wxRAISED_BORDER) | |
47 | wxFLAGS_MEMBER(wxSTATIC_BORDER) | |
48 | wxFLAGS_MEMBER(wxBORDER) | |
49 | ||
50 | // standard window styles | |
51 | wxFLAGS_MEMBER(wxTAB_TRAVERSAL) | |
52 | wxFLAGS_MEMBER(wxCLIP_CHILDREN) | |
53 | wxFLAGS_MEMBER(wxTRANSPARENT_WINDOW) | |
54 | wxFLAGS_MEMBER(wxWANTS_CHARS) | |
55 | wxFLAGS_MEMBER(wxFULL_REPAINT_ON_RESIZE) | |
56 | wxFLAGS_MEMBER(wxALWAYS_SHOW_SB ) | |
57 | wxFLAGS_MEMBER(wxVSCROLL) | |
58 | wxFLAGS_MEMBER(wxHSCROLL) | |
59 | ||
60 | wxFLAGS_MEMBER(wxDIRCTRL_DIR_ONLY) | |
61 | wxFLAGS_MEMBER(wxDIRCTRL_3D_INTERNAL) | |
62 | wxFLAGS_MEMBER(wxDIRCTRL_SELECT_FIRST) | |
63 | wxFLAGS_MEMBER(wxDIRCTRL_SHOW_FILTERS) | |
64 | wxEND_FLAGS( wxGenericDirCtrlStyle ) | |
65 | ||
66 | wxIMPLEMENT_DYNAMIC_CLASS_XTI(wxGenericDirCtrl, wxControl, "wx/dirctrl.h") | |
67 | ||
68 | wxBEGIN_PROPERTIES_TABLE(wxGenericDirCtrl) | |
69 | wxHIDE_PROPERTY( Children ) | |
70 | ||
71 | wxPROPERTY( DefaultPath, wxString, SetDefaultPath, GetDefaultPath, \ | |
72 | wxEMPTY_PARAMETER_VALUE, 0 /*flags*/, wxT("Helpstring"), wxT("group")) | |
73 | wxPROPERTY( Filter, wxString, SetFilter, GetFilter, wxEMPTY_PARAMETER_VALUE, \ | |
74 | 0 /*flags*/, wxT("Helpstring"), wxT("group") ) | |
75 | wxPROPERTY( DefaultFilter, int, SetFilterIndex, GetFilterIndex, \ | |
76 | wxEMPTY_PARAMETER_VALUE, 0 /*flags*/, wxT("Helpstring"), wxT("group") ) | |
77 | ||
78 | wxPROPERTY_FLAGS( WindowStyle, wxGenericDirCtrlStyle, long, SetWindowStyleFlag, \ | |
79 | GetWindowStyleFlag, wxEMPTY_PARAMETER_VALUE, 0, wxT("Helpstring"), \ | |
80 | wxT("group") ) | |
81 | wxEND_PROPERTIES_TABLE() | |
82 | ||
83 | wxEMPTY_HANDLERS_TABLE(wxGenericDirCtrl) | |
84 | ||
85 | wxCONSTRUCTOR_8( wxGenericDirCtrl, wxWindow*, Parent, wxWindowID, Id, \ | |
86 | wxString, DefaultPath, wxPoint, Position, wxSize, Size, \ | |
87 | long, WindowStyle, wxString, Filter, int, DefaultFilter ) | |
88 | ||
89 | #endif // wxUSE_DIRDLG || wxUSE_FILEDLG |