forked from AuroraMiddleware/gtk
treeview: Use new snapshot transforms
This commit is contained in:
parent
70100d888a
commit
5fc446dabf
@ -4925,13 +4925,12 @@ gtk_tree_view_snapshot (GtkWidget *widget,
|
||||
height - gtk_tree_view_get_effective_header_height (tree_view)
|
||||
));
|
||||
|
||||
gtk_snapshot_offset (snapshot,
|
||||
- (gint) gtk_adjustment_get_value (tree_view->priv->hadjustment),
|
||||
gtk_tree_view_get_effective_header_height (tree_view));
|
||||
gtk_snapshot_save (snapshot);
|
||||
gtk_snapshot_translate (snapshot, &GRAPHENE_POINT_INIT (
|
||||
- (gint) gtk_adjustment_get_value (tree_view->priv->hadjustment),
|
||||
gtk_tree_view_get_effective_header_height (tree_view)));
|
||||
gtk_tree_view_bin_snapshot (widget, snapshot);
|
||||
gtk_snapshot_offset (snapshot,
|
||||
(gint) gtk_adjustment_get_value (tree_view->priv->hadjustment),
|
||||
- gtk_tree_view_get_effective_header_height (tree_view));
|
||||
gtk_snapshot_restore (snapshot);
|
||||
|
||||
/* We can't just chain up to Container::draw as it will try to send the
|
||||
* event to the headers, so we handle propagating it to our children
|
||||
@ -9386,10 +9385,11 @@ gtk_tree_view_snapshot_arrow (GtkTreeView *tree_view,
|
||||
gtk_style_context_set_state (context, state);
|
||||
gtk_style_context_add_class (context, GTK_STYLE_CLASS_EXPANDER);
|
||||
|
||||
gtk_snapshot_offset (snapshot, area.x, area.y);
|
||||
gtk_snapshot_save (snapshot);
|
||||
gtk_snapshot_translate (snapshot, &GRAPHENE_POINT_INIT (area.x, area.y));
|
||||
gtk_css_style_snapshot_icon (gtk_style_context_lookup_style (context), snapshot,
|
||||
area.width, area.height, image_type);
|
||||
gtk_snapshot_offset (snapshot, -area.x, -area.y);
|
||||
gtk_snapshot_restore (snapshot);
|
||||
|
||||
gtk_style_context_restore (context);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user