Make drag reordering work properly for columns other than the first.

2005-09-09  Matthias Clasen  <mclasen@redhat.com>

	* gtk/gtktreeviewcolumn.c (gtk_tree_view_column_button_event):
	Make drag reordering work properly for columns other than the
	first.  (#315054, Dan Winship)
This commit is contained in:
Matthias Clasen
2005-09-09 21:43:01 +00:00
committed by Matthias Clasen
parent 22ee9e6c58
commit 6648dc472c
3 changed files with 9 additions and 5 deletions

View File

@@ -1,5 +1,9 @@
2005-09-09 Matthias Clasen <mclasen@redhat.com>
* gtk/gtktreeviewcolumn.c (gtk_tree_view_column_button_event):
Make drag reordering work properly for columns other than the
first. (#315054, Dan Winship)
* gtk/gtkfontbutton.c (gtk_font_button_update_font_info): Handle
invalid fontnames better. (#315187, Ed Catmur)

View File

@@ -1,5 +1,9 @@
2005-09-09 Matthias Clasen <mclasen@redhat.com>
* gtk/gtktreeviewcolumn.c (gtk_tree_view_column_button_event):
Make drag reordering work properly for columns other than the
first. (#315054, Dan Winship)
* gtk/gtkfontbutton.c (gtk_font_button_update_font_info): Handle
invalid fontnames better. (#315187, Ed Catmur)

View File

@@ -1053,7 +1053,7 @@ gtk_tree_view_column_button_event (GtkWidget *widget,
((GdkEventButton *)event)->button == 1)
{
column->maybe_reordered = TRUE;
gdk_window_get_pointer (widget->window,
gdk_window_get_pointer (GTK_BUTTON (widget)->event_window,
&column->drag_x,
&column->drag_y,
NULL);
@@ -1073,10 +1073,6 @@ gtk_tree_view_column_button_event (GtkWidget *widget,
(gint) ((GdkEventMotion *)event)->y)))
{
column->maybe_reordered = FALSE;
/* this is to change our drag_x to be relative to
* tree_view->priv->bin_window, instead of our window.
*/
column->drag_x -= column->button->allocation.x;
_gtk_tree_view_column_start_drag (GTK_TREE_VIEW (column->tree_view), column);
return TRUE;
}