X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/489468feaa08b8f504735eecca522fb8d0f825d2..64ea838d8f4d1853b7d850db93ee565e901d099a:/src/osx/carbon/control.cpp diff --git a/src/osx/carbon/control.cpp b/src/osx/carbon/control.cpp index f787ea9812..dba7a99689 100644 --- a/src/osx/carbon/control.cpp +++ b/src/osx/carbon/control.cpp @@ -1,5 +1,5 @@ ///////////////////////////////////////////////////////////////////////////// -// Name: src/mac/carbon/control.cpp +// Name: src/osx/carbon/control.cpp // Purpose: wxControl class // Author: Stefan Csomor // Modified by: @@ -27,12 +27,7 @@ #include "wx/sizer.h" #endif // WX_PRECOMP -#include "wx/notebook.h" -#include "wx/tabctrl.h" -#include "wx/spinbutt.h" - -#include "wx/mac/uma.h" -#include "wx/mac/private.h" +#include "wx/osx/private.h" IMPLEMENT_ABSTRACT_CLASS(wxControl, wxWindow) @@ -68,11 +63,6 @@ bool wxControl::Create( wxWindow *parent, return rval; } -wxControl::~wxControl() -{ - m_isBeingDeleted = true; -} - bool wxControl::ProcessCommand( wxCommandEvent &event ) { // Tries: @@ -83,9 +73,10 @@ bool wxControl::ProcessCommand( wxCommandEvent &event ) void wxControl::OnKeyDown( wxKeyEvent &WXUNUSED(event) ) { - if ( m_peer == NULL || !m_peer->Ok() ) + if ( GetPeer() == NULL || !GetPeer()->IsOk() ) return; +#if wxOSX_USE_CARBON UInt32 keyCode, modifiers; char charCode; @@ -93,5 +84,8 @@ void wxControl::OnKeyDown( wxKeyEvent &WXUNUSED(event) ) GetEventParameter( (EventRef)wxTheApp->MacGetCurrentEvent(), kEventParamKeyMacCharCodes, typeChar, NULL, sizeof(char), NULL, &charCode ); GetEventParameter( (EventRef)wxTheApp->MacGetCurrentEvent(), kEventParamKeyModifiers, typeUInt32, NULL, sizeof(UInt32), NULL, &modifiers ); - m_peer->HandleKey( keyCode, charCode, modifiers ); + GetPeer()->HandleKey( keyCode, charCode, modifiers ); +#else + // TODO +#endif }