X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/5c33522fca7cddc441a316f5b9fb50d7685435ba..12b5f4b4d2d8a07962da7ba3b78c8c1ec2634a67:/src/osx/carbon/textctrl.cpp diff --git a/src/osx/carbon/textctrl.cpp b/src/osx/carbon/textctrl.cpp index fc308b6712..ee9dd86bec 100644 --- a/src/osx/carbon/textctrl.cpp +++ b/src/osx/carbon/textctrl.cpp @@ -509,11 +509,12 @@ void wxMacUnicodeTextControl::InstallEventHandlers() { ::InstallControlEventHandler( m_controlRef , GetwxMacUnicodeTextControlEventHandlerUPP(), GetEventTypeCount(unicodeTextControlEventList), unicodeTextControlEventList, this, - NULL); + (EventHandlerRef*) &m_macTextCtrlEventHandler); } wxMacUnicodeTextControl::~wxMacUnicodeTextControl() { + ::RemoveEventHandler((EventHandlerRef) m_macTextCtrlEventHandler); } void wxMacUnicodeTextControl::VisibilityChanged(bool shown)