[gegl] graph: clear child nodes when setting node operation
- From: Ell <ell src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gegl] graph: clear child nodes when setting node operation
- Date: Tue, 2 Jun 2020 20:21:25 +0000 (UTC)
commit 3ff1e27c41c691e76fd831e3c6f9ef192f379cc7
Author: Ell <ell_se yahoo com>
Date: Tue Jun 2 22:48:39 2020 +0300
graph: clear child nodes when setting node operation
When setting a GeglNode's operation object, clear any child nodes,
to allow for replacing a node's op from a meta-op to a non-meta-op.
gegl/graph/gegl-node.c | 2 ++
1 file changed, 2 insertions(+)
---
diff --git a/gegl/graph/gegl-node.c b/gegl/graph/gegl-node.c
index 9054be160..de4fa23be 100644
--- a/gegl/graph/gegl-node.c
+++ b/gegl/graph/gegl-node.c
@@ -1426,6 +1426,8 @@ gegl_node_set_operation_object (GeglNode *self,
while (self->pads)
gegl_node_remove_pad (self, self->pads->data);
+ gegl_node_remove_children (self);
+
gegl_operation_attach (operation, self);
/* FIXME: This should handle all input pads instead of just these 3 */
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]