X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/407f0db0504c39e022c063d64c03e2ff2117d5b3..d223107206e4dfa6768e0bc2455325dd49e4d2bb:/src/mac/carbon/control.cpp diff --git a/src/mac/carbon/control.cpp b/src/mac/carbon/control.cpp index ae57f23ab0..033c3bde05 100644 --- a/src/mac/carbon/control.cpp +++ b/src/mac/carbon/control.cpp @@ -196,6 +196,8 @@ wxControl::~wxControl() } if ( (ControlHandle) m_macControl ) { + // in case the callback might be called during destruction + ::SetControlColorProc( (ControlHandle) m_macControl , NULL ) ; ::DisposeControl( (ControlHandle) m_macControl ) ; m_macControl = NULL ; } @@ -433,7 +435,7 @@ void wxControl::MacAdjustControlRect() { if ( IsKindOf( CLASSINFO( wxButton ) ) ) { - m_width = m_label.Length() * 10 + 12 ; + m_width = m_label.Length() * 8 + 12 ; if ( m_width < 70 ) m_width = 70 ; }