X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/d8c736e563cbf50bc5825c1a52878403ee48f513..594f0f5bf1355fb8d58f403d3ebacc1c1767c429:/src/mac/button.cpp?ds=sidebyside diff --git a/src/mac/button.cpp b/src/mac/button.cpp index d4837fd54a..b8689ca0fd 100644 --- a/src/mac/button.cpp +++ b/src/mac/button.cpp @@ -22,7 +22,7 @@ IMPLEMENT_DYNAMIC_CLASS(wxButton, wxControl) #endif -#include +#include "wx/mac/uma.h" // Button @@ -53,11 +53,12 @@ void wxButton::SetDefault() wxPanel *panel = wxDynamicCast(parent, wxPanel); if ( panel ) { - btnOldDefault = panel->GetDefaultItem(); + btnOldDefault = wxDynamicCast(panel->GetDefaultItem(), + wxButton); panel->SetDefaultItem(this); } -#ifdef __UNIX__ +#ifdef __DARWIN__ Boolean inData; if ( btnOldDefault && btnOldDefault->m_macControl ) {