Rework on pcbnew menubar: make code more easy to read and modify.

This commit is contained in:
jean-pierre charras 2017-02-24 12:43:10 +01:00
parent 23d4da9e49
commit 6ae7c15d89
3 changed files with 620 additions and 504 deletions

View File

@ -55,7 +55,7 @@ static void prepareToolsMenu( wxMenu* aParentMenu );
// Build the help menu
static void prepareHelpMenu( wxMenu* aParentMenu );
// Build the help submenu
// Build the import/export submenu
static void prepareImportExportMenu( wxMenu* aParentMenu );
// Build the edit menu

View File

@ -196,10 +196,10 @@ void WIDGET_EESCHEMA_COLOR_CONFIG::CreateControls()
iconDC.DrawRectangle( 0, 0, BUTT_SIZE_X, BUTT_SIZE_Y );
buttonId++;
wxBitmapButton* m_SelBgColor = new wxBitmapButton(
wxBitmapButton* selBgColorBtn = new wxBitmapButton(
this, buttonId, bitmap, wxDefaultPosition,
wxSize( BUTT_SIZE_X + 8, BUTT_SIZE_Y + 6 ) );
m_SelBgColor->SetClientData( (void*) &bgColorButton );
selBgColorBtn->SetClientData( (void*) &bgColorButton );
Connect( 1800, buttonId, wxEVT_COMMAND_BUTTON_CLICKED,
wxCommandEventHandler( WIDGET_EESCHEMA_COLOR_CONFIG::SetColor ) );
@ -214,7 +214,7 @@ void WIDGET_EESCHEMA_COLOR_CONFIG::CreateControls()
// Add a spacer to improve appearance.
columnBoxSizer->AddSpacer( 5 );
columnBoxSizer->Add( bgColorLabel, 1, wxALIGN_CENTER_VERTICAL | wxALL, 5 );
columnBoxSizer->Add( m_SelBgColor, 1, wxALIGN_CENTER_VERTICAL | wxRIGHT | wxBOTTOM, 5 );
columnBoxSizer->Add( selBgColorBtn, 1, wxALIGN_CENTER_VERTICAL | wxRIGHT | wxBOTTOM, 5 );
}
currentColors[ LAYER_BACKGROUND ] = bgColor;

File diff suppressed because it is too large Load Diff