[Bf-blender-cvs] [a814c7091b9] master: Fix T99847: Dragging image from Image Editor to Node Editor broken
Julian Eisel
noreply at git.blender.org
Wed Jul 20 14:54:41 CEST 2022
Commit: a814c7091b9a22067517b24b1f9c2de366717cbd
Author: Julian Eisel
Date: Wed Jul 20 14:49:14 2022 +0200
Branches: master
https://developer.blender.org/rBa814c7091b9a22067517b24b1f9c2de366717cbd
Fix T99847: Dragging image from Image Editor to Node Editor broken
Oversight in b0da080c2cb9. The `session_uuid` operator property wouldn't
be checked by the invoke callback, and if neither the `filepath` nor the
`name` property were set, the File Browser would open.
===================================================================
M source/blender/editors/space_node/node_add.cc
===================================================================
diff --git a/source/blender/editors/space_node/node_add.cc b/source/blender/editors/space_node/node_add.cc
index 04bf5ef469e..a89b5444a4d 100644
--- a/source/blender/editors/space_node/node_add.cc
+++ b/source/blender/editors/space_node/node_add.cc
@@ -690,8 +690,8 @@ static int node_add_file_invoke(bContext *C, wmOperator *op, const wmEvent *even
snode->runtime->cursor[0] /= UI_DPI_FAC;
snode->runtime->cursor[1] /= UI_DPI_FAC;
- if (RNA_struct_property_is_set(op->ptr, "filepath") ||
- RNA_struct_property_is_set(op->ptr, "name")) {
+ if (WM_operator_properties_id_lookup_is_set(op->ptr) ||
+ RNA_struct_property_is_set(op->ptr, "filepath")) {
return node_add_file_exec(C, op);
}
return WM_operator_filesel(C, op, event);
More information about the Bf-blender-cvs
mailing list