summaryrefslogtreecommitdiff
path: root/gsk/broadway
diff options
context:
space:
mode:
authorEmmanuele Bassi <ebassi@gnome.org>2020-04-07 23:33:54 +0100
committerEmmanuele Bassi <ebassi@gnome.org>2020-04-08 15:40:15 +0100
commitd701a892815453dd38e19062761443eeda54a7c5 (patch)
treecc1d91b6e88ad16d97f9204817ad7b650c66150b /gsk/broadway
parent5e095cd208db14625a549a766f60c752c066da7b (diff)
downloadgtk+-d701a892815453dd38e19062761443eeda54a7c5.tar.gz
Turn GskRenderNode into a derivable type
Language bindings—especially ones based on introspection—cannot deal with custom type hiearchies. Luckily for us, GType has a derivable type with low overhead: GTypeInstance. By turning GskRenderNode into a GTypeInstance, and creating derived types for each class of node, we can provide an introspectable API to our non-C API consumers, with no functional change to the C API itself.
Diffstat (limited to 'gsk/broadway')
-rw-r--r--gsk/broadway/gskbroadwayrenderer.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gsk/broadway/gskbroadwayrenderer.c b/gsk/broadway/gskbroadwayrenderer.c
index cb46f92bc2..89def7e807 100644
--- a/gsk/broadway/gskbroadwayrenderer.c
+++ b/gsk/broadway/gskbroadwayrenderer.c
@@ -595,7 +595,7 @@ gsk_broadway_renderer_add_node (GskRenderer *renderer,
n = gsk_linear_gradient_node_get_n_color_stops (node);
add_uint32 (nodes, n);
for (i = 0; i < n; i++)
- add_color_stop (nodes, &gsk_linear_gradient_node_peek_color_stops (node)[i]);
+ add_color_stop (nodes, &gsk_linear_gradient_node_peek_color_stops (node, NULL)[i]);
}
return;