+Tue Oct 22 20:02:22 2002 Owen Taylor <otaylor@redhat.com>
+
+ * gtk/gtkcombo.c: When popping up the list without
+ any selected items, hack the focus on the list to
+ avoid triggering a bug in GtkList when clicking
+ on focused-but-not-selected items (#86700,
+ Zimler Attila, Matthias Clasen) and to keep
+ GtkWindow from selecting the first item.
+
+ * tests/testgtk.c (create_list): Make the initial
+ setting of the selection mode correspond to the option
+ menu.
+
Wed Oct 23 01:03:43 2002 Kristian Rietveld <kris@gtk.org>
Another feature to create truly ugly TreeViews!: style properties
+Tue Oct 22 20:02:22 2002 Owen Taylor <otaylor@redhat.com>
+
+ * gtk/gtkcombo.c: When popping up the list without
+ any selected items, hack the focus on the list to
+ avoid triggering a bug in GtkList when clicking
+ on focused-but-not-selected items (#86700,
+ Zimler Attila, Matthias Clasen) and to keep
+ GtkWindow from selecting the first item.
+
+ * tests/testgtk.c (create_list): Make the initial
+ setting of the selection mode correspond to the option
+ menu.
+
Wed Oct 23 01:03:43 2002 Kristian Rietveld <kris@gtk.org>
Another feature to create truly ugly TreeViews!: style properties
+Tue Oct 22 20:02:22 2002 Owen Taylor <otaylor@redhat.com>
+
+ * gtk/gtkcombo.c: When popping up the list without
+ any selected items, hack the focus on the list to
+ avoid triggering a bug in GtkList when clicking
+ on focused-but-not-selected items (#86700,
+ Zimler Attila, Matthias Clasen) and to keep
+ GtkWindow from selecting the first item.
+
+ * tests/testgtk.c (create_list): Make the initial
+ setting of the selection mode correspond to the option
+ menu.
+
Wed Oct 23 01:03:43 2002 Kristian Rietveld <kris@gtk.org>
Another feature to create truly ugly TreeViews!: style properties
+Tue Oct 22 20:02:22 2002 Owen Taylor <otaylor@redhat.com>
+
+ * gtk/gtkcombo.c: When popping up the list without
+ any selected items, hack the focus on the list to
+ avoid triggering a bug in GtkList when clicking
+ on focused-but-not-selected items (#86700,
+ Zimler Attila, Matthias Clasen) and to keep
+ GtkWindow from selecting the first item.
+
+ * tests/testgtk.c (create_list): Make the initial
+ setting of the selection mode correspond to the option
+ menu.
+
Wed Oct 23 01:03:43 2002 Kristian Rietveld <kris@gtk.org>
Another feature to create truly ugly TreeViews!: style properties
+Tue Oct 22 20:02:22 2002 Owen Taylor <otaylor@redhat.com>
+
+ * gtk/gtkcombo.c: When popping up the list without
+ any selected items, hack the focus on the list to
+ avoid triggering a bug in GtkList when clicking
+ on focused-but-not-selected items (#86700,
+ Zimler Attila, Matthias Clasen) and to keep
+ GtkWindow from selecting the first item.
+
+ * tests/testgtk.c (create_list): Make the initial
+ setting of the selection mode correspond to the option
+ menu.
+
Wed Oct 23 01:03:43 2002 Kristian Rietveld <kris@gtk.org>
Another feature to create truly ugly TreeViews!: style properties
+Tue Oct 22 20:02:22 2002 Owen Taylor <otaylor@redhat.com>
+
+ * gtk/gtkcombo.c: When popping up the list without
+ any selected items, hack the focus on the list to
+ avoid triggering a bug in GtkList when clicking
+ on focused-but-not-selected items (#86700,
+ Zimler Attila, Matthias Clasen) and to keep
+ GtkWindow from selecting the first item.
+
+ * tests/testgtk.c (create_list): Make the initial
+ setting of the selection mode correspond to the option
+ menu.
+
Wed Oct 23 01:03:43 2002 Kristian Rietveld <kris@gtk.org>
Another feature to create truly ugly TreeViews!: style properties
static void
gtk_combo_popup_list (GtkCombo * combo)
{
+ GtkList *list;
gint height, width, x, y;
gint old_width, old_height;
gtk_widget_hide (GTK_SCROLLED_WINDOW (combo->popup)->vscrollbar);
}
+ gtk_combo_update_list (GTK_ENTRY (combo->entry), combo);
+
+ /* We need to make sure some child of combo->popwin
+ * is focused to disable GtkWindow's automatic
+ * "focus-the-first-item" code. If there is no selected
+ * child, we focus the list itself with some hackery.
+ */
+ list = GTK_LIST (combo->list);
+
+ if (list->selection)
+ {
+ gtk_widget_grab_focus (list->selection->data);
+ }
+ else
+ {
+ GTK_WIDGET_SET_FLAGS (list, GTK_CAN_FOCUS);
+ gtk_widget_grab_focus (list);
+ GTK_WIDGET_UNSET_FLAGS (list, GTK_CAN_FOCUS);
+ }
+
gtk_window_move (GTK_WINDOW (combo->popwin), x, y);
gtk_widget_set_size_request (combo->popwin, width, height);
gtk_widget_show (combo->popwin);
GTK_POLICY_AUTOMATIC);
list = gtk_list_new ();
- gtk_list_set_selection_mode (GTK_LIST (list), GTK_SELECTION_EXTENDED);
+ gtk_list_set_selection_mode (GTK_LIST (list), GTK_SELECTION_SINGLE);
gtk_scrolled_window_add_with_viewport
(GTK_SCROLLED_WINDOW (scrolled_win), list);
gtk_container_set_focus_vadjustment