1 /////////////////////////////////////////////////////////////////////////////
2 // Name: src/xrc/xh_gdctl.cpp
3 // Purpose: XRC resource for wxGenericDirCtrl
4 // Author: Markus Greither
6 // Copyright: (c) 2002 Markus Greither
7 // Licence: wxWindows licence
8 /////////////////////////////////////////////////////////////////////////////
10 // For compilers that support precompilation, includes "wx.h".
11 #include "wx/wxprec.h"
17 #if wxUSE_XRC && wxUSE_DIRDLG
19 #include "wx/xrc/xh_gdctl.h"
22 #include "wx/textctrl.h"
25 #include "wx/dirctrl.h"
27 IMPLEMENT_DYNAMIC_CLASS(wxGenericDirCtrlXmlHandler
, wxXmlResourceHandler
)
29 wxGenericDirCtrlXmlHandler::wxGenericDirCtrlXmlHandler()
30 : wxXmlResourceHandler()
32 XRC_ADD_STYLE(wxDIRCTRL_DIR_ONLY
);
33 XRC_ADD_STYLE(wxDIRCTRL_3D_INTERNAL
);
34 XRC_ADD_STYLE(wxDIRCTRL_SELECT_FIRST
);
35 XRC_ADD_STYLE(wxDIRCTRL_SHOW_FILTERS
);
36 XRC_ADD_STYLE(wxDIRCTRL_EDIT_LABELS
);
37 XRC_ADD_STYLE(wxDIRCTRL_MULTIPLE
);
41 wxObject
*wxGenericDirCtrlXmlHandler::DoCreateResource()
43 XRC_MAKE_INSTANCE(ctrl
, wxGenericDirCtrl
)
45 ctrl
->Create(m_parentAsWindow
,
47 GetText(wxT("defaultfolder")),
48 GetPosition(), GetSize(),
50 GetText(wxT("filter")),
51 (int)GetLong(wxT("defaultfilter")),
59 bool wxGenericDirCtrlXmlHandler::CanHandle(wxXmlNode
*node
)
61 return IsOfClass(node
, wxT("wxGenericDirCtrl"));
64 #endif // wxUSE_XRC && wxUSE_DIRDLG