implementing pure carbon event behaviour, getting rid of doubly executed events

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@37161 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Stefan Csomor
2006-01-26 16:41:53 +00:00
parent f03e8f9b16
commit 665b537f51

View File

@@ -990,23 +990,7 @@ void wxTextCtrl::OnChar(wxKeyEvent& event)
if (!eat_key)
{
// perform keystroke handling
if ( wxTheApp->MacGetCurrentEvent() != NULL && wxTheApp->MacGetCurrentEventHandlerCallRef() != NULL )
{
CallNextEventHandler( (EventHandlerCallRef)wxTheApp->MacGetCurrentEventHandlerCallRef(), (EventRef)wxTheApp->MacGetCurrentEvent() ) ;
}
else
{
EventRecord rec ;
if ( wxMacConvertEventToRecord( (EventRef) wxTheApp->MacGetCurrentEvent() , &rec ) )
{
short keycode, keychar ;
EventRecord *ev = &rec ;
keychar = short(ev->message & charCodeMask);
keycode = short(ev->message & keyCodeMask) >> 8 ;
m_peer->HandleKey( keycode , keychar , ev->modifiers ) ;
}
}
event.Skip(true) ;
}
if ( ( key >= 0x20 && key < WXK_START ) ||