Depsgraph: Simplify logic around special case for node tree update

This commit is contained in:
Sergey Sharybin
2017-12-15 15:10:11 +01:00
parent 1797923f32
commit 6609be0520

View File

@@ -369,14 +369,7 @@ void id_tag_update_editors_update(Main *bmain, Depsgraph *graph, ID *id)
void id_tag_update_ntree_special(Main *bmain, Depsgraph *graph, ID *id, int flag)
{
bNodeTree *ntree = NULL;
switch (GS(id->name)) {
case ID_MA:
ntree = ((Material *)id)->nodetree;
break;
default:
break;
}
bNodeTree *ntree = ntreeFromID(id);
if (ntree == NULL) {
return;
}