From 0ec256ccb4297b12375768cfefc7dd3720a86bf6 Mon Sep 17 00:00:00 2001 From: Maciej Suminski Date: Mon, 21 Jul 2014 12:54:58 +0200 Subject: [PATCH] Fixed bug: solder paste clearance is not displayed (GAL). --- pcbnew/pcb_painter.cpp | 6 +++--- pcbnew/pcbnew_config.cpp | 11 ++++++++++- 2 files changed, 13 insertions(+), 4 deletions(-) diff --git a/pcbnew/pcb_painter.cpp b/pcbnew/pcb_painter.cpp index 4adc0bc13c..a1eb3f77af 100644 --- a/pcbnew/pcb_painter.cpp +++ b/pcbnew/pcb_painter.cpp @@ -521,11 +521,11 @@ void PCB_PAINTER::draw( const D_PAD* aPad, int aLayer ) else if( aLayer == F_Paste || aLayer == B_Paste ) { // Drawing solderpaste - int solderpasteMargin = aPad->GetLocalSolderPasteMargin(); + wxSize solderpasteMargin = aPad->GetSolderPasteMargin(); m_gal->Translate( VECTOR2D( aPad->GetOffset() ) ); - size = VECTOR2D( aPad->GetSize().x / 2.0 + solderpasteMargin, - aPad->GetSize().y / 2.0 + solderpasteMargin ); + size = VECTOR2D( aPad->GetSize().x / 2.0 + solderpasteMargin.x, + aPad->GetSize().y / 2.0 + solderpasteMargin.y ); shape = aPad->GetShape(); } else diff --git a/pcbnew/pcbnew_config.cpp b/pcbnew/pcbnew_config.cpp index 963f9c4ba2..1125628dfe 100644 --- a/pcbnew/pcbnew_config.cpp +++ b/pcbnew/pcbnew_config.cpp @@ -32,6 +32,7 @@ #include #include #include +#include #include #include #include @@ -47,6 +48,7 @@ #include #include +#include #include #include #include @@ -166,7 +168,14 @@ void PCB_EDIT_FRAME::Process_Config( wxCommandEvent& event ) case ID_PCB_MASK_CLEARANCE: { DIALOG_PADS_MASK_CLEARANCE dlg( this ); - dlg.ShowModal(); + + if( dlg.ShowModal() == 1 && IsGalCanvasActive() ) + { + for( MODULE* module = GetBoard()->m_Modules; module; module = module->Next() ) + module->ViewUpdate(); + + GetGalCanvas()->Refresh(); + } } break;