From 057a947a4bd43966ec1763325eeabd039358ea0b Mon Sep 17 00:00:00 2001 From: Marco Serantoni Date: Sun, 22 Dec 2013 18:39:37 +0100 Subject: [PATCH] [MacOSX] Fixing crash/missing refresh in pcb text --- pcbnew/dialogs/dialog_pcb_text_properties.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/pcbnew/dialogs/dialog_pcb_text_properties.cpp b/pcbnew/dialogs/dialog_pcb_text_properties.cpp index ceaf62f5cc..820b0f6ec3 100644 --- a/pcbnew/dialogs/dialog_pcb_text_properties.cpp +++ b/pcbnew/dialogs/dialog_pcb_text_properties.cpp @@ -187,11 +187,13 @@ void DIALOG_PCB_TEXT_PROPERTIES::OnOkClick( wxCommandEvent& event ) if( m_SelectedPCBText->GetFlags() != 0 ) m_SelectedPCBText->SetFlags( IN_EDIT ); +#ifndef USE_WX_OVERLAY // Erase old text on screen if context is available if( m_DC ) { m_SelectedPCBText->Draw( m_Parent->GetCanvas(), m_DC, GR_XOR ); } +#endif // Set the new text content if( !m_TextContentCtrl->GetValue().IsEmpty() ) @@ -268,12 +270,15 @@ void DIALOG_PCB_TEXT_PROPERTIES::OnOkClick( wxCommandEvent& event ) break; } +#ifndef USE_WX_OVERLAY // Finally, display new text if there is a context to do so if( m_DC ) { m_SelectedPCBText->Draw( m_Parent->GetCanvas(), m_DC, GR_OR ); } - +#else + m_parent->Refresh(); +#endif m_Parent->OnModify(); EndModal( 1 ); }