Commit f765bb88 authored by Benjamin Otte's avatar Benjamin Otte

treeview: Don't draw a background for the bin window

The bin window's background would have to be drawn in the bin window's
size and inside the pixel cache draw function to not cause transparency
issues.

But because it's unnecessary as the view window draws the same
background, we just skip it.

https://bugzilla.gnome.org/show_bug.cgi?id=709027
parent a90ed567
......@@ -2222,7 +2222,6 @@ gtk_tree_view_ensure_background (GtkTreeView *tree_view)
context = gtk_widget_get_style_context (GTK_WIDGET (tree_view));
gtk_style_context_set_background (context, tree_view->priv->bin_window);
gtk_style_context_set_background (context, gtk_widget_get_window (GTK_WIDGET (tree_view)));
gtk_style_context_set_background (context, tree_view->priv->header_window);
}
......@@ -5465,10 +5464,6 @@ gtk_tree_view_draw (GtkWidget *widget,
GtkStyleContext *context;
context = gtk_widget_get_style_context (widget);
gtk_render_background (context, cr,
0, 0,
gtk_widget_get_allocated_width (widget),
gtk_widget_get_allocated_height (widget));
if (gtk_cairo_should_draw_window (cr, tree_view->priv->bin_window))
{
......@@ -5489,6 +5484,13 @@ gtk_tree_view_draw (GtkWidget *widget,
&view_rect, &canvas_rect,
draw_bin, widget);
}
else
{
gtk_render_background (context, cr,
0, 0,
gtk_widget_get_allocated_width (widget),
gtk_widget_get_allocated_height (widget));
}
gtk_style_context_save (context);
gtk_style_context_remove_class (context, GTK_STYLE_CLASS_VIEW);
......
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