diff --git a/pcbnew/dialogs/dialog_pad_properties.cpp b/pcbnew/dialogs/dialog_pad_properties.cpp index c62fdf85c8..7a29736d3e 100644 --- a/pcbnew/dialogs/dialog_pad_properties.cpp +++ b/pcbnew/dialogs/dialog_pad_properties.cpp @@ -332,11 +332,7 @@ void DIALOG_PAD_PROPERTIES::prepareCanvas() // fix the pad render mode (filled/not filled) auto settings = static_cast( view->GetPainter()->GetSettings() ); - if( m_cbShowPadOutline->IsChecked() ) - settings->m_ForcePadSketchModeOn = true; - else - settings->m_ForcePadSketchModeOff = true; - + settings->m_ForcePadSketchModeOn = m_cbShowPadOutline->IsChecked(); settings->SetHighContrast( false ); settings->m_ContrastModeDisplay = HIGH_CONTRAST_MODE::NORMAL; @@ -783,11 +779,7 @@ void DIALOG_PAD_PROPERTIES::onChangePadMode( wxCommandEvent& event ) // fix the pad render mode (filled/not filled) auto settings = static_cast( view->GetPainter()->GetSettings() ); - if( m_cbShowPadOutline->IsChecked() ) - settings->m_ForcePadSketchModeOn = true; - else - settings->m_ForcePadSketchModeOff = true; - + settings->m_ForcePadSketchModeOn = m_cbShowPadOutline->IsChecked(); settings->SetHighContrast( false ); settings->m_ContrastModeDisplay = HIGH_CONTRAST_MODE::NORMAL; @@ -1585,11 +1577,6 @@ bool DIALOG_PAD_PROPERTIES::TransferDataFromWindow() commit.Modify( m_currentPad ); - // redraw the area where the pad was, without pad (delete pad on screen) - m_currentPad->SetFlags( DO_NOT_DRAW ); - m_parent->GetCanvas()->Refresh(); - m_currentPad->ClearFlags( DO_NOT_DRAW ); - // Update values m_currentPad->SetShape( m_padMaster->GetShape() ); m_currentPad->SetAttribute( m_padMaster->GetAttribute() ); diff --git a/pcbnew/pcb_painter.cpp b/pcbnew/pcb_painter.cpp index fc26921999..7c01de4cfd 100644 --- a/pcbnew/pcb_painter.cpp +++ b/pcbnew/pcb_painter.cpp @@ -111,7 +111,6 @@ PCB_RENDER_SETTINGS::PCB_RENDER_SETTINGS() m_zoneOpacity = 1.0; m_imageOpacity = 1.0; - m_ForcePadSketchModeOff = false; m_ForcePadSketchModeOn = false; SetDashLengthRatio( 12 ); // From ISO 128-2 @@ -1195,9 +1194,7 @@ void PCB_PAINTER::draw( const PAD* aPad, int aLayer ) bool outline_mode = !viewer_settings()->m_ViewersDisplay.m_DisplayPadFill; - if( m_pcbSettings.m_ForcePadSketchModeOff ) - outline_mode = false; - else if( m_pcbSettings.m_ForcePadSketchModeOn ) + if( m_pcbSettings.m_ForcePadSketchModeOn ) outline_mode = true; if( outline_mode ) diff --git a/pcbnew/pcb_painter.h b/pcbnew/pcb_painter.h index 4535af93db..d5f2f3b6e7 100644 --- a/pcbnew/pcb_painter.h +++ b/pcbnew/pcb_painter.h @@ -119,7 +119,6 @@ public: const std::set& GetHiddenNets() const { return m_hiddenNets; } public: - bool m_ForcePadSketchModeOff; bool m_ForcePadSketchModeOn; ZONE_DISPLAY_MODE m_ZoneDisplayMode;