KiCad PCB EDA Suite
dialog_symbol_properties_base.cpp
Go to the documentation of this file.
1 // C++ code generated with wxFormBuilder (version Oct 26 2018)
3 // http://www.wxformbuilder.org/
4 //
5 // PLEASE DO *NOT* EDIT THIS FILE!
7 
8 #include "widgets/wx_grid.h"
9 
11 
13 
14 DIALOG_SYMBOL_PROPERTIES_BASE::DIALOG_SYMBOL_PROPERTIES_BASE( wxWindow* parent, wxWindowID id, const wxString& title, const wxPoint& pos, const wxSize& size, long style ) : DIALOG_SHIM( parent, id, title, pos, size, style )
15 {
16  this->SetSizeHints( wxDefaultSize, wxDefaultSize );
17 
18  wxBoxSizer* mainSizer;
19  mainSizer = new wxBoxSizer( wxVERTICAL );
20 
21  m_notebook1 = new wxNotebook( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, 0 );
22  generalPage = new wxPanel( m_notebook1, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL );
23  wxBoxSizer* generalPageSizer;
24  generalPageSizer = new wxBoxSizer( wxVERTICAL );
25 
26  wxStaticBoxSizer* sbFields;
27  sbFields = new wxStaticBoxSizer( new wxStaticBox( generalPage, wxID_ANY, _("Fields") ), wxVERTICAL );
28 
29  m_fieldsGrid = new WX_GRID( sbFields->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, 0 );
30 
31  // Grid
32  m_fieldsGrid->CreateGrid( 4, 11 );
33  m_fieldsGrid->EnableEditing( true );
34  m_fieldsGrid->EnableGridLines( true );
35  m_fieldsGrid->EnableDragGridSize( false );
36  m_fieldsGrid->SetMargins( 0, 0 );
37 
38  // Columns
39  m_fieldsGrid->SetColSize( 0, 72 );
40  m_fieldsGrid->SetColSize( 1, 120 );
41  m_fieldsGrid->SetColSize( 2, 48 );
42  m_fieldsGrid->SetColSize( 3, 72 );
43  m_fieldsGrid->SetColSize( 4, 72 );
44  m_fieldsGrid->SetColSize( 5, 48 );
45  m_fieldsGrid->SetColSize( 6, 48 );
46  m_fieldsGrid->SetColSize( 7, 84 );
47  m_fieldsGrid->SetColSize( 8, 84 );
48  m_fieldsGrid->SetColSize( 9, 84 );
49  m_fieldsGrid->SetColSize( 10, 84 );
50  m_fieldsGrid->EnableDragColMove( false );
51  m_fieldsGrid->EnableDragColSize( true );
53  m_fieldsGrid->SetColLabelValue( 0, _("Name") );
54  m_fieldsGrid->SetColLabelValue( 1, _("Value") );
55  m_fieldsGrid->SetColLabelValue( 2, _("Show") );
56  m_fieldsGrid->SetColLabelValue( 3, _("H Align") );
57  m_fieldsGrid->SetColLabelValue( 4, _("V Align") );
58  m_fieldsGrid->SetColLabelValue( 5, _("Italic") );
59  m_fieldsGrid->SetColLabelValue( 6, _("Bold") );
60  m_fieldsGrid->SetColLabelValue( 7, _("Text Size") );
61  m_fieldsGrid->SetColLabelValue( 8, _("Orientation") );
62  m_fieldsGrid->SetColLabelValue( 9, _("X Position") );
63  m_fieldsGrid->SetColLabelValue( 10, _("Y Position") );
64  m_fieldsGrid->SetColLabelAlignment( wxALIGN_CENTER, wxALIGN_CENTER );
65 
66  // Rows
67  m_fieldsGrid->EnableDragRowSize( true );
68  m_fieldsGrid->SetRowLabelSize( 0 );
69  m_fieldsGrid->SetRowLabelAlignment( wxALIGN_CENTER, wxALIGN_CENTER );
70 
71  // Label Appearance
72 
73  // Cell Defaults
74  m_fieldsGrid->SetDefaultCellAlignment( wxALIGN_LEFT, wxALIGN_TOP );
75  m_fieldsGrid->SetMinSize( wxSize( -1,180 ) );
76 
77  sbFields->Add( m_fieldsGrid, 1, wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT, 5 );
78 
79  wxBoxSizer* bButtonSize;
80  bButtonSize = new wxBoxSizer( wxHORIZONTAL );
81 
82  m_bpAdd = new wxBitmapButton( sbFields->GetStaticBox(), wxID_ANY, wxNullBitmap, wxDefaultPosition, wxDefaultSize, wxBU_AUTODRAW|0 );
83  m_bpAdd->SetToolTip( _("Add field") );
84 
85  bButtonSize->Add( m_bpAdd, 0, wxALIGN_CENTER_VERTICAL|wxRIGHT, 5 );
86 
87  m_bpMoveUp = new wxBitmapButton( sbFields->GetStaticBox(), wxID_ANY, wxNullBitmap, wxDefaultPosition, wxDefaultSize, wxBU_AUTODRAW|0 );
88  m_bpMoveUp->SetToolTip( _("Move up") );
89 
90  bButtonSize->Add( m_bpMoveUp, 0, wxALIGN_CENTER_VERTICAL|wxRIGHT, 5 );
91 
92  m_bpMoveDown = new wxBitmapButton( sbFields->GetStaticBox(), wxID_ANY, wxNullBitmap, wxDefaultPosition, wxDefaultSize, wxBU_AUTODRAW|0 );
93  m_bpMoveDown->SetToolTip( _("Move down") );
94 
95  bButtonSize->Add( m_bpMoveDown, 0, wxALIGN_CENTER_VERTICAL|wxRIGHT, 5 );
96 
97 
98  bButtonSize->Add( 20, 0, 0, wxEXPAND, 10 );
99 
100  m_bpDelete = new wxBitmapButton( sbFields->GetStaticBox(), wxID_ANY, wxNullBitmap, wxDefaultPosition, wxDefaultSize, wxBU_AUTODRAW|0 );
101  m_bpDelete->SetToolTip( _("Delete field") );
102 
103  bButtonSize->Add( m_bpDelete, 0, wxALIGN_CENTER_VERTICAL|wxRIGHT, 5 );
104 
105 
106  bButtonSize->Add( 0, 0, 1, wxEXPAND, 5 );
107 
108 
109  sbFields->Add( bButtonSize, 0, wxALL|wxEXPAND, 5 );
110 
111 
112  generalPageSizer->Add( sbFields, 1, wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT, 5 );
113 
114  wxBoxSizer* bLowerSizer;
115  bLowerSizer = new wxBoxSizer( wxHORIZONTAL );
116 
117  wxStaticBoxSizer* sbGeneralProps;
118  sbGeneralProps = new wxStaticBoxSizer( new wxStaticBox( generalPage, wxID_ANY, _("General") ), wxHORIZONTAL );
119 
120  wxGridBagSizer* gbSizer1;
121  gbSizer1 = new wxGridBagSizer( 3, 3 );
122  gbSizer1->SetFlexibleDirection( wxBOTH );
123  gbSizer1->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED );
124  gbSizer1->SetEmptyCellSize( wxSize( -1,10 ) );
125 
126  m_unitLabel = new wxStaticText( sbGeneralProps->GetStaticBox(), wxID_ANY, _("Unit:"), wxDefaultPosition, wxDefaultSize, 0 );
127  m_unitLabel->Wrap( -1 );
128  gbSizer1->Add( m_unitLabel, wxGBPosition( 0, 0 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL|wxLEFT|wxRIGHT, 5 );
129 
130  wxArrayString m_unitChoiceChoices;
131  m_unitChoice = new wxChoice( sbGeneralProps->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, m_unitChoiceChoices, 0 );
132  m_unitChoice->SetSelection( 0 );
133  m_unitChoice->SetMinSize( wxSize( 100,-1 ) );
134 
135  gbSizer1->Add( m_unitChoice, wxGBPosition( 0, 1 ), wxGBSpan( 1, 1 ), wxEXPAND|wxLEFT|wxRIGHT, 5 );
136 
137  m_cbAlternateSymbol = new wxCheckBox( sbGeneralProps->GetStaticBox(), wxID_ANY, _("Alternate symbol (DeMorgan)"), wxDefaultPosition, wxDefaultSize, 0 );
138  m_cbAlternateSymbol->SetToolTip( _("Use the alternate shape of this symbol.\nFor gates, this is the \"De Morgan\" conversion") );
139 
140  gbSizer1->Add( m_cbAlternateSymbol, wxGBPosition( 1, 0 ), wxGBSpan( 1, 2 ), wxBOTTOM|wxEXPAND|wxLEFT|wxRIGHT, 5 );
141 
142  m_orientationLabel = new wxStaticText( sbGeneralProps->GetStaticBox(), wxID_ANY, _("Angle:"), wxDefaultPosition, wxDefaultSize, 0 );
143  m_orientationLabel->Wrap( -1 );
144  gbSizer1->Add( m_orientationLabel, wxGBPosition( 3, 0 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL|wxLEFT|wxRIGHT|wxTOP, 5 );
145 
146  wxString m_orientationCtrlChoices[] = { _("0"), _("+90"), _("-90"), _("180") };
147  int m_orientationCtrlNChoices = sizeof( m_orientationCtrlChoices ) / sizeof( wxString );
148  m_orientationCtrl = new wxChoice( sbGeneralProps->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, m_orientationCtrlNChoices, m_orientationCtrlChoices, 0 );
149  m_orientationCtrl->SetSelection( 0 );
150  gbSizer1->Add( m_orientationCtrl, wxGBPosition( 3, 1 ), wxGBSpan( 1, 1 ), wxEXPAND|wxLEFT|wxRIGHT, 5 );
151 
152  m_mirrorLabel = new wxStaticText( sbGeneralProps->GetStaticBox(), wxID_ANY, _("Mirror:"), wxDefaultPosition, wxDefaultSize, 0 );
153  m_mirrorLabel->Wrap( -1 );
154  gbSizer1->Add( m_mirrorLabel, wxGBPosition( 4, 0 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL|wxLEFT|wxRIGHT, 5 );
155 
156  wxString m_mirrorCtrlChoices[] = { _("Not mirrored"), _("Around X axis"), _("Around Y axis") };
157  int m_mirrorCtrlNChoices = sizeof( m_mirrorCtrlChoices ) / sizeof( wxString );
158  m_mirrorCtrl = new wxChoice( sbGeneralProps->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, m_mirrorCtrlNChoices, m_mirrorCtrlChoices, 0 );
159  m_mirrorCtrl->SetSelection( 0 );
160  gbSizer1->Add( m_mirrorCtrl, wxGBPosition( 4, 1 ), wxGBSpan( 1, 1 ), wxEXPAND|wxLEFT|wxRIGHT, 5 );
161 
162 
163  gbSizer1->AddGrowableCol( 1 );
164 
165  sbGeneralProps->Add( gbSizer1, 1, wxEXPAND, 5 );
166 
167 
168  bLowerSizer->Add( sbGeneralProps, 1, wxEXPAND|wxRIGHT|wxLEFT, 5 );
169 
170  wxBoxSizer* bMiddleCol;
171  bMiddleCol = new wxBoxSizer( wxVERTICAL );
172 
173  wxStaticBoxSizer* sbSizerPinTextOpts;
174  sbSizerPinTextOpts = new wxStaticBoxSizer( new wxStaticBox( generalPage, wxID_ANY, _("Pin Text") ), wxVERTICAL );
175 
176  m_ShowPinNumButt = new wxCheckBox( sbSizerPinTextOpts->GetStaticBox(), wxID_ANY, _("Show pin numbers"), wxDefaultPosition, wxDefaultSize, 0 );
177  m_ShowPinNumButt->SetValue(true);
178  m_ShowPinNumButt->SetToolTip( _("Show or hide pin numbers") );
179 
180  sbSizerPinTextOpts->Add( m_ShowPinNumButt, 0, wxRIGHT|wxLEFT, 4 );
181 
182  m_ShowPinNameButt = new wxCheckBox( sbSizerPinTextOpts->GetStaticBox(), wxID_ANY, _("Show pin names"), wxDefaultPosition, wxDefaultSize, 0 );
183  m_ShowPinNameButt->SetValue(true);
184  m_ShowPinNameButt->SetToolTip( _("Show or hide pin names") );
185 
186  sbSizerPinTextOpts->Add( m_ShowPinNameButt, 0, wxALL, 4 );
187 
188 
189  bMiddleCol->Add( sbSizerPinTextOpts, 1, wxEXPAND|wxRIGHT|wxLEFT, 5 );
190 
191  wxStaticBoxSizer* sbAttributes;
192  sbAttributes = new wxStaticBoxSizer( new wxStaticBox( generalPage, wxID_ANY, _("Attributes") ), wxVERTICAL );
193 
194  m_cbExcludeFromBom = new wxCheckBox( sbAttributes->GetStaticBox(), wxID_ANY, _("Exclude from bill of materials"), wxDefaultPosition, wxDefaultSize, 0 );
195  m_cbExcludeFromBom->SetToolTip( _("This is useful for adding symbols for board footprints such as fiducials\nand logos that you do not want to appear in the bill of materials export") );
196 
197  sbAttributes->Add( m_cbExcludeFromBom, 0, wxBOTTOM|wxRIGHT|wxLEFT, 4 );
198 
199  m_cbExcludeFromBoard = new wxCheckBox( sbAttributes->GetStaticBox(), wxID_ANY, _("Exclude from board"), wxDefaultPosition, wxDefaultSize, 0 );
200  m_cbExcludeFromBoard->SetToolTip( _("This is useful for adding symbols that only get exported to the bill of materials but\nnot required to layout the board such as mechanical fasteners and enclosures") );
201 
202  sbAttributes->Add( m_cbExcludeFromBoard, 0, wxBOTTOM|wxRIGHT|wxLEFT, 4 );
203 
204 
205  bMiddleCol->Add( sbAttributes, 0, wxEXPAND|wxTOP|wxRIGHT|wxLEFT, 5 );
206 
207 
208  bLowerSizer->Add( bMiddleCol, 1, wxEXPAND|wxRIGHT|wxLEFT, 5 );
209 
210  wxBoxSizer* buttonsSizer;
211  buttonsSizer = new wxBoxSizer( wxVERTICAL );
212 
213  m_updateSymbolBtn = new wxButton( generalPage, wxID_ANY, _("Update Symbol from Library..."), wxDefaultPosition, wxDefaultSize, 0 );
214  buttonsSizer->Add( m_updateSymbolBtn, 0, wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT, 5 );
215 
216  m_changeSymbolBtn = new wxButton( generalPage, wxID_ANY, _("Change Symbol..."), wxDefaultPosition, wxDefaultSize, 0 );
217  buttonsSizer->Add( m_changeSymbolBtn, 0, wxEXPAND|wxALL, 5 );
218 
219  m_editSchematicSymbolBtn = new wxButton( generalPage, wxID_ANY, _("Edit Symbol..."), wxDefaultPosition, wxDefaultSize, 0 );
220  buttonsSizer->Add( m_editSchematicSymbolBtn, 0, wxEXPAND|wxALL, 5 );
221 
222 
223  buttonsSizer->Add( 0, 20, 0, wxEXPAND, 5 );
224 
225  m_editLibrarySymbolBtn = new wxButton( generalPage, wxID_ANY, _("Edit Library Symbol..."), wxDefaultPosition, wxDefaultSize, 0 );
226  buttonsSizer->Add( m_editLibrarySymbolBtn, 0, wxEXPAND|wxTOP|wxRIGHT|wxLEFT, 5 );
227 
228 
229  bLowerSizer->Add( buttonsSizer, 1, wxEXPAND|wxALL, 5 );
230 
231 
232  generalPageSizer->Add( bLowerSizer, 0, wxEXPAND|wxTOP|wxBOTTOM, 5 );
233 
234 
235  generalPage->SetSizer( generalPageSizer );
236  generalPage->Layout();
237  generalPageSizer->Fit( generalPage );
238  m_notebook1->AddPage( generalPage, _("General"), true );
239  m_pinTablePage = new wxPanel( m_notebook1, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL );
240  wxBoxSizer* pinTableSizer;
241  pinTableSizer = new wxBoxSizer( wxVERTICAL );
242 
243  wxBoxSizer* bMargins;
244  bMargins = new wxBoxSizer( wxVERTICAL );
245 
246  m_pinGrid = new WX_GRID( m_pinTablePage, wxID_ANY, wxDefaultPosition, wxSize( -1,-1 ), 0 );
247 
248  // Grid
249  m_pinGrid->CreateGrid( 5, 5 );
250  m_pinGrid->EnableEditing( true );
251  m_pinGrid->EnableGridLines( true );
252  m_pinGrid->EnableDragGridSize( false );
253  m_pinGrid->SetMargins( 0, 0 );
254 
255  // Columns
256  m_pinGrid->SetColSize( 0, 160 );
257  m_pinGrid->SetColSize( 1, 160 );
258  m_pinGrid->SetColSize( 2, 160 );
259  m_pinGrid->SetColSize( 3, 140 );
260  m_pinGrid->SetColSize( 4, 140 );
261  m_pinGrid->EnableDragColMove( false );
262  m_pinGrid->EnableDragColSize( true );
263  m_pinGrid->SetColLabelSize( 24 );
264  m_pinGrid->SetColLabelValue( 0, _("Pin Number") );
265  m_pinGrid->SetColLabelValue( 1, _("Base Pin Name") );
266  m_pinGrid->SetColLabelValue( 2, _("Alternate Assignment") );
267  m_pinGrid->SetColLabelValue( 3, _("Electrical Type") );
268  m_pinGrid->SetColLabelValue( 4, _("Graphic Style") );
269  m_pinGrid->SetColLabelAlignment( wxALIGN_CENTER, wxALIGN_CENTER );
270 
271  // Rows
272  m_pinGrid->EnableDragRowSize( false );
273  m_pinGrid->SetRowLabelSize( 0 );
274  m_pinGrid->SetRowLabelAlignment( wxALIGN_CENTER, wxALIGN_CENTER );
275 
276  // Label Appearance
277 
278  // Cell Defaults
279  m_pinGrid->SetDefaultCellAlignment( wxALIGN_LEFT, wxALIGN_TOP );
280  m_pinGrid->SetMinSize( wxSize( 512,320 ) );
281 
282  bMargins->Add( m_pinGrid, 1, wxEXPAND|wxALL, 5 );
283 
284 
285  pinTableSizer->Add( bMargins, 1, wxEXPAND|wxRIGHT|wxLEFT, 5 );
286 
287 
288  m_pinTablePage->SetSizer( pinTableSizer );
289  m_pinTablePage->Layout();
290  pinTableSizer->Fit( m_pinTablePage );
291  m_notebook1->AddPage( m_pinTablePage, _("Alternate Pin Assignments"), false );
292 
293  mainSizer->Add( m_notebook1, 1, wxEXPAND|wxTOP|wxRIGHT|wxLEFT, 5 );
294 
295  wxBoxSizer* bSizerBottom;
296  bSizerBottom = new wxBoxSizer( wxHORIZONTAL );
297 
298  wxBoxSizer* bLibLink;
299  bLibLink = new wxBoxSizer( wxHORIZONTAL );
300 
301  m_libraryIDLabel = new wxStaticText( this, wxID_ANY, _("Library link:"), wxDefaultPosition, wxDefaultSize, 0 );
302  m_libraryIDLabel->Wrap( -1 );
303  bLibLink->Add( m_libraryIDLabel, 0, wxALIGN_CENTER_VERTICAL|wxLEFT, 5 );
304 
305  m_tcLibraryID = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, wxTE_READONLY|wxBORDER_NONE );
306  bLibLink->Add( m_tcLibraryID, 1, wxALIGN_CENTER_VERTICAL, 5 );
307 
308 
309  bSizerBottom->Add( bLibLink, 1, wxLEFT|wxEXPAND, 10 );
310 
311 
312  bSizerBottom->Add( 20, 0, 0, 0, 5 );
313 
314  m_spiceFieldsButton = new wxButton( this, wxID_ANY, _("Spice Model..."), wxDefaultPosition, wxDefaultSize, 0 );
315  bSizerBottom->Add( m_spiceFieldsButton, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5 );
316 
317  m_stdDialogButtonSizer = new wxStdDialogButtonSizer();
318  m_stdDialogButtonSizerOK = new wxButton( this, wxID_OK );
320  m_stdDialogButtonSizerCancel = new wxButton( this, wxID_CANCEL );
322  m_stdDialogButtonSizer->Realize();
323 
324  bSizerBottom->Add( m_stdDialogButtonSizer, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5 );
325 
326 
327  mainSizer->Add( bSizerBottom, 0, wxEXPAND, 5 );
328 
329 
330  this->SetSizer( mainSizer );
331  this->Layout();
332  mainSizer->Fit( this );
333 
334  // Connect Events
335  this->Connect( wxEVT_INIT_DIALOG, wxInitDialogEventHandler( DIALOG_SYMBOL_PROPERTIES_BASE::OnInitDlg ) );
336  this->Connect( wxEVT_UPDATE_UI, wxUpdateUIEventHandler( DIALOG_SYMBOL_PROPERTIES_BASE::OnUpdateUI ) );
337  m_fieldsGrid->Connect( wxEVT_GRID_EDITOR_SHOWN, wxGridEventHandler( DIALOG_SYMBOL_PROPERTIES_BASE::OnGridEditorShown ), NULL, this );
338  m_fieldsGrid->Connect( wxEVT_SIZE, wxSizeEventHandler( DIALOG_SYMBOL_PROPERTIES_BASE::OnSizeGrid ), NULL, this );
339  m_bpAdd->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SYMBOL_PROPERTIES_BASE::OnAddField ), NULL, this );
340  m_bpMoveUp->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SYMBOL_PROPERTIES_BASE::OnMoveUp ), NULL, this );
341  m_bpMoveDown->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SYMBOL_PROPERTIES_BASE::OnMoveDown ), NULL, this );
342  m_bpDelete->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SYMBOL_PROPERTIES_BASE::OnDeleteField ), NULL, this );
343  m_updateSymbolBtn->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SYMBOL_PROPERTIES_BASE::OnUpdateSymbol ), NULL, this );
344  m_changeSymbolBtn->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SYMBOL_PROPERTIES_BASE::OnExchangeSymbol ), NULL, this );
345  m_editSchematicSymbolBtn->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SYMBOL_PROPERTIES_BASE::OnEditSymbol ), NULL, this );
346  m_editLibrarySymbolBtn->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SYMBOL_PROPERTIES_BASE::OnEditLibrarySymbol ), NULL, this );
347  m_pinGrid->Connect( wxEVT_GRID_CELL_CHANGED, wxGridEventHandler( DIALOG_SYMBOL_PROPERTIES_BASE::OnPinTableCellEdited ), NULL, this );
348  m_spiceFieldsButton->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SYMBOL_PROPERTIES_BASE::OnEditSpiceModel ), NULL, this );
349  m_stdDialogButtonSizerCancel->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SYMBOL_PROPERTIES_BASE::OnCancelButtonClick ), NULL, this );
350 }
351 
353 {
354  // Disconnect Events
355  this->Disconnect( wxEVT_INIT_DIALOG, wxInitDialogEventHandler( DIALOG_SYMBOL_PROPERTIES_BASE::OnInitDlg ) );
356  this->Disconnect( wxEVT_UPDATE_UI, wxUpdateUIEventHandler( DIALOG_SYMBOL_PROPERTIES_BASE::OnUpdateUI ) );
357  m_fieldsGrid->Disconnect( wxEVT_GRID_EDITOR_SHOWN, wxGridEventHandler( DIALOG_SYMBOL_PROPERTIES_BASE::OnGridEditorShown ), NULL, this );
358  m_fieldsGrid->Disconnect( wxEVT_SIZE, wxSizeEventHandler( DIALOG_SYMBOL_PROPERTIES_BASE::OnSizeGrid ), NULL, this );
359  m_bpAdd->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SYMBOL_PROPERTIES_BASE::OnAddField ), NULL, this );
360  m_bpMoveUp->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SYMBOL_PROPERTIES_BASE::OnMoveUp ), NULL, this );
361  m_bpMoveDown->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SYMBOL_PROPERTIES_BASE::OnMoveDown ), NULL, this );
362  m_bpDelete->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SYMBOL_PROPERTIES_BASE::OnDeleteField ), NULL, this );
363  m_updateSymbolBtn->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SYMBOL_PROPERTIES_BASE::OnUpdateSymbol ), NULL, this );
364  m_changeSymbolBtn->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SYMBOL_PROPERTIES_BASE::OnExchangeSymbol ), NULL, this );
365  m_editSchematicSymbolBtn->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SYMBOL_PROPERTIES_BASE::OnEditSymbol ), NULL, this );
366  m_editLibrarySymbolBtn->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SYMBOL_PROPERTIES_BASE::OnEditLibrarySymbol ), NULL, this );
367  m_pinGrid->Disconnect( wxEVT_GRID_CELL_CHANGED, wxGridEventHandler( DIALOG_SYMBOL_PROPERTIES_BASE::OnPinTableCellEdited ), NULL, this );
368  m_spiceFieldsButton->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SYMBOL_PROPERTIES_BASE::OnEditSpiceModel ), NULL, this );
369  m_stdDialogButtonSizerCancel->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SYMBOL_PROPERTIES_BASE::OnCancelButtonClick ), NULL, this );
370 
371 }
virtual void OnDeleteField(wxCommandEvent &event)
virtual void OnPinTableCellEdited(wxGridEvent &event)
virtual void OnExchangeSymbol(wxCommandEvent &event)
virtual void OnMoveUp(wxCommandEvent &event)
virtual void OnCancelButtonClick(wxCommandEvent &event)
virtual void OnEditSpiceModel(wxCommandEvent &event)
virtual void OnInitDlg(wxInitDialogEvent &event)
Dialog helper object to sit in the inheritance tree between wxDialog and any class written by wxFormB...
Definition: dialog_shim.h:83
virtual void OnUpdateUI(wxUpdateUIEvent &event)
wxStdDialogButtonSizer * m_stdDialogButtonSizer
virtual void OnSizeGrid(wxSizeEvent &event)
#define NULL
virtual void OnMoveDown(wxCommandEvent &event)
virtual void OnUpdateSymbol(wxCommandEvent &event)
virtual void OnEditSymbol(wxCommandEvent &event)
#define _(s)
Definition: 3d_actions.cpp:33
virtual void OnEditLibrarySymbol(wxCommandEvent &event)
virtual void OnAddField(wxCommandEvent &event)
virtual void OnGridEditorShown(wxGridEvent &event)
DIALOG_SYMBOL_PROPERTIES_BASE(wxWindow *parent, wxWindowID id=wxID_ANY, const wxString &title=_("Symbol Properties"), const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxSize(-1,-1), long style=wxCAPTION|wxCLOSE_BOX|wxDEFAULT_DIALOG_STYLE|wxMAXIMIZE_BOX|wxMINIMIZE_BOX|wxRESIZE_BORDER|wxSYSTEM_MENU)
void SetColLabelSize(int aHeight)
Hide wxGrid's SetColLabelSize() method with one which makes sure the size is tall enough for the syst...
Definition: wx_grid.cpp:49