[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [43193] trunk/blender/source/blender/ editors/interface/interface_templates.c: Cycles/Material list:

Thomas Dinges blender at dingto.org
Fri Jan 6 02:07:21 CET 2012


Revision: 43193
          http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=43193
Author:   dingto
Date:     2012-01-06 01:07:13 +0000 (Fri, 06 Jan 2012)
Log Message:
-----------
Cycles/Material list:
* Don't display "Node <none>" message in the material list, when new shading nodes are used. 

Modified Paths:
--------------
    trunk/blender/source/blender/editors/interface/interface_templates.c

Modified: trunk/blender/source/blender/editors/interface/interface_templates.c
===================================================================
--- trunk/blender/source/blender/editors/interface/interface_templates.c	2012-01-06 00:45:07 UTC (rev 43192)
+++ trunk/blender/source/blender/editors/interface/interface_templates.c	2012-01-06 01:07:13 UTC (rev 43193)
@@ -55,6 +55,7 @@
 #include "BKE_texture.h"
 #include "BKE_report.h"
 #include "BKE_displist.h"
+#include "BKE_scene.h"
 
 #include "ED_screen.h"
 #include "ED_object.h"
@@ -2125,6 +2126,7 @@
 	else if(RNA_struct_is_a(itemptr->type, &RNA_MaterialSlot)) {
 		/* provision to draw active node name */
 		Material *ma, *manode;
+		Scene *scene= CTX_data_scene(C);
 		Object *ob= (Object*)ptr->id.data;
 		int index= (Material**)itemptr->data - ob->mat;
 		
@@ -2132,7 +2134,7 @@
 		uiItemL(sub, name, icon);
 		
 		ma= give_current_material(ob, index+1);
-		if(ma) {
+		if (ma && !scene_use_new_shading_nodes(scene)){
 			manode= give_node_material(ma);
 			if(manode) {
 				char str[MAX_ID_NAME + 12];



More information about the Bf-blender-cvs mailing list