Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJulian Eisel <julian@blender.org>2021-02-15 21:35:24 +0300
committerJulian Eisel <julian@blender.org>2021-02-15 21:39:46 +0300
commit604e61d81d6326e665de6ec81dca2619e2cd5dbc (patch)
tree5d6bd388a0c6ed77e58dd3887bd77b0af7b93397 /source/blender/editors/space_node/node_ops.c
parent45852532d55be4fc7ab4f0f3be00983a78c69dea (diff)
UI/Nodes: Adding node groups via drag & drop (e.g. from Asset Browser)
Adds `NODE_OT_add_group` operator to add a node group from a given name, and uses that to register a node editor drop-box. When dropping a node-group asset, the ID will be appended. This is what we do for other ID assets too. Should the node group insertion fail (e.g. the group is not compatible with the current tree, as checked by the poll), the appended data-block is removed. Differential Revision: https://developer.blender.org/D10405 Reviewed by: Jacques Lucke
Diffstat (limited to 'source/blender/editors/space_node/node_ops.c')
-rw-r--r--source/blender/editors/space_node/node_ops.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/source/blender/editors/space_node/node_ops.c b/source/blender/editors/space_node/node_ops.c
index d55fd06ddea..7671547363b 100644
--- a/source/blender/editors/space_node/node_ops.c
+++ b/source/blender/editors/space_node/node_ops.c
@@ -88,6 +88,7 @@ void node_operatortypes(void)
WM_operatortype_append(NODE_OT_backimage_fit);
WM_operatortype_append(NODE_OT_backimage_sample);
+ WM_operatortype_append(NODE_OT_add_group);
WM_operatortype_append(NODE_OT_add_file);
WM_operatortype_append(NODE_OT_add_mask);