[gtk/wip/baedert/for-master: 5/6] textlayout: Use gtk_snapshot_{push,	pop}_collect()
- From: Timm Bäder <baedert src gnome org>
- To: commits-list gnome org
- Cc: 
- Subject: [gtk/wip/baedert/for-master: 5/6] textlayout: Use gtk_snapshot_{push,	pop}_collect()
- Date: Fri, 31 Jan 2020 17:04:18 +0000 (UTC)
commit ed8d584cea2d84ced020997802114153284f866e
Author: Timm Bäder <mail baedert org>
Date:   Fri Jan 31 17:43:31 2020 +0100
    textlayout: Use gtk_snapshot_{push,pop}_collect()
 gtk/gtktextlayout.c | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)
---
diff --git a/gtk/gtktextlayout.c b/gtk/gtktextlayout.c
index 5a2b419730..a5b2d8fe08 100644
--- a/gtk/gtktextlayout.c
+++ b/gtk/gtktextlayout.c
@@ -4160,15 +4160,13 @@ gtk_text_layout_snapshot (GtkTextLayout      *layout,
 
           if (line_display->node == NULL)
             {
-              GtkSnapshot *sub = gtk_snapshot_new_with_parent (snapshot);
+              gtk_snapshot_push_collect (snapshot);
 
-              crenderer->snapshot = sub;
               render_para (crenderer, 0, line_display,
                            selection_start_index, selection_end_index,
                            cursor_alpha);
-              crenderer->snapshot = snapshot;
 
-              line_display->node = gtk_snapshot_free_to_node (sub);
+              line_display->node = gtk_snapshot_pop_collect (snapshot);
             }
 
           if (line_display->node != NULL)
[
Date Prev][
Date Next]   [
Thread Prev][
Thread Next]   
[
Thread Index]
[
Date Index]
[
Author Index]