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:
authorBastien Montagne <montagne29@wanadoo.fr>2014-11-30 17:05:03 +0300
committerBastien Montagne <montagne29@wanadoo.fr>2014-11-30 19:21:39 +0300
commit503dbb65c02b0cd0d80f0cbed6419285162b3262 (patch)
tree5569a5722620510f587e40f84593363eb2116d27 /source/blender/editors/space_node/space_node.c
parentb12dbdd93bff32a26a6b265d46b626491bf4926f (diff)
Fix T42760: Drag-to-add feature fails in a case.
We have to unset 'name' when we set 'filepath', and vice-versa.
Diffstat (limited to 'source/blender/editors/space_node/space_node.c')
-rw-r--r--source/blender/editors/space_node/space_node.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/source/blender/editors/space_node/space_node.c b/source/blender/editors/space_node/space_node.c
index 3c91b33f7b8..f4dc0c7e2f5 100644
--- a/source/blender/editors/space_node/space_node.c
+++ b/source/blender/editors/space_node/space_node.c
@@ -702,10 +702,12 @@ static void node_id_path_drop_copy(wmDrag *drag, wmDropBox *drop)
if (id) {
RNA_string_set(drop->ptr, "name", id->name + 2);
+ RNA_struct_property_unset(drop->ptr, "filepath");
}
- if (drag->path[0]) {
+ else if (drag->path[0]) {
RNA_string_set(drop->ptr, "filepath", drag->path);
- }
+ RNA_struct_property_unset(drop->ptr, "name");
+}
}
/* this region dropbox definition */