use TREE_VIEW_DRAG_WIDTH/2 when calculating the drag window position

2007-02-14  Kristian Rietveld  <kris@imendio.com>

	* gtk/gtktreeviewcolumn.c (_gtk_tree_view_column_realize_button):
	use TREE_VIEW_DRAG_WIDTH/2 when calculating the drag window
	position instead of a hardcoded value.  (Taken from maemo-gtk).


svn path=/trunk/; revision=17292
This commit is contained in:
Kristian Rietveld 2007-02-14 12:13:48 +00:00 committed by Kristian Rietveld
parent 44d79a77ac
commit 6ab7015dfe
2 changed files with 7 additions and 1 deletions

View File

@ -1,3 +1,9 @@
2007-02-14 Kristian Rietveld <kris@imendio.com>
* gtk/gtktreeviewcolumn.c (_gtk_tree_view_column_realize_button):
use TREE_VIEW_DRAG_WIDTH/2 when calculating the drag window
position instead of a hardcoded value. (Taken from maemo-gtk).
2007-02-14 Michael Natterer <mitch@imendio.com>
* gtk/gtkmenu.c (gtk_menu_motion_notify): don't forget to set the

View File

@ -1259,7 +1259,7 @@ _gtk_tree_view_column_realize_button (GtkTreeViewColumn *column)
attr.width = TREE_VIEW_DRAG_WIDTH;
attr.height = tree_view->priv->header_height;
attr.x = (column->button->allocation.x + (rtl ? 0 : column->button->allocation.width)) - 3;
attr.x = (column->button->allocation.x + (rtl ? 0 : column->button->allocation.width)) - TREE_VIEW_DRAG_WIDTH / 2;
column->window = gdk_window_new (tree_view->priv->header_window,
&attr, attributes_mask);
gdk_window_set_user_data (column->window, tree_view);