]> git.saurik.com Git - wxWidgets.git/blobdiff - src/gtk/combobox.cpp
revert updating GTK size hints when window decorations change, it messes up min size...
[wxWidgets.git] / src / gtk / combobox.cpp
index d64524fbe0038167911bc1d95f77d97922f8eeed..439408958bd89fb940c0b6692cfec3bf37dc9a86 100644 (file)
@@ -393,6 +393,17 @@ void wxComboBox::OnChar( wxKeyEvent &event )
                     return;
                 }
             }
+
+            // On enter key press, we must give a signal to default control, 
+            // Otherwise, nothing happens when pressing Enter from inside a 
+            // combo box in a dialog. 
+            wxWindow *top_frame = wxGetTopLevelParent(this);
+            if( top_frame && GTK_IS_WINDOW(top_frame->m_widget) )
+            {
+                GtkWindow *window = GTK_WINDOW(top_frame->m_widget);
+                if ( window->default_widget )
+                    gtk_widget_activate( window->default_widget );
+            }
             break;
     }