Commit 57d36688 authored by Matthias Clasen's avatar Matthias Clasen Committed by Matthias Clasen

Pass a last item to gtk_combo_box_relayout_item. (#161050, John Finlay)

2004-12-12  Matthias Clasen  <mclasen@redhat.com>

	* gtk/gtkcombobox.c (gtk_combo_box_menu_row_changed): Pass a
	last item to gtk_combo_box_relayout_item.  (#161050, John Finlay)
parent 24295f3a
2004-12-12 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkcombobox.c (gtk_combo_box_menu_row_changed): Pass a
last item to gtk_combo_box_relayout_item. (#161050, John Finlay)
* tests/testfilechooserbutton.c (tests_button_clicked_cb): Rename
a local variable to avoid a conflict. (#161109, Robert Ögren)
......
2004-12-12 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkcombobox.c (gtk_combo_box_menu_row_changed): Pass a
last item to gtk_combo_box_relayout_item. (#161050, John Finlay)
* tests/testfilechooserbutton.c (tests_button_clicked_cb): Rename
a local variable to avoid a conflict. (#161109, Robert Ögren)
......
2004-12-12 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkcombobox.c (gtk_combo_box_menu_row_changed): Pass a
last item to gtk_combo_box_relayout_item. (#161050, John Finlay)
* tests/testfilechooserbutton.c (tests_button_clicked_cb): Rename
a local variable to avoid a conflict. (#161109, Robert Ögren)
......
2004-12-12 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkcombobox.c (gtk_combo_box_menu_row_changed): Pass a
last item to gtk_combo_box_relayout_item. (#161050, John Finlay)
* tests/testfilechooserbutton.c (tests_button_clicked_cb): Rename
a local variable to avoid a conflict. (#161109, Robert Ögren)
......
......@@ -3056,7 +3056,29 @@ gtk_combo_box_menu_row_changed (GtkTreeModel *model,
if (combo_box->priv->wrap_width
&& item->parent == combo_box->priv->popup_widget)
gtk_combo_box_relayout_item (combo_box, item, iter, NULL);
{
GtkWidget *pitem = NULL;
GtkTreePath *prev;
prev = gtk_tree_path_copy (path);
if (gtk_tree_path_prev (prev))
pitem = find_menu_by_path (combo_box->priv->popup_widget, prev, FALSE);
gtk_tree_path_free (prev);
/* unattach item so gtk_combo_box_relayout_item() won't spuriously
move it */
gtk_container_child_set (GTK_CONTAINER (combo_box->priv->popup_widget),
item,
"left_attach", -1,
"right_attach", -1,
"top_attach", -1,
"bottom_attach", -1,
NULL);
gtk_combo_box_relayout_item (combo_box, item, iter, pitem);
}
width = gtk_combo_box_calc_requested_width (combo_box, path);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment