1 ///////////////////////////////////////////////////////////////////////////
2 // C++ code generated with wxFormBuilder (version 3.9.0 Nov  1 2020)
3 // http://www.wxformbuilder.org/
4 //
5 // PLEASE DO *NOT* EDIT THIS FILE!
6 ///////////////////////////////////////////////////////////////////////////
7 
8 #include "dialog_config_equfiles_base.h"
9 
10 ///////////////////////////////////////////////////////////////////////////
11 
DIALOG_CONFIG_EQUFILES_BASE(wxWindow * parent,wxWindowID id,const wxString & title,const wxPoint & pos,const wxSize & size,long style)12 DIALOG_CONFIG_EQUFILES_BASE::DIALOG_CONFIG_EQUFILES_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( wxDefaultSize, wxDefaultSize );
15 
16 	wxBoxSizer* bMainSizer;
17 	bMainSizer = new wxBoxSizer( wxVERTICAL );
18 
19 	wxStaticBoxSizer* sbEquivChoiceSizer;
20 	sbEquivChoiceSizer = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Symbol Footprint Association Files (.equ)") ), wxHORIZONTAL );
21 
22 	wxBoxSizer* bSizerFlist;
23 	bSizerFlist = new wxBoxSizer( wxVERTICAL );
24 
25 	m_ListEquiv = new wxListBox( sbEquivChoiceSizer->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, 0, NULL, wxLB_EXTENDED|wxLB_HSCROLL|wxLB_NEEDED_SB|wxLB_SINGLE );
26 	m_ListEquiv->SetMinSize( wxSize( 350,-1 ) );
27 
28 	bSizerFlist->Add( m_ListEquiv, 1, wxBOTTOM|wxEXPAND|wxLEFT|wxRIGHT, 5 );
29 
30 
31 	sbEquivChoiceSizer->Add( bSizerFlist, 1, wxEXPAND, 5 );
32 
33 	wxBoxSizer* bSizerButtons;
34 	bSizerButtons = new wxBoxSizer( wxVERTICAL );
35 
36 	m_buttonAddEqu = new wxButton( sbEquivChoiceSizer->GetStaticBox(), ID_ADD_EQU, _("Add"), wxDefaultPosition, wxDefaultSize, 0 );
37 	bSizerButtons->Add( m_buttonAddEqu, 0, wxBOTTOM|wxEXPAND|wxLEFT|wxRIGHT, 5 );
38 
39 	m_buttonRemoveEqu = new wxButton( sbEquivChoiceSizer->GetStaticBox(), ID_REMOVE_EQU, _("Remove"), wxDefaultPosition, wxDefaultSize, 0 );
40 	bSizerButtons->Add( m_buttonRemoveEqu, 0, wxBOTTOM|wxEXPAND|wxLEFT|wxRIGHT, 5 );
41 
42 	m_buttonMoveUp = new wxButton( sbEquivChoiceSizer->GetStaticBox(), ID_EQU_UP, _("Move Up"), wxDefaultPosition, wxDefaultSize, 0 );
43 	bSizerButtons->Add( m_buttonMoveUp, 0, wxBOTTOM|wxEXPAND|wxLEFT|wxRIGHT, 5 );
44 
45 	m_buttonMoveDown = new wxButton( sbEquivChoiceSizer->GetStaticBox(), ID_EQU_DOWN, _("Move Down"), wxDefaultPosition, wxDefaultSize, 0 );
46 	bSizerButtons->Add( m_buttonMoveDown, 0, wxBOTTOM|wxEXPAND|wxLEFT|wxRIGHT, 5 );
47 
48 	m_buttonEdit = new wxButton( sbEquivChoiceSizer->GetStaticBox(), wxID_ANY, _("Edit File"), wxDefaultPosition, wxDefaultSize, 0 );
49 	bSizerButtons->Add( m_buttonEdit, 0, wxBOTTOM|wxEXPAND|wxLEFT|wxRIGHT, 5 );
50 
51 
52 	sbEquivChoiceSizer->Add( bSizerButtons, 0, wxALIGN_CENTER_VERTICAL, 5 );
53 
54 
55 	bMainSizer->Add( sbEquivChoiceSizer, 1, wxEXPAND|wxTOP|wxRIGHT|wxLEFT, 5 );
56 
57 	wxBoxSizer* bSizerLower;
58 	bSizerLower = new wxBoxSizer( wxHORIZONTAL );
59 
60 	wxBoxSizer* bSizerEnvVar;
61 	bSizerEnvVar = new wxBoxSizer( wxVERTICAL );
62 
63 	m_staticText2 = new wxStaticText( this, wxID_ANY, _("Available environment variables for relative paths:"), wxDefaultPosition, wxDefaultSize, 0 );
64 	m_staticText2->Wrap( -1 );
65 	bSizerEnvVar->Add( m_staticText2, 0, wxTOP|wxRIGHT|wxLEFT, 5 );
66 
67 	m_gridEnvVars = new wxGrid( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, 0 );
68 
69 	// Grid
70 	m_gridEnvVars->CreateGrid( 2, 2 );
71 	m_gridEnvVars->EnableEditing( true );
72 	m_gridEnvVars->EnableGridLines( true );
73 	m_gridEnvVars->EnableDragGridSize( false );
74 	m_gridEnvVars->SetMargins( 0, 0 );
75 
76 	// Columns
77 	m_gridEnvVars->EnableDragColMove( false );
78 	m_gridEnvVars->EnableDragColSize( true );
79 	m_gridEnvVars->SetColLabelSize( 25 );
80 	m_gridEnvVars->SetColLabelValue( 0, _("Name") );
81 	m_gridEnvVars->SetColLabelValue( 1, _("Value") );
82 	m_gridEnvVars->SetColLabelAlignment( wxALIGN_CENTER, wxALIGN_CENTER );
83 
84 	// Rows
85 	m_gridEnvVars->AutoSizeRows();
86 	m_gridEnvVars->EnableDragRowSize( true );
87 	m_gridEnvVars->SetRowLabelSize( 30 );
88 	m_gridEnvVars->SetRowLabelAlignment( wxALIGN_CENTER, wxALIGN_CENTER );
89 
90 	// Label Appearance
91 
92 	// Cell Defaults
93 	m_gridEnvVars->SetDefaultCellAlignment( wxALIGN_LEFT, wxALIGN_TOP );
94 	bSizerEnvVar->Add( m_gridEnvVars, 0, wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT, 5 );
95 
96 
97 	bSizerLower->Add( bSizerEnvVar, 1, wxEXPAND, 5 );
98 
99 	wxString m_rbPathOptionChoiceChoices[] = { _("Absolute"), _("Relative") };
100 	int m_rbPathOptionChoiceNChoices = sizeof( m_rbPathOptionChoiceChoices ) / sizeof( wxString );
101 	m_rbPathOptionChoice = new wxRadioBox( this, wxID_ANY, _("Path Type"), wxDefaultPosition, wxDefaultSize, m_rbPathOptionChoiceNChoices, m_rbPathOptionChoiceChoices, 1, wxRA_SPECIFY_COLS );
102 	m_rbPathOptionChoice->SetSelection( 1 );
103 	bSizerLower->Add( m_rbPathOptionChoice, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5 );
104 
105 
106 	bMainSizer->Add( bSizerLower, 0, wxEXPAND, 5 );
107 
108 	m_staticline2 = new wxStaticLine( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLI_HORIZONTAL );
109 	bMainSizer->Add( m_staticline2, 0, wxEXPAND|wxALL, 5 );
110 
111 	m_sdbSizer = new wxStdDialogButtonSizer();
112 	m_sdbSizerOK = new wxButton( this, wxID_OK );
113 	m_sdbSizer->AddButton( m_sdbSizerOK );
114 	m_sdbSizerCancel = new wxButton( this, wxID_CANCEL );
115 	m_sdbSizer->AddButton( m_sdbSizerCancel );
116 	m_sdbSizer->Realize();
117 
118 	bMainSizer->Add( m_sdbSizer, 0, wxALL|wxALIGN_RIGHT, 5 );
119 
120 
121 	this->SetSizer( bMainSizer );
122 	this->Layout();
123 	bMainSizer->Fit( this );
124 
125 	this->Centre( wxBOTH );
126 
127 	// Connect Events
128 	this->Connect( wxEVT_CLOSE_WINDOW, wxCloseEventHandler( DIALOG_CONFIG_EQUFILES_BASE::OnCloseWindow ) );
129 	m_buttonAddEqu->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_CONFIG_EQUFILES_BASE::OnAddFiles ), NULL, this );
130 	m_buttonRemoveEqu->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_CONFIG_EQUFILES_BASE::OnRemoveFiles ), NULL, this );
131 	m_buttonMoveUp->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_CONFIG_EQUFILES_BASE::OnButtonMoveUp ), NULL, this );
132 	m_buttonMoveDown->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_CONFIG_EQUFILES_BASE::OnButtonMoveDown ), NULL, this );
133 	m_buttonEdit->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_CONFIG_EQUFILES_BASE::OnEditEquFile ), NULL, this );
134 	m_sdbSizerOK->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_CONFIG_EQUFILES_BASE::OnOkClick ), NULL, this );
135 }
136 
~DIALOG_CONFIG_EQUFILES_BASE()137 DIALOG_CONFIG_EQUFILES_BASE::~DIALOG_CONFIG_EQUFILES_BASE()
138 {
139 	// Disconnect Events
140 	this->Disconnect( wxEVT_CLOSE_WINDOW, wxCloseEventHandler( DIALOG_CONFIG_EQUFILES_BASE::OnCloseWindow ) );
141 	m_buttonAddEqu->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_CONFIG_EQUFILES_BASE::OnAddFiles ), NULL, this );
142 	m_buttonRemoveEqu->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_CONFIG_EQUFILES_BASE::OnRemoveFiles ), NULL, this );
143 	m_buttonMoveUp->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_CONFIG_EQUFILES_BASE::OnButtonMoveUp ), NULL, this );
144 	m_buttonMoveDown->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_CONFIG_EQUFILES_BASE::OnButtonMoveDown ), NULL, this );
145 	m_buttonEdit->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_CONFIG_EQUFILES_BASE::OnEditEquFile ), NULL, this );
146 	m_sdbSizerOK->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_CONFIG_EQUFILES_BASE::OnOkClick ), NULL, this );
147 
148 }
149