Spin control now emits TEXT_ENTER commands.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@26020 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
16dce3b37b
commit
4a11cca24d
@ -290,6 +290,16 @@ void wxSpinCtrl::OnChar( wxKeyEvent &event )
|
||||
}
|
||||
}
|
||||
|
||||
if ((event.GetKeyCode() == WXK_RETURN))
|
||||
{
|
||||
wxCommandEvent evt( wxEVT_COMMAND_TEXT_ENTER, m_windowId );
|
||||
evt.SetEventObject(this);
|
||||
GtkSpinButton *gsb = GTK_SPIN_BUTTON(m_widget);
|
||||
wxString val = wxGTK_CONV_BACK( gtk_entry_get_text( &gsb->entry ) );
|
||||
evt.SetString( val );
|
||||
if (GetEventHandler()->ProcessEvent(evt)) return;
|
||||
}
|
||||
|
||||
event.Skip();
|
||||
}
|
||||
|
||||
|
@ -290,6 +290,16 @@ void wxSpinCtrl::OnChar( wxKeyEvent &event )
|
||||
}
|
||||
}
|
||||
|
||||
if ((event.GetKeyCode() == WXK_RETURN))
|
||||
{
|
||||
wxCommandEvent evt( wxEVT_COMMAND_TEXT_ENTER, m_windowId );
|
||||
evt.SetEventObject(this);
|
||||
GtkSpinButton *gsb = GTK_SPIN_BUTTON(m_widget);
|
||||
wxString val = wxGTK_CONV_BACK( gtk_entry_get_text( &gsb->entry ) );
|
||||
evt.SetString( val );
|
||||
if (GetEventHandler()->ProcessEvent(evt)) return;
|
||||
}
|
||||
|
||||
event.Skip();
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user