Debian Codegraph @

wxcrafter/controls/static_line_wrapper.cpp

raw
1 #include "static_line_wrapper.h"
2 #include "allocator_mgr.h"
3 #include <wx/statline.h>
4
5 StaticLineWrapper::StaticLineWrapper()
6 : wxcWidget(ID_WXSTATICLINE)
7 {
8 SetPropertyString(_("Common Settings"), "wxStaticLine");
9 PREPEND_STYLE(wxLI_HORIZONTAL, true);
10 PREPEND_STYLE(wxLI_VERTICAL, false);
11
12 EnableSizerFlag(wxT("wxEXPAND"), true);
13
14 m_namePattern = wxT("m_staticLine");
15 SetName(GenerateName());
16 }
17
18 StaticLineWrapper::~StaticLineWrapper() {}
19
20 wxcWidget* StaticLineWrapper::Clone() const { return new StaticLineWrapper(); }
21
22 wxString StaticLineWrapper::CppCtorCode() const
23 {
24 // m_staticline1 = new wxStaticLine( m_panel11, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLI_HORIZONTAL );
25 wxString code;
26 code << GetName() << wxT(" = new wxStaticLine(") << GetWindowParent() << wxT(", ") << WindowID() << wxT(", ")
27 << wxT("wxDefaultPosition, ") << SizeAsString() << wxT(", ") << StyleFlags(wxT("0")) << wxT(");\n");
28 code << CPPCommonAttributes();
29 return code;
30 }
31
32 void StaticLineWrapper::GetIncludeFile(wxArrayString& headers) const { headers.Add(wxT("#include <wx/statline.h>")); }
33
34 wxString StaticLineWrapper::GetWxClassName() const { return wxT("wxStaticLine"); }
35
36 void StaticLineWrapper::ToXRC(wxString& text, XRC_TYPE type) const
37 {
38 text << XRCPrefix() << XRCStyle() << XRCCommonAttributes() << XRCSuffix();
39 }