diff options
Diffstat (limited to 'gtk')
-rw-r--r-- | gtk/gtkcombobox.c | 2 | ||||
-rw-r--r-- | gtk/gtkcomboboxentry.c | 18 |
2 files changed, 18 insertions, 2 deletions
diff --git a/gtk/gtkcombobox.c b/gtk/gtkcombobox.c index f52a441689..c666578e8e 100644 --- a/gtk/gtkcombobox.c +++ b/gtk/gtkcombobox.c @@ -2834,7 +2834,7 @@ gtk_combo_box_mnemonic_activate (GtkWidget *widget, { GtkComboBox *combo_box = GTK_COMBO_BOX (widget); - gtk_widget_grab_focus (combo_box->priv->tree_view); + gtk_widget_grab_focus (combo_box->priv->button); return TRUE; } diff --git a/gtk/gtkcomboboxentry.c b/gtk/gtkcomboboxentry.c index c5f1965e1e..a21e73f823 100644 --- a/gtk/gtkcomboboxentry.c +++ b/gtk/gtkcomboboxentry.c @@ -51,7 +51,8 @@ static void gtk_combo_box_entry_active_changed (GtkComboBox *combo_b gpointer user_data); static void gtk_combo_box_entry_contents_changed (GtkEntry *entry, gpointer user_data); - +static gboolean gtk_combo_box_entry_mnemonic_activate (GtkWidget *entry, + gboolean group_cycling); enum { @@ -93,11 +94,15 @@ static void gtk_combo_box_entry_class_init (GtkComboBoxEntryClass *klass) { GObjectClass *object_class; + GtkWidgetClass *widget_class; object_class = (GObjectClass *)klass; object_class->set_property = gtk_combo_box_entry_set_property; object_class->get_property = gtk_combo_box_entry_get_property; + widget_class = (GtkWidgetClass *)klass; + widget_class->mnemonic_activate = gtk_combo_box_entry_mnemonic_activate; + g_object_class_install_property (object_class, PROP_TEXT_COLUMN, g_param_spec_int ("text_column", @@ -321,3 +326,14 @@ gtk_combo_box_entry_get_text_column (GtkComboBoxEntry *entry_box) return entry_box->priv->text_column; } + +static gboolean +gtk_combo_box_entry_mnemonic_activate (GtkWidget *widget, + gboolean group_cycling) +{ + GtkComboBoxEntry *entry_box = GTK_COMBO_BOX_ENTRY (widget); + + gtk_widget_grab_focus (entry_box->priv->entry); + + return TRUE; +} |