KiCad PCB EDA Suite
dialog_eeschema_config_fbp.cpp
Go to the documentation of this file.
1 // C++ code generated with wxFormBuilder (version Mar 28 2015)
3 // http://www.wxformbuilder.org/
4 //
5 // PLEASE DO "NOT" EDIT THIS FILE!
7 
9 
11 
12 DIALOG_EESCHEMA_CONFIG_FBP::DIALOG_EESCHEMA_CONFIG_FBP( 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  wxBoxSizer* bSizerUpper;
20  bSizerUpper = new wxBoxSizer( wxVERTICAL );
21 
22  m_staticTextLibsList = new wxStaticText( this, wxID_ANY, _("Component library files"), wxDefaultPosition, wxDefaultSize, 0 );
23  m_staticTextLibsList->Wrap( -1 );
24  bSizerUpper->Add( m_staticTextLibsList, 0, wxTOP|wxRIGHT|wxLEFT, 5 );
25 
26  wxBoxSizer* bSizerLibsChoice;
27  bSizerLibsChoice = new wxBoxSizer( wxHORIZONTAL );
28 
29  m_ListLibr = new wxListBox( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, 0, NULL, wxLB_EXTENDED|wxLB_HSCROLL|wxLB_NEEDED_SB|wxLB_SINGLE );
30  m_ListLibr->SetToolTip( _("List of active library files.\nOnly library files in this list are loaded by Eeschema.\nThe order of this list is important:\nEeschema searchs for a given component using this list order priority.") );
31  m_ListLibr->SetMinSize( wxSize( 400,250 ) );
32 
33  bSizerLibsChoice->Add( m_ListLibr, 1, wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT, 5 );
34 
35  wxBoxSizer* bRightSizer;
36  bRightSizer = new wxBoxSizer( wxVERTICAL );
37 
38  m_buttonAddLib = new wxButton( this, ID_ADD_LIB, _("Add"), wxDefaultPosition, wxDefaultSize, 0 );
39  m_buttonAddLib->SetToolTip( _("Add a new library after the selected library, and load it") );
40 
41  bRightSizer->Add( m_buttonAddLib, 0, wxLEFT|wxRIGHT|wxTOP|wxEXPAND, 5 );
42 
43  m_buttonIns = new wxButton( this, wxID_ANY, _("Insert"), wxDefaultPosition, wxDefaultSize, 0 );
44  m_buttonIns->SetToolTip( _("Add a new library before the selected library, and load it") );
45 
46  bRightSizer->Add( m_buttonIns, 0, wxLEFT|wxRIGHT|wxTOP|wxEXPAND, 5 );
47 
48  m_buttonRemoveLib = new wxButton( this, ID_REMOVE_LIB, _("Remove"), wxDefaultPosition, wxDefaultSize, 0 );
49  m_buttonRemoveLib->SetToolTip( _("Unload the selected library") );
50 
51  bRightSizer->Add( m_buttonRemoveLib, 0, wxALL|wxEXPAND, 5 );
52 
53  m_buttonUp = new wxButton( this, wxID_ANY, _("Up"), wxDefaultPosition, wxDefaultSize, 0 );
54  bRightSizer->Add( m_buttonUp, 0, wxBOTTOM|wxEXPAND|wxLEFT|wxRIGHT, 5 );
55 
56  m_buttonDown = new wxButton( this, wxID_ANY, _("Down"), wxDefaultPosition, wxDefaultSize, 0 );
57  bRightSizer->Add( m_buttonDown, 0, wxBOTTOM|wxEXPAND|wxLEFT|wxRIGHT, 5 );
58 
59 
60  bSizerLibsChoice->Add( bRightSizer, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5 );
61 
62 
63  bSizerUpper->Add( bSizerLibsChoice, 1, wxEXPAND, 5 );
64 
65 
66  bMainSizer->Add( bSizerUpper, 2, wxEXPAND, 5 );
67 
68  wxBoxSizer* bSizerMiddle;
69  bSizerMiddle = new wxBoxSizer( wxVERTICAL );
70 
71  m_staticTextPaths = new wxStaticText( this, wxID_ANY, _("User defined search path"), wxDefaultPosition, wxDefaultSize, 0 );
72  m_staticTextPaths->Wrap( -1 );
73  bSizerMiddle->Add( m_staticTextPaths, 0, wxTOP|wxRIGHT|wxLEFT, 5 );
74 
75  wxBoxSizer* bSizerPathsChoice;
76  bSizerPathsChoice = new wxBoxSizer( wxHORIZONTAL );
77 
78  m_listUserPaths = new wxListBox( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, 0, NULL, wxLB_HSCROLL|wxLB_NEEDED_SB|wxLB_SINGLE );
79  m_listUserPaths->SetToolTip( _("Additional paths used in this project. The priority is higher than default KiCad paths.") );
80  m_listUserPaths->SetMinSize( wxSize( 400,90 ) );
81 
82  bSizerPathsChoice->Add( m_listUserPaths, 1, wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT, 5 );
83 
84  wxBoxSizer* bUserPathsButtonsSizer;
85  bUserPathsButtonsSizer = new wxBoxSizer( wxVERTICAL );
86 
87  m_buttonAddPath = new wxButton( this, ID_LIB_PATH_SEL, _("Add"), wxDefaultPosition, wxDefaultSize, 0 );
88  bUserPathsButtonsSizer->Add( m_buttonAddPath, 0, wxLEFT|wxRIGHT|wxTOP|wxEXPAND, 5 );
89 
90  m_buttonInsPath = new wxButton( this, wxID_INSERT_PATH, _("Insert"), wxDefaultPosition, wxDefaultSize, 0 );
91  bUserPathsButtonsSizer->Add( m_buttonInsPath, 0, wxLEFT|wxRIGHT|wxTOP|wxEXPAND, 5 );
92 
93  m_buttonRemovePath = new wxButton( this, wxID_REMOVE_PATH, _("Remove"), wxDefaultPosition, wxDefaultSize, 0 );
94  bUserPathsButtonsSizer->Add( m_buttonRemovePath, 0, wxALL|wxEXPAND, 5 );
95 
96 
97  bSizerPathsChoice->Add( bUserPathsButtonsSizer, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5 );
98 
99 
100  bSizerMiddle->Add( bSizerPathsChoice, 1, wxEXPAND, 5 );
101 
102 
103  bMainSizer->Add( bSizerMiddle, 1, wxEXPAND, 5 );
104 
105  wxBoxSizer* bSizerLower;
106  bSizerLower = new wxBoxSizer( wxVERTICAL );
107 
108  m_staticTextPathlist = new wxStaticText( this, wxID_ANY, _("Current search path list"), wxDefaultPosition, wxDefaultSize, 0 );
109  m_staticTextPathlist->Wrap( -1 );
110  bSizerLower->Add( m_staticTextPathlist, 0, wxTOP|wxRIGHT|wxLEFT, 5 );
111 
112  m_DefaultLibraryPathslistBox = new wxListBox( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, 0, NULL, wxLB_NEEDED_SB );
113  m_DefaultLibraryPathslistBox->SetToolTip( _("System and user paths used to search and load library files and component doc files.\nSorted by decreasing priority order.") );
114 
115  bSizerLower->Add( m_DefaultLibraryPathslistBox, 1, wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT, 5 );
116 
117 
118  bMainSizer->Add( bSizerLower, 1, wxEXPAND, 5 );
119 
120  m_cbRescue = new wxCheckBox( this, wxID_ANY, _("Check for cache/library conflicts when loading schematic"), wxDefaultPosition, wxDefaultSize, 0 );
121  bMainSizer->Add( m_cbRescue, 0, wxALL, 5 );
122 
123  m_staticline3 = new wxStaticLine( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLI_HORIZONTAL );
124  bMainSizer->Add( m_staticline3, 0, wxEXPAND|wxRIGHT|wxLEFT, 5 );
125 
126  m_sdbSizer1 = new wxStdDialogButtonSizer();
127  m_sdbSizer1OK = new wxButton( this, wxID_OK );
128  m_sdbSizer1->AddButton( m_sdbSizer1OK );
129  m_sdbSizer1Cancel = new wxButton( this, wxID_CANCEL );
130  m_sdbSizer1->AddButton( m_sdbSizer1Cancel );
131  m_sdbSizer1->Realize();
132 
133  bMainSizer->Add( m_sdbSizer1, 0, wxALL|wxEXPAND, 5 );
134 
135 
136  this->SetSizer( bMainSizer );
137  this->Layout();
138  bMainSizer->Fit( this );
139 
140  this->Centre( wxBOTH );
141 
142  // Connect Events
143  this->Connect( wxEVT_CLOSE_WINDOW, wxCloseEventHandler( DIALOG_EESCHEMA_CONFIG_FBP::OnCloseWindow ) );
144  m_ListLibr->Connect( wxEVT_COMMAND_LISTBOX_SELECTED, wxCommandEventHandler( DIALOG_EESCHEMA_CONFIG_FBP::OnFilesListClick ), NULL, this );
145  m_ListLibr->Connect( wxEVT_COMMAND_LISTBOX_DOUBLECLICKED, wxCommandEventHandler( DIALOG_EESCHEMA_CONFIG_FBP::OnFilesListClick ), NULL, this );
146  m_buttonAddLib->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EESCHEMA_CONFIG_FBP::OnAddOrInsertLibClick ), NULL, this );
147  m_buttonIns->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EESCHEMA_CONFIG_FBP::OnAddOrInsertLibClick ), NULL, this );
148  m_buttonRemoveLib->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EESCHEMA_CONFIG_FBP::OnRemoveLibClick ), NULL, this );
149  m_buttonUp->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EESCHEMA_CONFIG_FBP::OnButtonUpClick ), NULL, this );
150  m_buttonDown->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EESCHEMA_CONFIG_FBP::OnButtonDownClick ), NULL, this );
151  m_buttonAddPath->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EESCHEMA_CONFIG_FBP::OnAddOrInsertPath ), NULL, this );
152  m_buttonInsPath->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EESCHEMA_CONFIG_FBP::OnAddOrInsertPath ), NULL, this );
153  m_buttonRemovePath->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EESCHEMA_CONFIG_FBP::OnRemoveUserPath ), NULL, this );
154  m_sdbSizer1Cancel->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EESCHEMA_CONFIG_FBP::OnCancelClick ), NULL, this );
155  m_sdbSizer1OK->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EESCHEMA_CONFIG_FBP::OnOkClick ), NULL, this );
156 }
157 
159 {
160  // Disconnect Events
161  this->Disconnect( wxEVT_CLOSE_WINDOW, wxCloseEventHandler( DIALOG_EESCHEMA_CONFIG_FBP::OnCloseWindow ) );
162  m_ListLibr->Disconnect( wxEVT_COMMAND_LISTBOX_SELECTED, wxCommandEventHandler( DIALOG_EESCHEMA_CONFIG_FBP::OnFilesListClick ), NULL, this );
163  m_ListLibr->Disconnect( wxEVT_COMMAND_LISTBOX_DOUBLECLICKED, wxCommandEventHandler( DIALOG_EESCHEMA_CONFIG_FBP::OnFilesListClick ), NULL, this );
164  m_buttonAddLib->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EESCHEMA_CONFIG_FBP::OnAddOrInsertLibClick ), NULL, this );
165  m_buttonIns->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EESCHEMA_CONFIG_FBP::OnAddOrInsertLibClick ), NULL, this );
166  m_buttonRemoveLib->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EESCHEMA_CONFIG_FBP::OnRemoveLibClick ), NULL, this );
167  m_buttonUp->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EESCHEMA_CONFIG_FBP::OnButtonUpClick ), NULL, this );
168  m_buttonDown->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EESCHEMA_CONFIG_FBP::OnButtonDownClick ), NULL, this );
169  m_buttonAddPath->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EESCHEMA_CONFIG_FBP::OnAddOrInsertPath ), NULL, this );
170  m_buttonInsPath->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EESCHEMA_CONFIG_FBP::OnAddOrInsertPath ), NULL, this );
171  m_buttonRemovePath->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EESCHEMA_CONFIG_FBP::OnRemoveUserPath ), NULL, this );
172  m_sdbSizer1Cancel->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EESCHEMA_CONFIG_FBP::OnCancelClick ), NULL, this );
173  m_sdbSizer1OK->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EESCHEMA_CONFIG_FBP::OnOkClick ), NULL, this );
174 
175 }
virtual void OnFilesListClick(wxCommandEvent &event)
virtual void OnAddOrInsertPath(wxCommandEvent &event)
virtual void OnCancelClick(wxCommandEvent &event)
virtual void OnOkClick(wxCommandEvent &event)
wxStdDialogButtonSizer * m_sdbSizer1
Class DIALOG_SHIM may sit in the inheritance tree between wxDialog and any class written by wxFormBui...
Definition: dialog_shim.h:60
virtual void OnAddOrInsertLibClick(wxCommandEvent &event)
DIALOG_EESCHEMA_CONFIG_FBP(wxWindow *parent, wxWindowID id=wxID_ANY, const wxString &title=wxEmptyString, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxSize(-1,-1), long style=wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER)
virtual void OnCloseWindow(wxCloseEvent &event)
virtual void OnButtonDownClick(wxCommandEvent &event)
virtual void OnButtonUpClick(wxCommandEvent &event)
virtual void OnRemoveLibClick(wxCommandEvent &event)
virtual void OnRemoveUserPath(wxCommandEvent &event)