Renamed GtkMyFixed to GtkPizza,
Made default button work more often than before. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@4256 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -779,6 +779,20 @@ void wxTextCtrl::OnChar( wxKeyEvent &key_event )
|
||||
if (GetEventHandler()->ProcessEvent(event)) return;
|
||||
}
|
||||
|
||||
if ((key_event.KeyCode() == WXK_RETURN) && !(m_windowStyle & wxTE_MULTILINE))
|
||||
{
|
||||
wxWindow *top_frame = m_parent;
|
||||
while (top_frame->GetParent() && !(top_frame->GetParent()->m_isFrame))
|
||||
top_frame = top_frame->GetParent();
|
||||
GtkWindow *window = GTK_WINDOW(top_frame->m_widget);
|
||||
|
||||
if (window->default_widget)
|
||||
{
|
||||
gtk_widget_activate (window->default_widget);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
key_event.Skip();
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user