void wxTreeCtrl::OnChar( wxKeyEvent &event )
{
+ wxTreeEvent te( wxEVT_COMMAND_TREE_KEY_DOWN, GetId() );
+ te.m_code = event.KeyCode();
+ te.SetEventObject( this );
+ GetEventHandler()->ProcessEvent( te );
+
if (m_current == 0)
{
event.Skip();
case ' ':
case WXK_RETURN:
{
- wxTreeEvent event( wxEVT_COMMAND_TREE_KEY_DOWN, GetId() );
+ wxTreeEvent event( wxEVT_COMMAND_TREE_ITEM_ACTIVATED, GetId() );
event.m_item = m_current;
event.m_code = 0;
event.SetEventObject( this );
if ( event.LeftDClick() )
{
- wxTreeEvent event( wxEVT_COMMAND_TREE_KEY_DOWN, GetId() );
+ wxTreeEvent event( wxEVT_COMMAND_TREE_ITEM_ACTIVATED, GetId() );
event.m_item = item;
event.m_code = 0;
event.SetEventObject( this );