Commit 1fb04c5f authored by Kristian Rietveld's avatar Kristian Rietveld

The full changelog for this commit is too long to paste here, so to avoid

annoying everybody I will write a short summary here.

Fixes for: #102890, #103198, #102618, #93629, #100172, #101235, #96650,
#102379.

Other than that also a ListStore fix and a TreeView scrolling fix.

Those interested in the hairy details can checkout gtk+/ChangeLog.
parent 3c7719b4
Tue Jan 14 23:29:00 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtkcellrendererpixbuf.c (gtk_cell_renderer_pixbuf_render):
make sure exposed pixbufs are clipped to the exposed area before
drawing, which is a slight speedup. (#102379, patch from Soeren
Sandmann).
Tue Jan 14 23:26:41 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (validate_visible_area): silly typo fix,
only free scroll_to_path when the complete tree has been validated.
This makes sure that we scrolled to the correct path.
Tue Jan 14 23:25:32 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (gtk_tree_view_style_set): update the
background of widget->window and bin->window. (Fixes #96650, reported
by Dave Camp).
Tue Jan 14 23:24:02 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (gtk_tree_view_clamp_node_visible): process
updates before scrolling, avoiding a "selection streak". (Fixes
#101235, patch from Soeren Sandmann).
Tue Jan 14 23:22:13 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (validate_visible_area): actually put values
in the requisition using gtk_widget_size_request. (Fixes #100172,
reported by Kjartan Maraas).
Tue Jan 14 23:19:45 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (gtk_tree_view_rows_reordered): cancel the
arrow animation timeout before we actually reorder the rbtree. If
we don't do this we can get stuck arrows,
(cancel_arrow_animation): new function. (Fixes #93629, part 2,
reported and testcase provided by Hans Petter Jansson).
Tue Jan 14 23:18:21 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeselection.c (gtk_tree_selection_real_modify_range):
anchor_path should be start_path, not end_path. (Fixes #102618,
patch from Carlos Garnacho Parro).
Tue Jan 14 23:16:15 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtkliststore.c (gtk_list_store_move): also update the tail,
only correct new_pos if we don't move to the head/tail.
Tue Jan 14 23:11:55 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreestore.c (gtk_tree_store_swap): take the path from
the parent_iter if depth >= 1, so we send the reordered signal to
the correct level, remove debugging printfs which I forgot the remove
earlier (2.2.0 shipped with this, oops). (Fixes #103198, Reported and
testcase provided by Matthew Tuck).
Tue Jan 14 20:58:44 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (invalite_last_column): split out actual column
invalidation into invalite_column(),
(gtk_tree_view_size_allocate_columns): invalidate column if the
new width is larger than the old width.
(fixes #102890, reported by Alex Duggan).
2003-01-14 Matthias Clasen <maclas@gmx.de>
* gtk/gtktextview.c (gtk_text_view_move_cursor_internal): Skip
......
Tue Jan 14 23:29:00 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtkcellrendererpixbuf.c (gtk_cell_renderer_pixbuf_render):
make sure exposed pixbufs are clipped to the exposed area before
drawing, which is a slight speedup. (#102379, patch from Soeren
Sandmann).
Tue Jan 14 23:26:41 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (validate_visible_area): silly typo fix,
only free scroll_to_path when the complete tree has been validated.
This makes sure that we scrolled to the correct path.
Tue Jan 14 23:25:32 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (gtk_tree_view_style_set): update the
background of widget->window and bin->window. (Fixes #96650, reported
by Dave Camp).
Tue Jan 14 23:24:02 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (gtk_tree_view_clamp_node_visible): process
updates before scrolling, avoiding a "selection streak". (Fixes
#101235, patch from Soeren Sandmann).
Tue Jan 14 23:22:13 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (validate_visible_area): actually put values
in the requisition using gtk_widget_size_request. (Fixes #100172,
reported by Kjartan Maraas).
Tue Jan 14 23:19:45 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (gtk_tree_view_rows_reordered): cancel the
arrow animation timeout before we actually reorder the rbtree. If
we don't do this we can get stuck arrows,
(cancel_arrow_animation): new function. (Fixes #93629, part 2,
reported and testcase provided by Hans Petter Jansson).
Tue Jan 14 23:18:21 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeselection.c (gtk_tree_selection_real_modify_range):
anchor_path should be start_path, not end_path. (Fixes #102618,
patch from Carlos Garnacho Parro).
Tue Jan 14 23:16:15 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtkliststore.c (gtk_list_store_move): also update the tail,
only correct new_pos if we don't move to the head/tail.
Tue Jan 14 23:11:55 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreestore.c (gtk_tree_store_swap): take the path from
the parent_iter if depth >= 1, so we send the reordered signal to
the correct level, remove debugging printfs which I forgot the remove
earlier (2.2.0 shipped with this, oops). (Fixes #103198, Reported and
testcase provided by Matthew Tuck).
Tue Jan 14 20:58:44 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (invalite_last_column): split out actual column
invalidation into invalite_column(),
(gtk_tree_view_size_allocate_columns): invalidate column if the
new width is larger than the old width.
(fixes #102890, reported by Alex Duggan).
2003-01-14 Matthias Clasen <maclas@gmx.de>
* gtk/gtktextview.c (gtk_text_view_move_cursor_internal): Skip
......
Tue Jan 14 23:29:00 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtkcellrendererpixbuf.c (gtk_cell_renderer_pixbuf_render):
make sure exposed pixbufs are clipped to the exposed area before
drawing, which is a slight speedup. (#102379, patch from Soeren
Sandmann).
Tue Jan 14 23:26:41 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (validate_visible_area): silly typo fix,
only free scroll_to_path when the complete tree has been validated.
This makes sure that we scrolled to the correct path.
Tue Jan 14 23:25:32 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (gtk_tree_view_style_set): update the
background of widget->window and bin->window. (Fixes #96650, reported
by Dave Camp).
Tue Jan 14 23:24:02 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (gtk_tree_view_clamp_node_visible): process
updates before scrolling, avoiding a "selection streak". (Fixes
#101235, patch from Soeren Sandmann).
Tue Jan 14 23:22:13 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (validate_visible_area): actually put values
in the requisition using gtk_widget_size_request. (Fixes #100172,
reported by Kjartan Maraas).
Tue Jan 14 23:19:45 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (gtk_tree_view_rows_reordered): cancel the
arrow animation timeout before we actually reorder the rbtree. If
we don't do this we can get stuck arrows,
(cancel_arrow_animation): new function. (Fixes #93629, part 2,
reported and testcase provided by Hans Petter Jansson).
Tue Jan 14 23:18:21 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeselection.c (gtk_tree_selection_real_modify_range):
anchor_path should be start_path, not end_path. (Fixes #102618,
patch from Carlos Garnacho Parro).
Tue Jan 14 23:16:15 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtkliststore.c (gtk_list_store_move): also update the tail,
only correct new_pos if we don't move to the head/tail.
Tue Jan 14 23:11:55 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreestore.c (gtk_tree_store_swap): take the path from
the parent_iter if depth >= 1, so we send the reordered signal to
the correct level, remove debugging printfs which I forgot the remove
earlier (2.2.0 shipped with this, oops). (Fixes #103198, Reported and
testcase provided by Matthew Tuck).
Tue Jan 14 20:58:44 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (invalite_last_column): split out actual column
invalidation into invalite_column(),
(gtk_tree_view_size_allocate_columns): invalidate column if the
new width is larger than the old width.
(fixes #102890, reported by Alex Duggan).
2003-01-14 Matthias Clasen <maclas@gmx.de>
* gtk/gtktextview.c (gtk_text_view_move_cursor_internal): Skip
......
Tue Jan 14 23:29:00 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtkcellrendererpixbuf.c (gtk_cell_renderer_pixbuf_render):
make sure exposed pixbufs are clipped to the exposed area before
drawing, which is a slight speedup. (#102379, patch from Soeren
Sandmann).
Tue Jan 14 23:26:41 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (validate_visible_area): silly typo fix,
only free scroll_to_path when the complete tree has been validated.
This makes sure that we scrolled to the correct path.
Tue Jan 14 23:25:32 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (gtk_tree_view_style_set): update the
background of widget->window and bin->window. (Fixes #96650, reported
by Dave Camp).
Tue Jan 14 23:24:02 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (gtk_tree_view_clamp_node_visible): process
updates before scrolling, avoiding a "selection streak". (Fixes
#101235, patch from Soeren Sandmann).
Tue Jan 14 23:22:13 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (validate_visible_area): actually put values
in the requisition using gtk_widget_size_request. (Fixes #100172,
reported by Kjartan Maraas).
Tue Jan 14 23:19:45 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (gtk_tree_view_rows_reordered): cancel the
arrow animation timeout before we actually reorder the rbtree. If
we don't do this we can get stuck arrows,
(cancel_arrow_animation): new function. (Fixes #93629, part 2,
reported and testcase provided by Hans Petter Jansson).
Tue Jan 14 23:18:21 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeselection.c (gtk_tree_selection_real_modify_range):
anchor_path should be start_path, not end_path. (Fixes #102618,
patch from Carlos Garnacho Parro).
Tue Jan 14 23:16:15 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtkliststore.c (gtk_list_store_move): also update the tail,
only correct new_pos if we don't move to the head/tail.
Tue Jan 14 23:11:55 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreestore.c (gtk_tree_store_swap): take the path from
the parent_iter if depth >= 1, so we send the reordered signal to
the correct level, remove debugging printfs which I forgot the remove
earlier (2.2.0 shipped with this, oops). (Fixes #103198, Reported and
testcase provided by Matthew Tuck).
Tue Jan 14 20:58:44 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (invalite_last_column): split out actual column
invalidation into invalite_column(),
(gtk_tree_view_size_allocate_columns): invalidate column if the
new width is larger than the old width.
(fixes #102890, reported by Alex Duggan).
2003-01-14 Matthias Clasen <maclas@gmx.de>
* gtk/gtktextview.c (gtk_text_view_move_cursor_internal): Skip
......
Tue Jan 14 23:29:00 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtkcellrendererpixbuf.c (gtk_cell_renderer_pixbuf_render):
make sure exposed pixbufs are clipped to the exposed area before
drawing, which is a slight speedup. (#102379, patch from Soeren
Sandmann).
Tue Jan 14 23:26:41 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (validate_visible_area): silly typo fix,
only free scroll_to_path when the complete tree has been validated.
This makes sure that we scrolled to the correct path.
Tue Jan 14 23:25:32 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (gtk_tree_view_style_set): update the
background of widget->window and bin->window. (Fixes #96650, reported
by Dave Camp).
Tue Jan 14 23:24:02 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (gtk_tree_view_clamp_node_visible): process
updates before scrolling, avoiding a "selection streak". (Fixes
#101235, patch from Soeren Sandmann).
Tue Jan 14 23:22:13 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (validate_visible_area): actually put values
in the requisition using gtk_widget_size_request. (Fixes #100172,
reported by Kjartan Maraas).
Tue Jan 14 23:19:45 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (gtk_tree_view_rows_reordered): cancel the
arrow animation timeout before we actually reorder the rbtree. If
we don't do this we can get stuck arrows,
(cancel_arrow_animation): new function. (Fixes #93629, part 2,
reported and testcase provided by Hans Petter Jansson).
Tue Jan 14 23:18:21 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeselection.c (gtk_tree_selection_real_modify_range):
anchor_path should be start_path, not end_path. (Fixes #102618,
patch from Carlos Garnacho Parro).
Tue Jan 14 23:16:15 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtkliststore.c (gtk_list_store_move): also update the tail,
only correct new_pos if we don't move to the head/tail.
Tue Jan 14 23:11:55 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreestore.c (gtk_tree_store_swap): take the path from
the parent_iter if depth >= 1, so we send the reordered signal to
the correct level, remove debugging printfs which I forgot the remove
earlier (2.2.0 shipped with this, oops). (Fixes #103198, Reported and
testcase provided by Matthew Tuck).
Tue Jan 14 20:58:44 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (invalite_last_column): split out actual column
invalidation into invalite_column(),
(gtk_tree_view_size_allocate_columns): invalidate column if the
new width is larger than the old width.
(fixes #102890, reported by Alex Duggan).
2003-01-14 Matthias Clasen <maclas@gmx.de>
* gtk/gtktextview.c (gtk_text_view_move_cursor_internal): Skip
......
......@@ -446,7 +446,8 @@ gtk_cell_renderer_pixbuf_render (GtkCellRenderer *cell,
pix_rect.width -= cell->xpad * 2;
pix_rect.height -= cell->ypad * 2;
if (gdk_rectangle_intersect (cell_area, &pix_rect, &draw_rect))
if (gdk_rectangle_intersect (cell_area, &pix_rect, &draw_rect) &&
gdk_rectangle_intersect (expose_area, &draw_rect, &draw_rect))
gdk_draw_pixbuf (window,
widget->style->black_gc,
pixbuf,
......
......@@ -1867,7 +1867,11 @@ gtk_list_store_move (GtkListStore *store,
if (!prev)
store->root = G_SLIST (iter->user_data)->next;
else
prev->next = G_SLIST (iter->user_data)->next;
{
prev->next = G_SLIST (iter->user_data)->next;
if (!prev->next)
store->tail = prev;
}
/* and reinsert it */
if (a)
......@@ -1901,12 +1905,12 @@ gtk_list_store_move (GtkListStore *store,
if (new_pos > old_pos)
{
if (before)
if (before && position)
new_pos--;
}
else
{
if (!before)
if (!before && position)
new_pos++;
}
......
......@@ -1165,7 +1165,7 @@ gtk_tree_selection_real_modify_range (GtkTreeSelection *selection,
start_path,
&end_tree,
&end_node);
anchor_path = end_path;
anchor_path = start_path;
break;
case 0:
_gtk_tree_view_find_node (selection->tree_view,
......
......@@ -2104,7 +2104,7 @@ gtk_tree_store_swap (GtkTreeStore *tree_store,
g_free (order);
}
/* WARNING: this function is *incredibly* fragily. Please smashtest after
/* WARNING: this function is *incredibly* fragile. Please smashtest after
* making changes here.
* -Kris
*/
......@@ -2394,14 +2394,14 @@ gtk_tree_store_move (GtkTreeStore *tree_store,
order[i] = i;
}
path = gtk_tree_path_new ();
if (depth)
path = gtk_tree_model_get_path (GTK_TREE_MODEL (tree_store), &parent_iter);
else
path = gtk_tree_path_new ();
gtk_tree_model_rows_reordered (GTK_TREE_MODEL (tree_store),
path, NULL, order);
for (i = 0; i < length; i++)
g_print ("%2d ", order[i]);
g_print ("\n");
gtk_tree_path_free (path);
if (position)
gtk_tree_path_free (pos_path);
......
......@@ -1548,6 +1548,54 @@ gtk_tree_view_size_request (GtkWidget *widget,
}
}
static void
invalidate_column (GtkTreeView *tree_view,
GtkTreeViewColumn *column)
{
gint column_offset = 0;
GList *list;
GtkWidget *widget = GTK_WIDGET (tree_view);
if (!GTK_WIDGET_REALIZED (widget))
return;
for (list = tree_view->priv->columns; list; list = list->next)
{
GtkTreeViewColumn *tmpcolumn = list->data;
if (tmpcolumn == column)
{
GdkRectangle invalid_rect;
invalid_rect.x = column_offset;
invalid_rect.y = 0;
invalid_rect.width = column->width;
invalid_rect.height = widget->allocation.height;
gdk_window_invalidate_rect (widget->window, &invalid_rect, TRUE);
break;
}
column_offset += tmpcolumn->width;
}
}
static void
invalidate_last_column (GtkTreeView *tree_view)
{
GList *last_column;
for (last_column = g_list_last (tree_view->priv->columns);
last_column; last_column = last_column->prev)
{
if (GTK_TREE_VIEW_COLUMN (last_column->data)->visible)
{
invalidate_column (tree_view, last_column->data);
return;
}
}
}
/* GtkWidget::size_allocate helper */
static void
gtk_tree_view_size_allocate_columns (GtkWidget *widget)
......@@ -1573,7 +1621,11 @@ gtk_tree_view_size_allocate_columns (GtkWidget *widget)
for (list = tree_view->priv->columns; list != last_column->next; list = list->next)
{
gint real_requested_width = 0;
gint old_width;
column = list->data;
old_width = column->width;
if (!column->visible)
continue;
......@@ -1619,15 +1671,23 @@ gtk_tree_view_size_allocate_columns (GtkWidget *widget)
allocation.x = width;
column->width = real_requested_width;
if (list == last_column &&
width + real_requested_width < widget->allocation.width)
{
column->width += (widget->allocation.width - column->width - width);
}
g_object_notify (G_OBJECT (column), "width");
allocation.width = column->width;
width += column->width;
if (column->width > old_width)
invalidate_column (tree_view, column);
gtk_widget_size_allocate (column->button, &allocation);
if (column->window)
gdk_window_move_resize (column->window,
allocation.x + allocation.width - TREE_VIEW_DRAG_WIDTH/2,
......@@ -1636,38 +1696,6 @@ gtk_tree_view_size_allocate_columns (GtkWidget *widget)
}
}
static void
invalidate_last_column (GtkTreeView *tree_view)
{
GList *list, *last_column;
gint last_column_x;
GtkWidget *widget = GTK_WIDGET (tree_view);
for (last_column = g_list_last (tree_view->priv->columns);
last_column && !(GTK_TREE_VIEW_COLUMN (last_column->data)->visible);
last_column = last_column->prev)
;
last_column_x = 0;
for (list = tree_view->priv->columns; list; list = list->next)
{
GtkTreeViewColumn *column = list->data;
if (list == last_column)
{
GdkRectangle invalid_rect;
invalid_rect.x = last_column_x;
invalid_rect.y = 0;
invalid_rect.width = column->width;
invalid_rect.height = widget->allocation.height;
gdk_window_invalidate_rect (widget->window, &invalid_rect, TRUE);
break;
}
last_column_x += column->width;
}
}
static void
gtk_tree_view_size_allocate (GtkWidget *widget,
......@@ -3907,6 +3935,7 @@ validate_visible_area (GtkTreeView *tree_view)
else
{
/* row not visible */
if (dy >= 0 && dy <= tree_view->priv->vadjustment->page_size)
{
/* row at the beginning -- fixed */
......@@ -3930,7 +3959,7 @@ validate_visible_area (GtkTreeView *tree_view)
* of the view
*/
area_above = 0;
area_above = total_height - height;
area_below = total_height - height;
}
}
}
......@@ -4097,6 +4126,7 @@ validate_visible_area (GtkTreeView *tree_view)
/* We temporarily guess a size, under the assumption that it will be the
* same when we get our next size_allocate. If we don't do this, we'll be
* in an inconsistent state if we call top_row_to_dy. */
gtk_widget_size_request (GTK_WIDGET (tree_view), &requisition);
tree_view->priv->hadjustment->upper = MAX (tree_view->priv->hadjustment->upper, (gfloat)requisition.width);
tree_view->priv->vadjustment->upper = MAX (tree_view->priv->vadjustment->upper, (gfloat)requisition.height);
gtk_adjustment_changed (tree_view->priv->hadjustment);
......@@ -4128,11 +4158,13 @@ validate_visible_area (GtkTreeView *tree_view)
{
dy = 0;
}
gtk_adjustment_set_value (tree_view->priv->vadjustment, dy);
need_redraw = TRUE;
}
if (tree_view->priv->scroll_to_path)
if (tree_view->priv->scroll_to_path &&
! GTK_RBNODE_FLAG_SET (tree_view->priv->tree->root, GTK_RBNODE_DESCENDANTS_INVALID))
{
gtk_tree_row_reference_free (tree_view->priv->scroll_to_path);
tree_view->priv->scroll_to_path = NULL;
......@@ -5720,6 +5752,12 @@ gtk_tree_view_style_set (GtkWidget *widget,
tree_view = GTK_TREE_VIEW (widget);
if (GTK_WIDGET_REALIZED (widget))
{
gdk_window_set_background (widget->window, &widget->style->base[widget->state]);
gdk_window_set_background (tree_view->priv->bin_window, &widget->style->base[widget->state]);
}
gtk_widget_style_get (widget,
"expander_size", &tree_view->priv->expander_size,
NULL);
......@@ -6252,6 +6290,13 @@ gtk_tree_view_row_deleted (GtkTreeModel *model,
g_signal_emit_by_name (tree_view->priv->selection, "changed");
}
static void
cancel_arrow_animation (GtkTreeView *tree_view)
{
if (tree_view->priv->expand_collapse_timeout)
while (expand_collapse_timeout (tree_view));
tree_view->priv->expand_collapse_timeout = 0;
}
static void
gtk_tree_view_rows_reordered (GtkTreeModel *model,
......@@ -6292,6 +6337,9 @@ gtk_tree_view_rows_reordered (GtkTreeModel *model,
/* we need to be unprelighted */
ensure_unprelighted (tree_view);
/* clear the timeout */
cancel_arrow_animation (tree_view);
_gtk_rbtree_reorder (tree, new_order, len);
......@@ -6567,8 +6615,6 @@ gtk_tree_view_clamp_node_visible (GtkTreeView *tree_view,
{
GtkTreePath *path = NULL;
/* We process updates because we want to clear old selected items when we scroll.
* if this is removed, we get a "selection streak" at the bottom. */
if (!GTK_WIDGET_REALIZED (tree_view))
return;
......@@ -6576,6 +6622,9 @@ gtk_tree_view_clamp_node_visible (GtkTreeView *tree_view,
if (path)
{
/* We process updates because we want to clear old selected items when we scroll.
* if this is removed, we get a "selection streak" at the bottom. */
gdk_window_process_updates (tree_view->priv->bin_window, TRUE);
gtk_tree_view_scroll_to_cell (tree_view, path, NULL, FALSE, 0.0, 0.0);
gtk_tree_path_free (path);
}
......@@ -7786,8 +7835,6 @@ gtk_tree_view_adjustment_changed (GtkAdjustment *adjustment,
/* update our dy and top_row */
tree_view->priv->dy = (int) tree_view->priv->vadjustment->value;
gtk_tree_view_dy_to_top_row (tree_view);
gdk_window_process_updates (tree_view->priv->bin_window, TRUE);
gdk_window_process_updates (tree_view->priv->header_window, TRUE);
}
}
......
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