KiCad PCB EDA Suite
dialog_template_selector_base.cpp
Go to the documentation of this file.
1
2// C++ code generated with wxFormBuilder (version Oct 26 2018)
3// http://www.wxformbuilder.org/
4//
5// PLEASE DO *NOT* EDIT THIS FILE!
7
9
11
12DIALOG_TEMPLATE_SELECTOR_BASE::DIALOG_TEMPLATE_SELECTOR_BASE( wxWindow* parent, wxWindowID id, const wxString& title, const wxPoint& pos, const wxSize& size, long style ) : DIALOG_SHIM( parent, id, title, pos, size, style )
13{
14 this->SetSizeHints( wxSize( -1,-1 ), wxDefaultSize );
15
16 wxBoxSizer* bmainSizer;
17 bmainSizer = new wxBoxSizer( wxVERTICAL );
18
19 wxBoxSizer* bsizerTemplateSelector;
20 bsizerTemplateSelector = new wxBoxSizer( wxHORIZONTAL );
21
22 m_staticTextTpath = new wxStaticText( this, wxID_ANY, _("Folder:"), wxDefaultPosition, wxDefaultSize, 0 );
23 m_staticTextTpath->Wrap( -1 );
24 bsizerTemplateSelector->Add( m_staticTextTpath, 0, wxALIGN_CENTER_VERTICAL|wxRIGHT|wxLEFT, 5 );
25
26 m_tcTemplatePath = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, wxTE_PROCESS_ENTER );
27 bsizerTemplateSelector->Add( m_tcTemplatePath, 1, wxALIGN_CENTER_VERTICAL|wxRIGHT, 2 );
28
29 m_browseButton = new wxBitmapButton( this, wxID_ANY, wxNullBitmap, wxDefaultPosition, wxDefaultSize, wxBU_AUTODRAW|0 );
30 bsizerTemplateSelector->Add( m_browseButton, 0, wxTOP|wxBOTTOM|wxRIGHT, 5 );
31
32 m_reloadButton = new wxBitmapButton( this, wxID_ANY, wxNullBitmap, wxDefaultPosition, wxDefaultSize, wxBU_AUTODRAW|0 );
33 bsizerTemplateSelector->Add( m_reloadButton, 0, wxALL, 5 );
34
35
36 bmainSizer->Add( bsizerTemplateSelector, 0, wxEXPAND|wxTOP|wxRIGHT|wxLEFT, 5 );
37
38 m_notebook = new wxNotebook( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, 0 );
39 m_notebook->SetMinSize( wxSize( -1,185 ) );
40
41
42 bmainSizer->Add( m_notebook, 0, wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT, 5 );
43
44 m_htmlWin = new HTML_WINDOW( this, wxID_ANY, wxDefaultPosition, wxSize( -1,-1 ), wxHW_SCROLLBAR_AUTO );
45 m_htmlWin->SetMinSize( wxSize( 750,380 ) );
46
47 bmainSizer->Add( m_htmlWin, 1, wxBOTTOM|wxRIGHT|wxLEFT|wxEXPAND, 12 );
48
49 m_staticline = new wxStaticLine( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLI_HORIZONTAL );
50 bmainSizer->Add( m_staticline, 0, wxEXPAND | wxALL, 5 );
51
52 m_sdbSizer = new wxStdDialogButtonSizer();
53 m_sdbSizerOK = new wxButton( this, wxID_OK );
54 m_sdbSizer->AddButton( m_sdbSizerOK );
55 m_sdbSizerCancel = new wxButton( this, wxID_CANCEL );
56 m_sdbSizer->AddButton( m_sdbSizerCancel );
57 m_sdbSizer->Realize();
58
59 bmainSizer->Add( m_sdbSizer, 0, wxALL|wxEXPAND, 5 );
60
61
62 this->SetSizer( bmainSizer );
63 this->Layout();
64 bmainSizer->Fit( this );
65
66 this->Centre( wxBOTH );
67
68 // Connect Events
69 m_browseButton->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_TEMPLATE_SELECTOR_BASE::onDirectoryBrowseClicked ), NULL, this );
70 m_reloadButton->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_TEMPLATE_SELECTOR_BASE::onReload ), NULL, this );
71 m_notebook->Connect( wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGED, wxNotebookEventHandler( DIALOG_TEMPLATE_SELECTOR_BASE::OnPageChange ), NULL, this );
72 m_htmlWin->Connect( wxEVT_COMMAND_HTML_LINK_CLICKED, wxHtmlLinkEventHandler( DIALOG_TEMPLATE_SELECTOR_BASE::OnHtmlLinkActivated ), NULL, this );
73}
74
76{
77 // Disconnect Events
78 m_browseButton->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_TEMPLATE_SELECTOR_BASE::onDirectoryBrowseClicked ), NULL, this );
79 m_reloadButton->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_TEMPLATE_SELECTOR_BASE::onReload ), NULL, this );
80 m_notebook->Disconnect( wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGED, wxNotebookEventHandler( DIALOG_TEMPLATE_SELECTOR_BASE::OnPageChange ), NULL, this );
81 m_htmlWin->Disconnect( wxEVT_COMMAND_HTML_LINK_CLICKED, wxHtmlLinkEventHandler( DIALOG_TEMPLATE_SELECTOR_BASE::OnHtmlLinkActivated ), NULL, this );
82
83}
84
85TEMPLATE_SELECTION_PANEL_BASE::TEMPLATE_SELECTION_PANEL_BASE( wxWindow* parent, wxWindowID id, const wxPoint& pos, const wxSize& size, long style, const wxString& name ) : wxPanel( parent, id, pos, size, style, name )
86{
87 m_SizerBase = new wxBoxSizer( wxHORIZONTAL );
88
89 wxBoxSizer* bSizerMargins;
90 bSizerMargins = new wxBoxSizer( wxVERTICAL );
91
92 m_scrolledWindow = new wxScrolledWindow( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxALWAYS_SHOW_SB|wxHSCROLL );
93 m_scrolledWindow->SetScrollRate( 5, 5 );
94 m_SizerChoice = new wxGridSizer( 1, 0, 0, 0 );
95
96
98 m_scrolledWindow->Layout();
100 bSizerMargins->Add( m_scrolledWindow, 1, wxEXPAND|wxLEFT, 5 );
101
102
103 m_SizerBase->Add( bSizerMargins, 1, wxEXPAND|wxBOTTOM|wxLEFT, 5 );
104
105
106 this->SetSizer( m_SizerBase );
107 this->Layout();
108}
109
111{
112}
113
114TEMPLATE_WIDGET_BASE::TEMPLATE_WIDGET_BASE( wxWindow* parent, wxWindowID id, const wxPoint& pos, const wxSize& size, long style, const wxString& name ) : wxPanel( parent, id, pos, size, style, name )
115{
116 this->SetMinSize( wxSize( 108,-1 ) );
117 this->SetMaxSize( wxSize( 108,-1 ) );
118
119 wxBoxSizer* bSizerMain;
120 bSizerMain = new wxBoxSizer( wxVERTICAL );
121
122 m_bitmapIcon = new wxStaticBitmap( this, wxID_ANY, wxNullBitmap, wxDefaultPosition, wxSize( 64,64 ), 0 );
123 m_bitmapIcon->SetMinSize( wxSize( 64,64 ) );
124
125 bSizerMain->Add( m_bitmapIcon, 0, wxALL|wxALIGN_CENTER_HORIZONTAL, 5 );
126
127 m_staticTitle = new wxStaticText( this, wxID_ANY, _("Project Template Title"), wxDefaultPosition, wxDefaultSize, wxALIGN_CENTER_HORIZONTAL );
128 m_staticTitle->Wrap( 100 );
129 bSizerMain->Add( m_staticTitle, 1, wxALIGN_CENTER_HORIZONTAL|wxBOTTOM|wxRIGHT|wxLEFT, 2 );
130
131
132 this->SetSizer( bSizerMain );
133 this->Layout();
134}
135
137{
138}
const char * name
Definition: DXF_plotter.cpp:56
Dialog helper object to sit in the inheritance tree between wxDialog and any class written by wxFormB...
Definition: dialog_shim.h:83
virtual void OnPageChange(wxNotebookEvent &event)
DIALOG_TEMPLATE_SELECTOR_BASE(wxWindow *parent, wxWindowID id=wxID_ANY, const wxString &title=_("Project Template Selector"), const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxSize(-1,-1), long style=wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER)
virtual void onReload(wxCommandEvent &event)
virtual void onDirectoryBrowseClicked(wxCommandEvent &event)
virtual void OnHtmlLinkActivated(wxHtmlLinkEvent &event)
Add dark theme support to wxHtmlWindow.
Definition: html_window.h:34
TEMPLATE_SELECTION_PANEL_BASE(wxWindow *parent, wxWindowID id=wxID_ANY, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxSize(-1, 140), long style=wxTAB_TRAVERSAL|wxBORDER_NONE, const wxString &name=wxEmptyString)
TEMPLATE_WIDGET_BASE(wxWindow *parent, wxWindowID id=wxID_ANY, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxSize(108,-1), long style=wxTAB_TRAVERSAL, const wxString &name=wxEmptyString)
#define _(s)