+ if ( btnOldDefault )
+ btnOldDefault->m_peer->SetData(kControlButtonPart , kControlPushButtonDefaultTag , (Boolean) 0 ) ;
+
+ m_peer->SetData(kControlButtonPart , kControlPushButtonDefaultTag , (Boolean) 1 ) ;
+}
+
+wxSize wxButton::DoGetBestSize() const
+{
+ if ( GetId() == wxID_HELP )
+ return wxSize( 20 , 20 ) ;
+
+ wxSize sz = GetDefaultSize() ;
+ int charspace = 8 ;
+
+ switch (GetWindowVariant())
+ {
+ case wxWINDOW_VARIANT_NORMAL:
+ case wxWINDOW_VARIANT_LARGE:
+ sz.y = 20 ;
+ charspace = 10 ;
+ break;
+
+ case wxWINDOW_VARIANT_SMALL:
+ sz.y = 17 ;
+ break;
+
+ case wxWINDOW_VARIANT_MINI:
+ sz.y = 15 ;
+ break;
+
+ default:
+ break;
+ }
+
+ Rect bestsize = { 0 , 0 , 0 , 0 } ;
+ m_peer->GetBestRect( &bestsize ) ;
+
+ int wBtn;
+ if ( EmptyRect( &bestsize ) )