[Bf-blender-cvs] [59aa170c0f1] greasepencil-object: Fix T51449: empty node editor continuously redrawing and using CPU.

Brecht Van Lommel noreply at git.blender.org
Mon May 15 10:42:48 CEST 2017


Commit: 59aa170c0f18406cc4745a208d74dd7d6f2cd3f9
Author: Brecht Van Lommel
Date:   Thu May 11 20:28:39 2017 +0200
Branches: greasepencil-object
https://developer.blender.org/rB59aa170c0f18406cc4745a208d74dd7d6f2cd3f9

Fix T51449: empty node editor continuously redrawing and using CPU.

===================================================================

M	source/blender/editors/space_node/node_edit.c

===================================================================

diff --git a/source/blender/editors/space_node/node_edit.c b/source/blender/editors/space_node/node_edit.c
index 107a84cf530..1339dbec120 100644
--- a/source/blender/editors/space_node/node_edit.c
+++ b/source/blender/editors/space_node/node_edit.c
@@ -588,7 +588,8 @@ void snode_set_context(const bContext *C)
 		}
 	}
 	
-	if (snode->nodetree != ntree || snode->id != id || snode->from != from || snode->treepath.last == NULL) {
+	if (snode->nodetree != ntree || snode->id != id || snode->from != from ||
+	    (snode->treepath.last == NULL && ntree)) {
 		ED_node_tree_start(snode, ntree, id, from);
 	}
 }




More information about the Bf-blender-cvs mailing list