Change top selection drop-down to combobox
wxChoice centers the selection on GTK. So when switching from a mid-list item to an item at the top, the list is always cut off for choice lists located on the top toolbar. Using a combobox provides a drop-down that allows easier access to all elements in the box. Fixes: lp:1808569 * https://bugs.launchpad.net/kicad/+bug/1808569
This commit is contained in:
parent
8de12094d8
commit
7d06651a10
|
@ -518,7 +518,7 @@ void EDA_DRAW_FRAME::OnSelectGrid( wxCommandEvent& event )
|
||||||
int* clientData;
|
int* clientData;
|
||||||
int eventId = ID_POPUP_GRID_LEVEL_100;
|
int eventId = ID_POPUP_GRID_LEVEL_100;
|
||||||
|
|
||||||
if( event.GetEventType() == wxEVT_CHOICE )
|
if( event.GetEventType() == wxEVT_COMBOBOX )
|
||||||
{
|
{
|
||||||
if( m_gridSelectBox == NULL ) // Should not happen
|
if( m_gridSelectBox == NULL ) // Should not happen
|
||||||
return;
|
return;
|
||||||
|
|
|
@ -519,7 +519,7 @@ void EDA_DRAW_FRAME::OnSelectGrid( wxCommandEvent& event )
|
||||||
int* clientData;
|
int* clientData;
|
||||||
int eventId = ID_POPUP_GRID_LEVEL_100;
|
int eventId = ID_POPUP_GRID_LEVEL_100;
|
||||||
|
|
||||||
if( event.GetEventType() == wxEVT_CHOICE )
|
if( event.GetEventType() == wxEVT_COMBOBOX )
|
||||||
{
|
{
|
||||||
if( m_gridSelectBox == NULL ) // Should not happen
|
if( m_gridSelectBox == NULL ) // Should not happen
|
||||||
return;
|
return;
|
||||||
|
|
|
@ -68,8 +68,8 @@ BEGIN_EVENT_TABLE( DISPLAY_FOOTPRINTS_FRAME, PCB_BASE_FRAME )
|
||||||
EVT_CLOSE( DISPLAY_FOOTPRINTS_FRAME::OnCloseWindow )
|
EVT_CLOSE( DISPLAY_FOOTPRINTS_FRAME::OnCloseWindow )
|
||||||
EVT_TOOL( ID_OPTIONS_SETUP, DISPLAY_FOOTPRINTS_FRAME::InstallOptionsDisplay )
|
EVT_TOOL( ID_OPTIONS_SETUP, DISPLAY_FOOTPRINTS_FRAME::InstallOptionsDisplay )
|
||||||
EVT_TOOL( ID_CVPCB_SHOW3D_FRAME, DISPLAY_FOOTPRINTS_FRAME::Show3D_Frame )
|
EVT_TOOL( ID_CVPCB_SHOW3D_FRAME, DISPLAY_FOOTPRINTS_FRAME::Show3D_Frame )
|
||||||
EVT_CHOICE( ID_ON_ZOOM_SELECT, DISPLAY_FOOTPRINTS_FRAME::OnSelectZoom )
|
EVT_COMBOBOX( ID_ON_ZOOM_SELECT, DISPLAY_FOOTPRINTS_FRAME::OnSelectZoom )
|
||||||
EVT_CHOICE( ID_ON_GRID_SELECT, DISPLAY_FOOTPRINTS_FRAME::OnSelectGrid )
|
EVT_COMBOBOX( ID_ON_GRID_SELECT, DISPLAY_FOOTPRINTS_FRAME::OnSelectGrid )
|
||||||
|
|
||||||
EVT_UPDATE_UI( ID_NO_TOOL_SELECTED, DISPLAY_FOOTPRINTS_FRAME::OnUIToolSelection )
|
EVT_UPDATE_UI( ID_NO_TOOL_SELECTED, DISPLAY_FOOTPRINTS_FRAME::OnUIToolSelection )
|
||||||
EVT_UPDATE_UI( ID_TB_MEASUREMENT_TOOL, DISPLAY_FOOTPRINTS_FRAME::OnUIToolSelection )
|
EVT_UPDATE_UI( ID_TB_MEASUREMENT_TOOL, DISPLAY_FOOTPRINTS_FRAME::OnUIToolSelection )
|
||||||
|
@ -305,16 +305,16 @@ void DISPLAY_FOOTPRINTS_FRAME::ReCreateHToolbar()
|
||||||
KiScaledSeparator( m_mainToolBar, this );
|
KiScaledSeparator( m_mainToolBar, this );
|
||||||
|
|
||||||
// Grid selection choice box.
|
// Grid selection choice box.
|
||||||
m_gridSelectBox = new wxChoice( m_mainToolBar, ID_ON_GRID_SELECT,
|
m_gridSelectBox = new wxComboBox( m_mainToolBar, ID_ON_GRID_SELECT, wxEmptyString,
|
||||||
wxDefaultPosition, wxDefaultSize, 0, NULL );
|
wxDefaultPosition, wxDefaultSize, 0, nullptr, wxCB_READONLY );
|
||||||
UpdateGridSelectBox();
|
UpdateGridSelectBox();
|
||||||
m_mainToolBar->AddControl( m_gridSelectBox );
|
m_mainToolBar->AddControl( m_gridSelectBox );
|
||||||
|
|
||||||
KiScaledSeparator( m_mainToolBar, this );
|
KiScaledSeparator( m_mainToolBar, this );
|
||||||
|
|
||||||
// Zoom selection choice box.
|
// Zoom selection choice box.
|
||||||
m_zoomSelectBox = new wxChoice( m_mainToolBar, ID_ON_ZOOM_SELECT,
|
m_zoomSelectBox = new wxComboBox( m_mainToolBar, ID_ON_ZOOM_SELECT, wxEmptyString,
|
||||||
wxDefaultPosition, wxDefaultSize, 0, NULL );
|
wxDefaultPosition, wxDefaultSize, 0, nullptr, wxCB_READONLY );
|
||||||
updateZoomSelectBox();
|
updateZoomSelectBox();
|
||||||
m_mainToolBar->AddControl( m_zoomSelectBox );
|
m_mainToolBar->AddControl( m_zoomSelectBox );
|
||||||
|
|
||||||
|
|
|
@ -138,12 +138,12 @@ BEGIN_EVENT_TABLE( GERBVIEW_FRAME, EDA_DRAW_FRAME )
|
||||||
EVT_TOOL( ID_TB_OPTIONS_HIGH_CONTRAST_MODE, GERBVIEW_FRAME::OnSelectOptionToolbar )
|
EVT_TOOL( ID_TB_OPTIONS_HIGH_CONTRAST_MODE, GERBVIEW_FRAME::OnSelectOptionToolbar )
|
||||||
|
|
||||||
// Auxiliary horizontal toolbar
|
// Auxiliary horizontal toolbar
|
||||||
EVT_CHOICE( ID_GBR_AUX_TOOLBAR_PCB_CMP_CHOICE, GERBVIEW_FRAME::OnSelectHighlightChoice )
|
EVT_COMBOBOX( ID_GBR_AUX_TOOLBAR_PCB_CMP_CHOICE, GERBVIEW_FRAME::OnSelectHighlightChoice )
|
||||||
EVT_CHOICE( ID_GBR_AUX_TOOLBAR_PCB_NET_CHOICE, GERBVIEW_FRAME::OnSelectHighlightChoice )
|
EVT_COMBOBOX( ID_GBR_AUX_TOOLBAR_PCB_NET_CHOICE, GERBVIEW_FRAME::OnSelectHighlightChoice )
|
||||||
EVT_CHOICE( ID_GBR_AUX_TOOLBAR_PCB_APERATTRIBUTES_CHOICE,
|
EVT_COMBOBOX( ID_GBR_AUX_TOOLBAR_PCB_APERATTRIBUTES_CHOICE,
|
||||||
GERBVIEW_FRAME::OnSelectHighlightChoice )
|
GERBVIEW_FRAME::OnSelectHighlightChoice )
|
||||||
EVT_CHOICE( ID_ON_ZOOM_SELECT, GERBVIEW_FRAME::OnSelectZoom )
|
EVT_COMBOBOX( ID_ON_ZOOM_SELECT, GERBVIEW_FRAME::OnSelectZoom )
|
||||||
EVT_CHOICE( ID_ON_GRID_SELECT, GERBVIEW_FRAME::OnSelectGrid )
|
EVT_COMBOBOX( ID_ON_GRID_SELECT, GERBVIEW_FRAME::OnSelectGrid )
|
||||||
|
|
||||||
// Right click context menu
|
// Right click context menu
|
||||||
EVT_MENU( ID_HIGHLIGHT_CMP_ITEMS, GERBVIEW_FRAME::Process_Special_Functions )
|
EVT_MENU( ID_HIGHLIGHT_CMP_ITEMS, GERBVIEW_FRAME::Process_Special_Functions )
|
||||||
|
|
|
@ -170,9 +170,9 @@ protected:
|
||||||
wxString m_lastFileName;
|
wxString m_lastFileName;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
wxChoice* m_SelComponentBox; // a choice box to display and highlight component graphic items
|
wxComboBox* m_SelComponentBox; // a choice box to display and highlight component graphic items
|
||||||
wxChoice* m_SelNetnameBox; // a choice box to display and highlight netlist graphic items
|
wxComboBox* m_SelNetnameBox; // a choice box to display and highlight netlist graphic items
|
||||||
wxChoice* m_SelAperAttributesBox; // a choice box to display aperture attributes and highlight items
|
wxComboBox* m_SelAperAttributesBox; // a choice box to display aperture attributes and highlight items
|
||||||
GBR_LAYER_BOX_SELECTOR* m_SelLayerBox; // The combobox to select the current active graphic layer
|
GBR_LAYER_BOX_SELECTOR* m_SelLayerBox; // The combobox to select the current active graphic layer
|
||||||
// (which is drawn on top on the other layers
|
// (which is drawn on top on the other layers
|
||||||
DCODE_SELECTION_BOX* m_DCodeSelector; // a list box to select the dcode Id to highlight.
|
DCODE_SELECTION_BOX* m_DCodeSelector; // a list box to select the dcode Id to highlight.
|
||||||
|
|
|
@ -119,8 +119,9 @@ void GERBVIEW_FRAME::ReCreateAuxiliaryToolbar()
|
||||||
// Creates box to display and choose components:
|
// Creates box to display and choose components:
|
||||||
if( !m_SelComponentBox )
|
if( !m_SelComponentBox )
|
||||||
{
|
{
|
||||||
m_SelComponentBox = new wxChoice( m_auxiliaryToolBar,
|
m_SelComponentBox = new wxComboBox( m_auxiliaryToolBar,
|
||||||
ID_GBR_AUX_TOOLBAR_PCB_CMP_CHOICE );
|
ID_GBR_AUX_TOOLBAR_PCB_CMP_CHOICE, wxEmptyString,
|
||||||
|
wxDefaultPosition, wxDefaultSize, 0, nullptr, wxCB_READONLY );
|
||||||
m_SelComponentBox->SetToolTip( _("Highlight items belonging to this component") );
|
m_SelComponentBox->SetToolTip( _("Highlight items belonging to this component") );
|
||||||
text = new wxStaticText( m_auxiliaryToolBar, wxID_ANY, _( "Cmp: ") );
|
text = new wxStaticText( m_auxiliaryToolBar, wxID_ANY, _( "Cmp: ") );
|
||||||
m_auxiliaryToolBar->AddControl( text );
|
m_auxiliaryToolBar->AddControl( text );
|
||||||
|
@ -131,8 +132,9 @@ void GERBVIEW_FRAME::ReCreateAuxiliaryToolbar()
|
||||||
// Creates choice box to display net names and highlight selected:
|
// Creates choice box to display net names and highlight selected:
|
||||||
if( !m_SelNetnameBox )
|
if( !m_SelNetnameBox )
|
||||||
{
|
{
|
||||||
m_SelNetnameBox = new wxChoice( m_auxiliaryToolBar,
|
m_SelNetnameBox = new wxComboBox( m_auxiliaryToolBar,
|
||||||
ID_GBR_AUX_TOOLBAR_PCB_NET_CHOICE );
|
ID_GBR_AUX_TOOLBAR_PCB_NET_CHOICE, wxEmptyString,
|
||||||
|
wxDefaultPosition, wxDefaultSize, 0, nullptr, wxCB_READONLY );
|
||||||
m_SelNetnameBox->SetToolTip( _("Highlight items belonging to this net") );
|
m_SelNetnameBox->SetToolTip( _("Highlight items belonging to this net") );
|
||||||
text = new wxStaticText( m_auxiliaryToolBar, wxID_ANY, _( "Net:" ) );
|
text = new wxStaticText( m_auxiliaryToolBar, wxID_ANY, _( "Net:" ) );
|
||||||
m_auxiliaryToolBar->AddControl( text );
|
m_auxiliaryToolBar->AddControl( text );
|
||||||
|
@ -143,8 +145,9 @@ void GERBVIEW_FRAME::ReCreateAuxiliaryToolbar()
|
||||||
// Creates choice box to display aperture attributes and highlight selected:
|
// Creates choice box to display aperture attributes and highlight selected:
|
||||||
if( !m_SelAperAttributesBox )
|
if( !m_SelAperAttributesBox )
|
||||||
{
|
{
|
||||||
m_SelAperAttributesBox = new wxChoice( m_auxiliaryToolBar,
|
m_SelAperAttributesBox = new wxComboBox( m_auxiliaryToolBar,
|
||||||
ID_GBR_AUX_TOOLBAR_PCB_APERATTRIBUTES_CHOICE );
|
ID_GBR_AUX_TOOLBAR_PCB_APERATTRIBUTES_CHOICE, wxEmptyString,
|
||||||
|
wxDefaultPosition, wxDefaultSize, 0, nullptr, wxCB_READONLY );
|
||||||
m_SelAperAttributesBox->SetToolTip( _("Highlight items with this aperture attribute") );
|
m_SelAperAttributesBox->SetToolTip( _("Highlight items with this aperture attribute") );
|
||||||
text = new wxStaticText( m_auxiliaryToolBar, wxID_ANY, _( "Attr:" ) );
|
text = new wxStaticText( m_auxiliaryToolBar, wxID_ANY, _( "Attr:" ) );
|
||||||
m_auxiliaryToolBar->AddControl( text );
|
m_auxiliaryToolBar->AddControl( text );
|
||||||
|
@ -165,16 +168,16 @@ void GERBVIEW_FRAME::ReCreateAuxiliaryToolbar()
|
||||||
if( !m_gridSelectBox )
|
if( !m_gridSelectBox )
|
||||||
{
|
{
|
||||||
KiScaledSeparator( m_auxiliaryToolBar, this );
|
KiScaledSeparator( m_auxiliaryToolBar, this );
|
||||||
m_gridSelectBox = new wxChoice( m_auxiliaryToolBar, ID_ON_GRID_SELECT,
|
m_gridSelectBox = new wxComboBox( m_auxiliaryToolBar, ID_ON_GRID_SELECT, wxEmptyString,
|
||||||
wxDefaultPosition, wxDefaultSize, 0, nullptr );
|
wxDefaultPosition, wxDefaultSize, 0, nullptr, wxCB_READONLY );
|
||||||
m_auxiliaryToolBar->AddControl( m_gridSelectBox );
|
m_auxiliaryToolBar->AddControl( m_gridSelectBox );
|
||||||
}
|
}
|
||||||
|
|
||||||
if( !m_zoomSelectBox )
|
if( !m_zoomSelectBox )
|
||||||
{
|
{
|
||||||
KiScaledSeparator( m_auxiliaryToolBar, this );
|
KiScaledSeparator( m_auxiliaryToolBar, this );
|
||||||
m_zoomSelectBox = new wxChoice( m_auxiliaryToolBar, ID_ON_ZOOM_SELECT,
|
m_zoomSelectBox = new wxComboBox( m_auxiliaryToolBar, ID_ON_ZOOM_SELECT, wxEmptyString,
|
||||||
wxDefaultPosition, wxDefaultSize, 0, nullptr );
|
wxDefaultPosition, wxDefaultSize, 0, nullptr, wxCB_READONLY );
|
||||||
m_auxiliaryToolBar->AddControl( m_zoomSelectBox );
|
m_auxiliaryToolBar->AddControl( m_zoomSelectBox );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -145,7 +145,7 @@ protected:
|
||||||
/// Key to control whether first run dialog is shown on startup
|
/// Key to control whether first run dialog is shown on startup
|
||||||
long m_firstRunDialogSetting;
|
long m_firstRunDialogSetting;
|
||||||
|
|
||||||
wxChoice* m_gridSelectBox;
|
wxComboBox* m_gridSelectBox;
|
||||||
wxChoice* m_zoomSelectBox;
|
wxChoice* m_zoomSelectBox;
|
||||||
|
|
||||||
/// Auxiliary tool bar typically shown below the main tool bar at the top of the
|
/// Auxiliary tool bar typically shown below the main tool bar at the top of the
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
///////////////////////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////////////////////
|
||||||
// C++ code generated with wxFormBuilder (version Aug 2 2018)
|
// C++ code generated with wxFormBuilder (version Nov 23 2018)
|
||||||
// http://www.wxformbuilder.org/
|
// http://www.wxformbuilder.org/
|
||||||
//
|
//
|
||||||
// PLEASE DO *NOT* EDIT THIS FILE!
|
// PLEASE DO *NOT* EDIT THIS FILE!
|
||||||
|
@ -14,117 +14,113 @@
|
||||||
DIALOG_GLOBAL_EDIT_TRACKS_AND_VIAS_BASE::DIALOG_GLOBAL_EDIT_TRACKS_AND_VIAS_BASE( wxWindow* parent, wxWindowID id, const wxString& title, const wxPoint& pos, const wxSize& size, long style ) : DIALOG_SHIM( parent, id, title, pos, size, style )
|
DIALOG_GLOBAL_EDIT_TRACKS_AND_VIAS_BASE::DIALOG_GLOBAL_EDIT_TRACKS_AND_VIAS_BASE( wxWindow* parent, wxWindowID id, const wxString& title, const wxPoint& pos, const wxSize& size, long style ) : DIALOG_SHIM( parent, id, title, pos, size, style )
|
||||||
{
|
{
|
||||||
this->SetSizeHints( wxDefaultSize, wxDefaultSize );
|
this->SetSizeHints( wxDefaultSize, wxDefaultSize );
|
||||||
|
|
||||||
wxBoxSizer* bMainSizer;
|
wxBoxSizer* bMainSizer;
|
||||||
bMainSizer = new wxBoxSizer( wxVERTICAL );
|
bMainSizer = new wxBoxSizer( wxVERTICAL );
|
||||||
|
|
||||||
wxStaticBoxSizer* sbScope;
|
wxStaticBoxSizer* sbScope;
|
||||||
sbScope = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Scope") ), wxVERTICAL );
|
sbScope = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Scope") ), wxVERTICAL );
|
||||||
|
|
||||||
wxFlexGridSizer* fgSizer1;
|
wxFlexGridSizer* fgSizer1;
|
||||||
fgSizer1 = new wxFlexGridSizer( 0, 2, 0, 0 );
|
fgSizer1 = new wxFlexGridSizer( 0, 2, 0, 0 );
|
||||||
fgSizer1->AddGrowableCol( 0 );
|
fgSizer1->AddGrowableCol( 0 );
|
||||||
fgSizer1->AddGrowableCol( 1 );
|
fgSizer1->AddGrowableCol( 1 );
|
||||||
fgSizer1->SetFlexibleDirection( wxBOTH );
|
fgSizer1->SetFlexibleDirection( wxBOTH );
|
||||||
fgSizer1->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED );
|
fgSizer1->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED );
|
||||||
|
|
||||||
m_tracks = new wxCheckBox( sbScope->GetStaticBox(), wxID_ANY, _("Tracks"), wxDefaultPosition, wxDefaultSize, 0 );
|
m_tracks = new wxCheckBox( sbScope->GetStaticBox(), wxID_ANY, _("Tracks"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||||
m_tracks->SetValue(true);
|
m_tracks->SetValue(true);
|
||||||
fgSizer1->Add( m_tracks, 0, wxBOTTOM|wxRIGHT|wxLEFT, 5 );
|
fgSizer1->Add( m_tracks, 0, wxBOTTOM|wxRIGHT|wxLEFT, 5 );
|
||||||
|
|
||||||
m_vias = new wxCheckBox( sbScope->GetStaticBox(), wxID_ANY, _("Vias"), wxDefaultPosition, wxDefaultSize, 0 );
|
m_vias = new wxCheckBox( sbScope->GetStaticBox(), wxID_ANY, _("Vias"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||||
m_vias->SetValue(true);
|
m_vias->SetValue(true);
|
||||||
fgSizer1->Add( m_vias, 0, wxBOTTOM|wxRIGHT|wxLEFT, 5 );
|
fgSizer1->Add( m_vias, 0, wxBOTTOM|wxRIGHT|wxLEFT, 5 );
|
||||||
|
|
||||||
|
|
||||||
sbScope->Add( fgSizer1, 0, wxEXPAND, 5 );
|
sbScope->Add( fgSizer1, 0, wxEXPAND, 5 );
|
||||||
|
|
||||||
|
|
||||||
bMainSizer->Add( sbScope, 0, wxALL|wxEXPAND, 5 );
|
bMainSizer->Add( sbScope, 0, wxALL|wxEXPAND, 5 );
|
||||||
|
|
||||||
wxStaticBoxSizer* sbFilters;
|
wxStaticBoxSizer* sbFilters;
|
||||||
sbFilters = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Filters") ), wxVERTICAL );
|
sbFilters = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Filters") ), wxVERTICAL );
|
||||||
|
|
||||||
wxFlexGridSizer* fgSizer3;
|
wxFlexGridSizer* fgSizer3;
|
||||||
fgSizer3 = new wxFlexGridSizer( 0, 3, 3, 0 );
|
fgSizer3 = new wxFlexGridSizer( 0, 3, 3, 0 );
|
||||||
fgSizer3->AddGrowableCol( 1 );
|
fgSizer3->AddGrowableCol( 1 );
|
||||||
fgSizer3->AddGrowableCol( 2 );
|
fgSizer3->AddGrowableCol( 2 );
|
||||||
fgSizer3->SetFlexibleDirection( wxHORIZONTAL );
|
fgSizer3->SetFlexibleDirection( wxHORIZONTAL );
|
||||||
fgSizer3->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED );
|
fgSizer3->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED );
|
||||||
|
|
||||||
m_netFilterOpt = new wxCheckBox( sbFilters->GetStaticBox(), wxID_ANY, _("Filter items by net:"), wxDefaultPosition, wxDefaultSize, 0 );
|
m_netFilterOpt = new wxCheckBox( sbFilters->GetStaticBox(), wxID_ANY, _("Filter items by net:"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||||
fgSizer3->Add( m_netFilterOpt, 0, wxALIGN_CENTER_VERTICAL|wxRIGHT|wxLEFT, 5 );
|
fgSizer3->Add( m_netFilterOpt, 0, wxALIGN_CENTER_VERTICAL|wxRIGHT|wxLEFT, 5 );
|
||||||
|
|
||||||
m_netFilter = new NET_SELECTOR( sbFilters->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, 0 );
|
m_netFilter = new NET_SELECTOR( sbFilters->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, 0 );
|
||||||
fgSizer3->Add( m_netFilter, 1, wxEXPAND|wxRIGHT, 5 );
|
fgSizer3->Add( m_netFilter, 1, wxEXPAND|wxRIGHT, 5 );
|
||||||
|
|
||||||
|
|
||||||
fgSizer3->Add( 0, 0, 1, wxEXPAND|wxRIGHT|wxLEFT, 100 );
|
fgSizer3->Add( 0, 0, 1, wxEXPAND|wxRIGHT|wxLEFT, 100 );
|
||||||
|
|
||||||
m_netclassFilterOpt = new wxCheckBox( sbFilters->GetStaticBox(), wxID_ANY, _("Filter items by net class:"), wxDefaultPosition, wxDefaultSize, 0 );
|
m_netclassFilterOpt = new wxCheckBox( sbFilters->GetStaticBox(), wxID_ANY, _("Filter items by net class:"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||||
fgSizer3->Add( m_netclassFilterOpt, 0, wxALIGN_CENTER_VERTICAL|wxRIGHT|wxLEFT, 5 );
|
fgSizer3->Add( m_netclassFilterOpt, 0, wxALIGN_CENTER_VERTICAL|wxRIGHT|wxLEFT, 5 );
|
||||||
|
|
||||||
wxArrayString m_netclassFilterChoices;
|
wxArrayString m_netclassFilterChoices;
|
||||||
m_netclassFilter = new wxChoice( sbFilters->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, m_netclassFilterChoices, 0 );
|
m_netclassFilter = new wxChoice( sbFilters->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, m_netclassFilterChoices, 0 );
|
||||||
m_netclassFilter->SetSelection( 0 );
|
m_netclassFilter->SetSelection( 0 );
|
||||||
fgSizer3->Add( m_netclassFilter, 0, wxALIGN_CENTER_VERTICAL|wxEXPAND|wxRIGHT, 5 );
|
fgSizer3->Add( m_netclassFilter, 0, wxALIGN_CENTER_VERTICAL|wxEXPAND|wxRIGHT, 5 );
|
||||||
|
|
||||||
|
|
||||||
fgSizer3->Add( 0, 0, 1, wxEXPAND, 5 );
|
fgSizer3->Add( 0, 0, 1, wxEXPAND, 5 );
|
||||||
|
|
||||||
m_layerFilterOpt = new wxCheckBox( sbFilters->GetStaticBox(), wxID_ANY, _("Filter items by layer:"), wxDefaultPosition, wxDefaultSize, 0 );
|
m_layerFilterOpt = new wxCheckBox( sbFilters->GetStaticBox(), wxID_ANY, _("Filter items by layer:"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||||
fgSizer3->Add( m_layerFilterOpt, 0, wxALIGN_CENTER_VERTICAL|wxRIGHT|wxLEFT, 5 );
|
fgSizer3->Add( m_layerFilterOpt, 0, wxALIGN_CENTER_VERTICAL|wxRIGHT|wxLEFT, 5 );
|
||||||
|
|
||||||
m_layerFilter = new PCB_LAYER_BOX_SELECTOR( sbFilters->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0, NULL, 0 );
|
m_layerFilter = new PCB_LAYER_BOX_SELECTOR( sbFilters->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0, NULL, 0 );
|
||||||
fgSizer3->Add( m_layerFilter, 0, wxEXPAND|wxALIGN_CENTER_VERTICAL|wxRIGHT, 5 );
|
fgSizer3->Add( m_layerFilter, 0, wxEXPAND|wxALIGN_CENTER_VERTICAL|wxRIGHT, 5 );
|
||||||
|
|
||||||
|
|
||||||
fgSizer3->Add( 0, 0, 1, wxEXPAND, 5 );
|
fgSizer3->Add( 0, 0, 1, wxEXPAND, 5 );
|
||||||
|
|
||||||
|
|
||||||
sbFilters->Add( fgSizer3, 1, wxEXPAND, 5 );
|
sbFilters->Add( fgSizer3, 1, wxEXPAND, 5 );
|
||||||
|
|
||||||
|
|
||||||
bMainSizer->Add( sbFilters, 0, wxALL|wxEXPAND, 5 );
|
bMainSizer->Add( sbFilters, 0, wxALL|wxEXPAND, 5 );
|
||||||
|
|
||||||
wxStaticBoxSizer* sbAction;
|
wxStaticBoxSizer* sbAction;
|
||||||
sbAction = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Action") ), wxVERTICAL );
|
sbAction = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Action") ), wxVERTICAL );
|
||||||
|
|
||||||
m_setToSpecifiedValues = new wxRadioButton( sbAction->GetStaticBox(), ID_SPECIFIED_NET_TO_SPECIFIED_VALUES, _("Set to specified values:"), wxDefaultPosition, wxDefaultSize, wxRB_GROUP );
|
m_setToSpecifiedValues = new wxRadioButton( sbAction->GetStaticBox(), ID_SPECIFIED_NET_TO_SPECIFIED_VALUES, _("Set to specified values:"), wxDefaultPosition, wxDefaultSize, wxRB_GROUP );
|
||||||
m_setToSpecifiedValues->SetValue( true );
|
m_setToSpecifiedValues->SetValue( true );
|
||||||
sbAction->Add( m_setToSpecifiedValues, 0, wxTOP|wxBOTTOM, 5 );
|
sbAction->Add( m_setToSpecifiedValues, 0, wxTOP|wxBOTTOM, 5 );
|
||||||
|
|
||||||
wxBoxSizer* bSizerTrackViaPopups;
|
wxBoxSizer* bSizerTrackViaPopups;
|
||||||
bSizerTrackViaPopups = new wxBoxSizer( wxHORIZONTAL );
|
bSizerTrackViaPopups = new wxBoxSizer( wxHORIZONTAL );
|
||||||
|
|
||||||
wxArrayString m_trackWidthSelectBoxChoices;
|
m_trackWidthSelectBox = new wxComboBox( sbAction->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0, NULL, wxCB_READONLY );
|
||||||
m_trackWidthSelectBox = new wxChoice( sbAction->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, m_trackWidthSelectBoxChoices, 0 );
|
|
||||||
m_trackWidthSelectBox->SetSelection( 0 );
|
|
||||||
bSizerTrackViaPopups->Add( m_trackWidthSelectBox, 4, wxEXPAND|wxRIGHT, 5 );
|
bSizerTrackViaPopups->Add( m_trackWidthSelectBox, 4, wxEXPAND|wxRIGHT, 5 );
|
||||||
|
|
||||||
wxArrayString m_viaSizesSelectBoxChoices;
|
m_viaSizesSelectBox = new wxComboBox( sbAction->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0, NULL, wxCB_READONLY );
|
||||||
m_viaSizesSelectBox = new wxChoice( sbAction->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, m_viaSizesSelectBoxChoices, 0 );
|
bSizerTrackViaPopups->Add( m_viaSizesSelectBox, 5, wxEXPAND|wxLEFT|wxRIGHT, 5 );
|
||||||
m_viaSizesSelectBox->SetSelection( 0 );
|
|
||||||
bSizerTrackViaPopups->Add( m_viaSizesSelectBox, 5, wxEXPAND|wxRIGHT|wxLEFT, 5 );
|
m_layerBox = new PCB_LAYER_BOX_SELECTOR( sbAction->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0, NULL, 0 );
|
||||||
|
|
||||||
m_layerBox = new PCB_LAYER_BOX_SELECTOR( sbAction->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0, NULL, 0 );
|
|
||||||
bSizerTrackViaPopups->Add( m_layerBox, 0, wxRIGHT|wxLEFT, 3 );
|
bSizerTrackViaPopups->Add( m_layerBox, 0, wxRIGHT|wxLEFT, 3 );
|
||||||
|
|
||||||
|
|
||||||
sbAction->Add( bSizerTrackViaPopups, 0, wxEXPAND|wxBOTTOM|wxLEFT, 15 );
|
sbAction->Add( bSizerTrackViaPopups, 0, wxEXPAND|wxBOTTOM|wxLEFT, 15 );
|
||||||
|
|
||||||
m_setToNetclassValues = new wxRadioButton( sbAction->GetStaticBox(), ID_SPECIFIED_NET_TO_NETCLASS_VALUES, _("Set to net class values:"), wxDefaultPosition, wxDefaultSize, 0 );
|
m_setToNetclassValues = new wxRadioButton( sbAction->GetStaticBox(), ID_SPECIFIED_NET_TO_NETCLASS_VALUES, _("Set to net class values:"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||||
sbAction->Add( m_setToNetclassValues, 0, wxTOP|wxBOTTOM, 5 );
|
sbAction->Add( m_setToNetclassValues, 0, wxTOP|wxBOTTOM, 5 );
|
||||||
|
|
||||||
m_netclassGrid = new wxGrid( sbAction->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, wxBORDER_DEFAULT|wxVSCROLL );
|
m_netclassGrid = new wxGrid( sbAction->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, wxBORDER_DEFAULT|wxVSCROLL );
|
||||||
|
|
||||||
// Grid
|
// Grid
|
||||||
m_netclassGrid->CreateGrid( 1, 6 );
|
m_netclassGrid->CreateGrid( 1, 6 );
|
||||||
m_netclassGrid->EnableEditing( false );
|
m_netclassGrid->EnableEditing( false );
|
||||||
m_netclassGrid->EnableGridLines( true );
|
m_netclassGrid->EnableGridLines( true );
|
||||||
m_netclassGrid->EnableDragGridSize( false );
|
m_netclassGrid->EnableDragGridSize( false );
|
||||||
m_netclassGrid->SetMargins( 0, 0 );
|
m_netclassGrid->SetMargins( 0, 0 );
|
||||||
|
|
||||||
// Columns
|
// Columns
|
||||||
m_netclassGrid->SetColSize( 0, 95 );
|
m_netclassGrid->SetColSize( 0, 95 );
|
||||||
m_netclassGrid->SetColSize( 1, 95 );
|
m_netclassGrid->SetColSize( 1, 95 );
|
||||||
|
@ -135,41 +131,41 @@ DIALOG_GLOBAL_EDIT_TRACKS_AND_VIAS_BASE::DIALOG_GLOBAL_EDIT_TRACKS_AND_VIAS_BASE
|
||||||
m_netclassGrid->EnableDragColMove( false );
|
m_netclassGrid->EnableDragColMove( false );
|
||||||
m_netclassGrid->EnableDragColSize( false );
|
m_netclassGrid->EnableDragColSize( false );
|
||||||
m_netclassGrid->SetColLabelSize( 0 );
|
m_netclassGrid->SetColLabelSize( 0 );
|
||||||
m_netclassGrid->SetColLabelAlignment( wxALIGN_CENTRE, wxALIGN_CENTRE );
|
m_netclassGrid->SetColLabelAlignment( wxALIGN_CENTER, wxALIGN_CENTER );
|
||||||
|
|
||||||
// Rows
|
// Rows
|
||||||
m_netclassGrid->EnableDragRowSize( false );
|
m_netclassGrid->EnableDragRowSize( false );
|
||||||
m_netclassGrid->SetRowLabelSize( 0 );
|
m_netclassGrid->SetRowLabelSize( 0 );
|
||||||
m_netclassGrid->SetRowLabelAlignment( wxALIGN_CENTRE, wxALIGN_CENTRE );
|
m_netclassGrid->SetRowLabelAlignment( wxALIGN_CENTER, wxALIGN_CENTER );
|
||||||
|
|
||||||
// Label Appearance
|
// Label Appearance
|
||||||
|
|
||||||
// Cell Defaults
|
// Cell Defaults
|
||||||
m_netclassGrid->SetDefaultCellBackgroundColour( wxSystemSettings::GetColour( wxSYS_COLOUR_BTNFACE ) );
|
m_netclassGrid->SetDefaultCellBackgroundColour( wxSystemSettings::GetColour( wxSYS_COLOUR_BTNFACE ) );
|
||||||
m_netclassGrid->SetDefaultCellFont( wxFont( 11, wxFONTFAMILY_DEFAULT, wxFONTSTYLE_NORMAL, wxFONTWEIGHT_NORMAL, false, wxEmptyString ) );
|
m_netclassGrid->SetDefaultCellFont( wxFont( 11, wxFONTFAMILY_DEFAULT, wxFONTSTYLE_NORMAL, wxFONTWEIGHT_NORMAL, false, wxEmptyString ) );
|
||||||
m_netclassGrid->SetDefaultCellAlignment( wxALIGN_LEFT, wxALIGN_CENTRE );
|
m_netclassGrid->SetDefaultCellAlignment( wxALIGN_LEFT, wxALIGN_CENTER );
|
||||||
sbAction->Add( m_netclassGrid, 0, wxEXPAND|wxLEFT, 15 );
|
sbAction->Add( m_netclassGrid, 0, wxEXPAND|wxLEFT, 15 );
|
||||||
|
|
||||||
|
|
||||||
sbAction->Add( 0, 0, 1, wxEXPAND|wxTOP, 5 );
|
sbAction->Add( 0, 0, 1, wxEXPAND|wxTOP, 5 );
|
||||||
|
|
||||||
|
|
||||||
bMainSizer->Add( sbAction, 1, wxEXPAND|wxTOP|wxRIGHT|wxLEFT, 5 );
|
bMainSizer->Add( sbAction, 1, wxEXPAND|wxTOP|wxRIGHT|wxLEFT, 5 );
|
||||||
|
|
||||||
m_sdbSizer = new wxStdDialogButtonSizer();
|
m_sdbSizer = new wxStdDialogButtonSizer();
|
||||||
m_sdbSizerOK = new wxButton( this, wxID_OK );
|
m_sdbSizerOK = new wxButton( this, wxID_OK );
|
||||||
m_sdbSizer->AddButton( m_sdbSizerOK );
|
m_sdbSizer->AddButton( m_sdbSizerOK );
|
||||||
m_sdbSizerCancel = new wxButton( this, wxID_CANCEL );
|
m_sdbSizerCancel = new wxButton( this, wxID_CANCEL );
|
||||||
m_sdbSizer->AddButton( m_sdbSizerCancel );
|
m_sdbSizer->AddButton( m_sdbSizerCancel );
|
||||||
m_sdbSizer->Realize();
|
m_sdbSizer->Realize();
|
||||||
|
|
||||||
bMainSizer->Add( m_sdbSizer, 0, wxEXPAND|wxALL, 5 );
|
bMainSizer->Add( m_sdbSizer, 0, wxEXPAND|wxALL, 5 );
|
||||||
|
|
||||||
|
|
||||||
this->SetSizer( bMainSizer );
|
this->SetSizer( bMainSizer );
|
||||||
this->Layout();
|
this->Layout();
|
||||||
bMainSizer->Fit( this );
|
bMainSizer->Fit( this );
|
||||||
|
|
||||||
// Connect Events
|
// Connect Events
|
||||||
this->Connect( wxEVT_UPDATE_UI, wxUpdateUIEventHandler( DIALOG_GLOBAL_EDIT_TRACKS_AND_VIAS_BASE::OnUpdateUI ) );
|
this->Connect( wxEVT_UPDATE_UI, wxUpdateUIEventHandler( DIALOG_GLOBAL_EDIT_TRACKS_AND_VIAS_BASE::OnUpdateUI ) );
|
||||||
m_netclassFilter->Connect( wxEVT_COMMAND_CHOICE_SELECTED, wxCommandEventHandler( DIALOG_GLOBAL_EDIT_TRACKS_AND_VIAS_BASE::OnNetclassFilterSelect ), NULL, this );
|
m_netclassFilter->Connect( wxEVT_COMMAND_CHOICE_SELECTED, wxCommandEventHandler( DIALOG_GLOBAL_EDIT_TRACKS_AND_VIAS_BASE::OnNetclassFilterSelect ), NULL, this );
|
||||||
|
@ -184,5 +180,5 @@ DIALOG_GLOBAL_EDIT_TRACKS_AND_VIAS_BASE::~DIALOG_GLOBAL_EDIT_TRACKS_AND_VIAS_BAS
|
||||||
m_netclassFilter->Disconnect( wxEVT_COMMAND_CHOICE_SELECTED, wxCommandEventHandler( DIALOG_GLOBAL_EDIT_TRACKS_AND_VIAS_BASE::OnNetclassFilterSelect ), NULL, this );
|
m_netclassFilter->Disconnect( wxEVT_COMMAND_CHOICE_SELECTED, wxCommandEventHandler( DIALOG_GLOBAL_EDIT_TRACKS_AND_VIAS_BASE::OnNetclassFilterSelect ), NULL, this );
|
||||||
m_layerFilter->Disconnect( wxEVT_COMMAND_COMBOBOX_SELECTED, wxCommandEventHandler( DIALOG_GLOBAL_EDIT_TRACKS_AND_VIAS_BASE::OnLayerFilterSelect ), NULL, this );
|
m_layerFilter->Disconnect( wxEVT_COMMAND_COMBOBOX_SELECTED, wxCommandEventHandler( DIALOG_GLOBAL_EDIT_TRACKS_AND_VIAS_BASE::OnLayerFilterSelect ), NULL, this );
|
||||||
m_netclassGrid->Disconnect( wxEVT_SIZE, wxSizeEventHandler( DIALOG_GLOBAL_EDIT_TRACKS_AND_VIAS_BASE::OnSizeNetclassGrid ), NULL, this );
|
m_netclassGrid->Disconnect( wxEVT_SIZE, wxSizeEventHandler( DIALOG_GLOBAL_EDIT_TRACKS_AND_VIAS_BASE::OnSizeNetclassGrid ), NULL, this );
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -1,12 +1,11 @@
|
||||||
///////////////////////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////////////////////
|
||||||
// C++ code generated with wxFormBuilder (version Aug 2 2018)
|
// C++ code generated with wxFormBuilder (version Nov 23 2018)
|
||||||
// http://www.wxformbuilder.org/
|
// http://www.wxformbuilder.org/
|
||||||
//
|
//
|
||||||
// PLEASE DO *NOT* EDIT THIS FILE!
|
// PLEASE DO *NOT* EDIT THIS FILE!
|
||||||
///////////////////////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
#ifndef __DIALOG_GLOBAL_EDIT_TRACKS_AND_VIAS_BASE_H__
|
#pragma once
|
||||||
#define __DIALOG_GLOBAL_EDIT_TRACKS_AND_VIAS_BASE_H__
|
|
||||||
|
|
||||||
#include <wx/artprov.h>
|
#include <wx/artprov.h>
|
||||||
#include <wx/xrc/xmlres.h>
|
#include <wx/xrc/xmlres.h>
|
||||||
|
@ -26,6 +25,7 @@ class PCB_LAYER_BOX_SELECTOR;
|
||||||
#include <wx/choice.h>
|
#include <wx/choice.h>
|
||||||
#include <wx/bmpcbox.h>
|
#include <wx/bmpcbox.h>
|
||||||
#include <wx/radiobut.h>
|
#include <wx/radiobut.h>
|
||||||
|
#include <wx/combobox.h>
|
||||||
#include <wx/grid.h>
|
#include <wx/grid.h>
|
||||||
#include <wx/button.h>
|
#include <wx/button.h>
|
||||||
#include <wx/dialog.h>
|
#include <wx/dialog.h>
|
||||||
|
@ -41,38 +41,37 @@ class PCB_LAYER_BOX_SELECTOR;
|
||||||
class DIALOG_GLOBAL_EDIT_TRACKS_AND_VIAS_BASE : public DIALOG_SHIM
|
class DIALOG_GLOBAL_EDIT_TRACKS_AND_VIAS_BASE : public DIALOG_SHIM
|
||||||
{
|
{
|
||||||
private:
|
private:
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
wxCheckBox* m_tracks;
|
wxCheckBox* m_tracks;
|
||||||
wxCheckBox* m_vias;
|
wxCheckBox* m_vias;
|
||||||
wxCheckBox* m_netFilterOpt;
|
wxCheckBox* m_netFilterOpt;
|
||||||
NET_SELECTOR* m_netFilter;
|
NET_SELECTOR* m_netFilter;
|
||||||
wxCheckBox* m_netclassFilterOpt;
|
wxCheckBox* m_netclassFilterOpt;
|
||||||
wxChoice* m_netclassFilter;
|
wxChoice* m_netclassFilter;
|
||||||
wxCheckBox* m_layerFilterOpt;
|
wxCheckBox* m_layerFilterOpt;
|
||||||
PCB_LAYER_BOX_SELECTOR* m_layerFilter;
|
PCB_LAYER_BOX_SELECTOR* m_layerFilter;
|
||||||
wxRadioButton* m_setToSpecifiedValues;
|
wxRadioButton* m_setToSpecifiedValues;
|
||||||
wxChoice* m_trackWidthSelectBox;
|
wxComboBox* m_trackWidthSelectBox;
|
||||||
wxChoice* m_viaSizesSelectBox;
|
wxComboBox* m_viaSizesSelectBox;
|
||||||
PCB_LAYER_BOX_SELECTOR* m_layerBox;
|
PCB_LAYER_BOX_SELECTOR* m_layerBox;
|
||||||
wxRadioButton* m_setToNetclassValues;
|
wxRadioButton* m_setToNetclassValues;
|
||||||
wxGrid* m_netclassGrid;
|
wxGrid* m_netclassGrid;
|
||||||
wxStdDialogButtonSizer* m_sdbSizer;
|
wxStdDialogButtonSizer* m_sdbSizer;
|
||||||
wxButton* m_sdbSizerOK;
|
wxButton* m_sdbSizerOK;
|
||||||
wxButton* m_sdbSizerCancel;
|
wxButton* m_sdbSizerCancel;
|
||||||
|
|
||||||
// Virtual event handlers, overide them in your derived class
|
// Virtual event handlers, overide them in your derived class
|
||||||
virtual void OnUpdateUI( wxUpdateUIEvent& event ) { event.Skip(); }
|
virtual void OnUpdateUI( wxUpdateUIEvent& event ) { event.Skip(); }
|
||||||
virtual void OnNetclassFilterSelect( wxCommandEvent& event ) { event.Skip(); }
|
virtual void OnNetclassFilterSelect( wxCommandEvent& event ) { event.Skip(); }
|
||||||
virtual void OnLayerFilterSelect( wxCommandEvent& event ) { event.Skip(); }
|
virtual void OnLayerFilterSelect( wxCommandEvent& event ) { event.Skip(); }
|
||||||
virtual void OnSizeNetclassGrid( wxSizeEvent& event ) { event.Skip(); }
|
virtual void OnSizeNetclassGrid( wxSizeEvent& event ) { event.Skip(); }
|
||||||
|
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
||||||
DIALOG_GLOBAL_EDIT_TRACKS_AND_VIAS_BASE( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("Set Track and Via Properties"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( -1,-1 ), long style = wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER );
|
DIALOG_GLOBAL_EDIT_TRACKS_AND_VIAS_BASE( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("Set Track and Via Properties"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( -1,-1 ), long style = wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER );
|
||||||
~DIALOG_GLOBAL_EDIT_TRACKS_AND_VIAS_BASE();
|
~DIALOG_GLOBAL_EDIT_TRACKS_AND_VIAS_BASE();
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif //__DIALOG_GLOBAL_EDIT_TRACKS_AND_VIAS_BASE_H__
|
|
||||||
|
|
|
@ -92,8 +92,8 @@ BEGIN_EVENT_TABLE( FOOTPRINT_EDIT_FRAME, PCB_BASE_FRAME )
|
||||||
|
|
||||||
EVT_SIZE( FOOTPRINT_EDIT_FRAME::OnSize )
|
EVT_SIZE( FOOTPRINT_EDIT_FRAME::OnSize )
|
||||||
|
|
||||||
EVT_CHOICE( ID_ON_ZOOM_SELECT, FOOTPRINT_EDIT_FRAME::OnSelectZoom )
|
EVT_COMBOBOX( ID_ON_ZOOM_SELECT, FOOTPRINT_EDIT_FRAME::OnSelectZoom )
|
||||||
EVT_CHOICE( ID_ON_GRID_SELECT, FOOTPRINT_EDIT_FRAME::OnSelectGrid )
|
EVT_COMBOBOX( ID_ON_GRID_SELECT, FOOTPRINT_EDIT_FRAME::OnSelectGrid )
|
||||||
|
|
||||||
EVT_TOOL( ID_MODEDIT_SAVE, FOOTPRINT_EDIT_FRAME::Process_Special_Functions )
|
EVT_TOOL( ID_MODEDIT_SAVE, FOOTPRINT_EDIT_FRAME::Process_Special_Functions )
|
||||||
EVT_TOOL( ID_MODEDIT_SAVE_AS, FOOTPRINT_EDIT_FRAME::Process_Special_Functions )
|
EVT_TOOL( ID_MODEDIT_SAVE_AS, FOOTPRINT_EDIT_FRAME::Process_Special_Functions )
|
||||||
|
|
|
@ -94,8 +94,8 @@ BEGIN_EVENT_TABLE( FOOTPRINT_VIEWER_FRAME, EDA_DRAW_FRAME )
|
||||||
EVT_TOOL( ID_MODVIEW_PREVIOUS, FOOTPRINT_VIEWER_FRAME::OnIterateFootprintList )
|
EVT_TOOL( ID_MODVIEW_PREVIOUS, FOOTPRINT_VIEWER_FRAME::OnIterateFootprintList )
|
||||||
EVT_TOOL( ID_MODVIEW_EXPORT_TO_BOARD, FOOTPRINT_VIEWER_FRAME::ExportSelectedFootprint )
|
EVT_TOOL( ID_MODVIEW_EXPORT_TO_BOARD, FOOTPRINT_VIEWER_FRAME::ExportSelectedFootprint )
|
||||||
EVT_TOOL( ID_MODVIEW_SHOW_3D_VIEW, FOOTPRINT_VIEWER_FRAME::Show3D_Frame )
|
EVT_TOOL( ID_MODVIEW_SHOW_3D_VIEW, FOOTPRINT_VIEWER_FRAME::Show3D_Frame )
|
||||||
EVT_CHOICE( ID_ON_ZOOM_SELECT, FOOTPRINT_VIEWER_FRAME::OnSelectZoom )
|
EVT_COMBOBOX( ID_ON_ZOOM_SELECT, FOOTPRINT_VIEWER_FRAME::OnSelectZoom )
|
||||||
EVT_CHOICE( ID_ON_GRID_SELECT, FOOTPRINT_VIEWER_FRAME::OnSelectGrid )
|
EVT_COMBOBOX( ID_ON_GRID_SELECT, FOOTPRINT_VIEWER_FRAME::OnSelectGrid )
|
||||||
|
|
||||||
EVT_UPDATE_UI( ID_ON_GRID_SELECT, FOOTPRINT_VIEWER_FRAME::OnUpdateSelectGrid )
|
EVT_UPDATE_UI( ID_ON_GRID_SELECT, FOOTPRINT_VIEWER_FRAME::OnUpdateSelectGrid )
|
||||||
EVT_UPDATE_UI( ID_ON_ZOOM_SELECT, FOOTPRINT_VIEWER_FRAME::OnUpdateSelectZoom )
|
EVT_UPDATE_UI( ID_ON_ZOOM_SELECT, FOOTPRINT_VIEWER_FRAME::OnUpdateSelectZoom )
|
||||||
|
|
|
@ -1075,7 +1075,7 @@ void PCB_BASE_FRAME::SetFastGrid1()
|
||||||
|
|
||||||
if( m_gridSelectBox )
|
if( m_gridSelectBox )
|
||||||
{
|
{
|
||||||
wxCommandEvent cmd( wxEVT_CHOICE );
|
wxCommandEvent cmd( wxEVT_COMBOBOX );
|
||||||
cmd.SetEventObject( this );
|
cmd.SetEventObject( this );
|
||||||
OnSelectGrid( cmd );
|
OnSelectGrid( cmd );
|
||||||
}
|
}
|
||||||
|
@ -1094,7 +1094,7 @@ void PCB_BASE_FRAME::SetFastGrid2()
|
||||||
|
|
||||||
if( m_gridSelectBox )
|
if( m_gridSelectBox )
|
||||||
{
|
{
|
||||||
wxCommandEvent cmd( wxEVT_CHOICE );
|
wxCommandEvent cmd( wxEVT_COMBOBOX );
|
||||||
cmd.SetEventObject( this );
|
cmd.SetEventObject( this );
|
||||||
OnSelectGrid( cmd );
|
OnSelectGrid( cmd );
|
||||||
}
|
}
|
||||||
|
@ -1108,7 +1108,7 @@ void PCB_BASE_FRAME::SetNextGrid()
|
||||||
|
|
||||||
if( m_gridSelectBox )
|
if( m_gridSelectBox )
|
||||||
{
|
{
|
||||||
wxCommandEvent cmd( wxEVT_CHOICE );
|
wxCommandEvent cmd( wxEVT_COMBOBOX );
|
||||||
cmd.SetEventObject( this );
|
cmd.SetEventObject( this );
|
||||||
OnSelectGrid( cmd );
|
OnSelectGrid( cmd );
|
||||||
}
|
}
|
||||||
|
@ -1123,7 +1123,7 @@ void PCB_BASE_FRAME::SetPrevGrid()
|
||||||
|
|
||||||
if( m_gridSelectBox )
|
if( m_gridSelectBox )
|
||||||
{
|
{
|
||||||
wxCommandEvent cmd( wxEVT_CHOICE );
|
wxCommandEvent cmd( wxEVT_COMBOBOX );
|
||||||
cmd.SetEventObject( this );
|
cmd.SetEventObject( this );
|
||||||
OnSelectGrid( cmd );
|
OnSelectGrid( cmd );
|
||||||
}
|
}
|
||||||
|
|
|
@ -96,8 +96,8 @@ BEGIN_EVENT_TABLE( PCB_EDIT_FRAME, PCB_BASE_FRAME )
|
||||||
EVT_SOCKET( ID_EDA_SOCKET_EVENT_SERV, PCB_EDIT_FRAME::OnSockRequestServer )
|
EVT_SOCKET( ID_EDA_SOCKET_EVENT_SERV, PCB_EDIT_FRAME::OnSockRequestServer )
|
||||||
EVT_SOCKET( ID_EDA_SOCKET_EVENT, PCB_EDIT_FRAME::OnSockRequest )
|
EVT_SOCKET( ID_EDA_SOCKET_EVENT, PCB_EDIT_FRAME::OnSockRequest )
|
||||||
|
|
||||||
EVT_CHOICE( ID_ON_ZOOM_SELECT, PCB_EDIT_FRAME::OnSelectZoom )
|
EVT_COMBOBOX( ID_ON_ZOOM_SELECT, PCB_EDIT_FRAME::OnSelectZoom )
|
||||||
EVT_CHOICE( ID_ON_GRID_SELECT, PCB_EDIT_FRAME::OnSelectGrid )
|
EVT_COMBOBOX( ID_ON_GRID_SELECT, PCB_EDIT_FRAME::OnSelectGrid )
|
||||||
|
|
||||||
EVT_CLOSE( PCB_EDIT_FRAME::OnCloseWindow )
|
EVT_CLOSE( PCB_EDIT_FRAME::OnCloseWindow )
|
||||||
EVT_SIZE( PCB_EDIT_FRAME::OnSize )
|
EVT_SIZE( PCB_EDIT_FRAME::OnSize )
|
||||||
|
@ -197,8 +197,8 @@ BEGIN_EVENT_TABLE( PCB_EDIT_FRAME, PCB_BASE_FRAME )
|
||||||
EVT_TOOL( ID_AUX_TOOLBAR_PCB_SELECT_LAYER_PAIR, PCB_EDIT_FRAME::Process_Special_Functions )
|
EVT_TOOL( ID_AUX_TOOLBAR_PCB_SELECT_LAYER_PAIR, PCB_EDIT_FRAME::Process_Special_Functions )
|
||||||
EVT_TOOL( ID_AUX_TOOLBAR_PCB_SELECT_AUTO_WIDTH, PCB_EDIT_FRAME::Tracks_and_Vias_Size_Event )
|
EVT_TOOL( ID_AUX_TOOLBAR_PCB_SELECT_AUTO_WIDTH, PCB_EDIT_FRAME::Tracks_and_Vias_Size_Event )
|
||||||
EVT_COMBOBOX( ID_TOOLBARH_PCB_SELECT_LAYER, PCB_EDIT_FRAME::Process_Special_Functions )
|
EVT_COMBOBOX( ID_TOOLBARH_PCB_SELECT_LAYER, PCB_EDIT_FRAME::Process_Special_Functions )
|
||||||
EVT_CHOICE( ID_AUX_TOOLBAR_PCB_TRACK_WIDTH, PCB_EDIT_FRAME::Tracks_and_Vias_Size_Event )
|
EVT_COMBOBOX( ID_AUX_TOOLBAR_PCB_TRACK_WIDTH, PCB_EDIT_FRAME::Tracks_and_Vias_Size_Event )
|
||||||
EVT_CHOICE( ID_AUX_TOOLBAR_PCB_VIA_SIZE, PCB_EDIT_FRAME::Tracks_and_Vias_Size_Event )
|
EVT_COMBOBOX( ID_AUX_TOOLBAR_PCB_VIA_SIZE, PCB_EDIT_FRAME::Tracks_and_Vias_Size_Event )
|
||||||
|
|
||||||
|
|
||||||
#if defined(KICAD_SCRIPTING) && defined(KICAD_SCRIPTING_ACTION_MENU)
|
#if defined(KICAD_SCRIPTING) && defined(KICAD_SCRIPTING_ACTION_MENU)
|
||||||
|
|
|
@ -262,8 +262,8 @@ protected:
|
||||||
|
|
||||||
public:
|
public:
|
||||||
PCB_LAYER_BOX_SELECTOR* m_SelLayerBox; // a combo box to display and select active layer
|
PCB_LAYER_BOX_SELECTOR* m_SelLayerBox; // a combo box to display and select active layer
|
||||||
wxChoice* m_SelTrackWidthBox; // a choice box to display and select current track width
|
wxComboBox* m_SelTrackWidthBox; // a choice box to display and select current track width
|
||||||
wxChoice* m_SelViaSizeBox; // a choice box to display and select current via diameter
|
wxComboBox* m_SelViaSizeBox; // a choice box to display and select current via diameter
|
||||||
|
|
||||||
bool m_show_microwave_tools;
|
bool m_show_microwave_tools;
|
||||||
bool m_show_layer_manager_tools;
|
bool m_show_layer_manager_tools;
|
||||||
|
@ -353,8 +353,8 @@ public:
|
||||||
void OnUpdatePCBFromSch( wxCommandEvent& event );
|
void OnUpdatePCBFromSch( wxCommandEvent& event );
|
||||||
void OnRunEeschema( wxCommandEvent& event );
|
void OnRunEeschema( wxCommandEvent& event );
|
||||||
|
|
||||||
void UpdateTrackWidthSelectBox( wxChoice* aTrackWidthSelectBox );
|
void UpdateTrackWidthSelectBox( wxComboBox* aTrackWidthSelectBox );
|
||||||
void UpdateViaSizeSelectBox( wxChoice* aViaSizeSelectBox );
|
void UpdateViaSizeSelectBox( wxComboBox* aViaSizeSelectBox );
|
||||||
|
|
||||||
void GetKicadAbout( wxCommandEvent& event );
|
void GetKicadAbout( wxCommandEvent& event );
|
||||||
|
|
||||||
|
|
|
@ -115,16 +115,16 @@ void FOOTPRINT_EDIT_FRAME::ReCreateHToolbar()
|
||||||
KiScaledSeparator( m_mainToolBar, this );
|
KiScaledSeparator( m_mainToolBar, this );
|
||||||
|
|
||||||
// Grid selection choice box.
|
// Grid selection choice box.
|
||||||
m_gridSelectBox = new wxChoice( m_mainToolBar, ID_ON_GRID_SELECT,
|
m_gridSelectBox = new wxComboBox( m_mainToolBar, ID_ON_GRID_SELECT, wxEmptyString,
|
||||||
wxDefaultPosition, wxDefaultSize, 0, NULL );
|
wxDefaultPosition, wxDefaultSize, 0, nullptr, wxCB_READONLY );
|
||||||
UpdateGridSelectBox();
|
UpdateGridSelectBox();
|
||||||
m_mainToolBar->AddControl( m_gridSelectBox );
|
m_mainToolBar->AddControl( m_gridSelectBox );
|
||||||
|
|
||||||
KiScaledSeparator( m_mainToolBar, this );
|
KiScaledSeparator( m_mainToolBar, this );
|
||||||
|
|
||||||
// Zoom selection choice box.
|
// Zoom selection choice box.
|
||||||
m_zoomSelectBox = new wxChoice( m_mainToolBar, ID_ON_ZOOM_SELECT,
|
m_zoomSelectBox = new wxComboBox( m_mainToolBar, ID_ON_ZOOM_SELECT, wxEmptyString,
|
||||||
wxDefaultPosition, wxDefaultSize, 0, NULL );
|
wxDefaultPosition, wxDefaultSize, 0, nullptr, wxCB_READONLY );
|
||||||
updateZoomSelectBox();
|
updateZoomSelectBox();
|
||||||
m_mainToolBar->AddControl( m_zoomSelectBox );
|
m_mainToolBar->AddControl( m_zoomSelectBox );
|
||||||
|
|
||||||
|
|
|
@ -102,16 +102,16 @@ void FOOTPRINT_VIEWER_FRAME::ReCreateHToolbar()
|
||||||
KiScaledSeparator( m_mainToolBar, this );
|
KiScaledSeparator( m_mainToolBar, this );
|
||||||
|
|
||||||
// Grid selection choice box.
|
// Grid selection choice box.
|
||||||
m_gridSelectBox = new wxChoice( m_mainToolBar, ID_ON_GRID_SELECT,
|
m_gridSelectBox = new wxComboBox( m_mainToolBar, ID_ON_GRID_SELECT, wxEmptyString,
|
||||||
wxDefaultPosition, wxDefaultSize, 0, NULL );
|
wxDefaultPosition, wxDefaultSize, 0, nullptr, wxCB_READONLY );
|
||||||
UpdateGridSelectBox();
|
UpdateGridSelectBox();
|
||||||
m_mainToolBar->AddControl( m_gridSelectBox );
|
m_mainToolBar->AddControl( m_gridSelectBox );
|
||||||
|
|
||||||
KiScaledSeparator( m_mainToolBar, this );
|
KiScaledSeparator( m_mainToolBar, this );
|
||||||
|
|
||||||
// Zoom selection choice box.
|
// Zoom selection choice box.
|
||||||
m_zoomSelectBox = new wxChoice( m_mainToolBar, ID_ON_ZOOM_SELECT,
|
m_zoomSelectBox = new wxComboBox( m_mainToolBar, ID_ON_ZOOM_SELECT, wxEmptyString,
|
||||||
wxDefaultPosition, wxDefaultSize, 0, NULL );
|
wxDefaultPosition, wxDefaultSize, 0, nullptr, wxCB_READONLY );
|
||||||
updateZoomSelectBox();
|
updateZoomSelectBox();
|
||||||
m_mainToolBar->AddControl( m_zoomSelectBox );
|
m_mainToolBar->AddControl( m_zoomSelectBox );
|
||||||
|
|
||||||
|
|
|
@ -583,18 +583,16 @@ void PCB_EDIT_FRAME::ReCreateAuxiliaryToolbar()
|
||||||
/* Set up toolbar items */
|
/* Set up toolbar items */
|
||||||
|
|
||||||
// Creates box to display and choose tracks widths:
|
// Creates box to display and choose tracks widths:
|
||||||
m_SelTrackWidthBox = new wxChoice( m_auxiliaryToolBar,
|
m_SelTrackWidthBox = new wxComboBox( m_auxiliaryToolBar,
|
||||||
ID_AUX_TOOLBAR_PCB_TRACK_WIDTH,
|
ID_AUX_TOOLBAR_PCB_TRACK_WIDTH, wxEmptyString,
|
||||||
wxDefaultPosition, wxDefaultSize,
|
wxDefaultPosition, wxDefaultSize, 0, nullptr, wxCB_READONLY );
|
||||||
0, NULL );
|
|
||||||
UpdateTrackWidthSelectBox( m_SelTrackWidthBox );
|
UpdateTrackWidthSelectBox( m_SelTrackWidthBox );
|
||||||
m_auxiliaryToolBar->AddControl( m_SelTrackWidthBox );
|
m_auxiliaryToolBar->AddControl( m_SelTrackWidthBox );
|
||||||
|
|
||||||
// Creates box to display and choose vias diameters:
|
// Creates box to display and choose vias diameters:
|
||||||
m_SelViaSizeBox = new wxChoice( m_auxiliaryToolBar,
|
m_SelViaSizeBox = new wxComboBox( m_auxiliaryToolBar,
|
||||||
ID_AUX_TOOLBAR_PCB_VIA_SIZE,
|
ID_AUX_TOOLBAR_PCB_VIA_SIZE, wxEmptyString,
|
||||||
wxDefaultPosition, wxDefaultSize,
|
wxDefaultPosition, wxDefaultSize, 0, nullptr, wxCB_READONLY );
|
||||||
0, NULL );
|
|
||||||
UpdateViaSizeSelectBox( m_SelViaSizeBox );
|
UpdateViaSizeSelectBox( m_SelViaSizeBox );
|
||||||
m_auxiliaryToolBar->AddControl( m_SelViaSizeBox );
|
m_auxiliaryToolBar->AddControl( m_SelViaSizeBox );
|
||||||
KiScaledSeparator( m_auxiliaryToolBar, this );
|
KiScaledSeparator( m_auxiliaryToolBar, this );
|
||||||
|
@ -609,20 +607,17 @@ void PCB_EDIT_FRAME::ReCreateAuxiliaryToolbar()
|
||||||
|
|
||||||
// Add the box to display and select the current grid size:
|
// Add the box to display and select the current grid size:
|
||||||
KiScaledSeparator( m_auxiliaryToolBar, this );
|
KiScaledSeparator( m_auxiliaryToolBar, this );
|
||||||
m_gridSelectBox = new wxChoice( m_auxiliaryToolBar,
|
m_gridSelectBox = new wxComboBox( m_auxiliaryToolBar, ID_ON_GRID_SELECT, wxEmptyString,
|
||||||
ID_ON_GRID_SELECT,
|
wxDefaultPosition, wxDefaultSize, 0, nullptr, wxCB_READONLY );
|
||||||
wxDefaultPosition, wxDefaultSize,
|
|
||||||
0, NULL );
|
|
||||||
UpdateGridSelectBox();
|
UpdateGridSelectBox();
|
||||||
|
|
||||||
m_auxiliaryToolBar->AddControl( m_gridSelectBox );
|
m_auxiliaryToolBar->AddControl( m_gridSelectBox );
|
||||||
|
|
||||||
// Add the box to display and select the current Zoom
|
// Add the box to display and select the current Zoom
|
||||||
KiScaledSeparator( m_auxiliaryToolBar, this );
|
KiScaledSeparator( m_auxiliaryToolBar, this );
|
||||||
m_zoomSelectBox = new wxChoice( m_auxiliaryToolBar,
|
m_zoomSelectBox = new wxComboBox( m_auxiliaryToolBar,
|
||||||
ID_ON_ZOOM_SELECT,
|
ID_ON_ZOOM_SELECT, wxEmptyString,
|
||||||
wxDefaultPosition, wxDefaultSize,
|
wxDefaultPosition, wxDefaultSize, 0, nullptr, wxCB_READONLY );
|
||||||
0, NULL );
|
|
||||||
updateZoomSelectBox();
|
updateZoomSelectBox();
|
||||||
m_auxiliaryToolBar->AddControl( m_zoomSelectBox );
|
m_auxiliaryToolBar->AddControl( m_zoomSelectBox );
|
||||||
|
|
||||||
|
@ -631,7 +626,7 @@ void PCB_EDIT_FRAME::ReCreateAuxiliaryToolbar()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void PCB_EDIT_FRAME::UpdateTrackWidthSelectBox( wxChoice* aTrackWidthSelectBox )
|
void PCB_EDIT_FRAME::UpdateTrackWidthSelectBox( wxComboBox* aTrackWidthSelectBox )
|
||||||
{
|
{
|
||||||
if( aTrackWidthSelectBox == NULL )
|
if( aTrackWidthSelectBox == NULL )
|
||||||
return;
|
return;
|
||||||
|
@ -672,7 +667,7 @@ void PCB_EDIT_FRAME::UpdateTrackWidthSelectBox( wxChoice* aTrackWidthSelectBox )
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void PCB_EDIT_FRAME::UpdateViaSizeSelectBox( wxChoice* aViaSizeSelectBox )
|
void PCB_EDIT_FRAME::UpdateViaSizeSelectBox( wxComboBox* aViaSizeSelectBox )
|
||||||
{
|
{
|
||||||
if( aViaSizeSelectBox == NULL )
|
if( aViaSizeSelectBox == NULL )
|
||||||
return;
|
return;
|
||||||
|
|
Loading…
Reference in New Issue