Revision: 39976
          
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=39976
Author:   lukastoenne
Date:     2011-09-06 16:48:28 +0000 (Tue, 06 Sep 2011)
Log Message:
-----------
Fix for node group add menu, groups from old files wouldn't show up there.

Reason was that node trees are now associated to specific node types 
(NODE_GROUP in particular) by the ntree->nodetype id.

Modified Paths:
--------------
    trunk/blender/source/blender/blenloader/intern/readfile.c

Modified: trunk/blender/source/blender/blenloader/intern/readfile.c
===================================================================
--- trunk/blender/source/blender/blenloader/intern/readfile.c   2011-09-06 
16:32:51 UTC (rev 39975)
+++ trunk/blender/source/blender/blenloader/intern/readfile.c   2011-09-06 
16:48:28 UTC (rev 39976)
@@ -11991,6 +11991,17 @@
                                ntree->update |= NTREE_UPDATE;
                        }
                }
+
+               {
+                       /* Initialize group tree nodetypes.
+                        * These are used to distinguish tree types and
+                        * associate them with specific node types for polling.
+                        */
+                       bNodeTree *ntree;
+                       /* all node trees in main->nodetree are considered 
groups */
+                       for (ntree=main->nodetree.first; ntree; 
ntree=ntree->id.next)
+                               ntree->nodetype = NODE_GROUP;
+               }
        }
 
        /* put compatibility code here until next subversion bump */

_______________________________________________
Bf-blender-cvs mailing list
[email protected]
http://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to