[Bf-blender-cvs] [7033bd8] soc-2013-paint: Cleanup:

Antony Riakiotakis noreply at git.blender.org
Thu Apr 24 01:31:37 CEST 2014


Commit: 7033bd83d12ead3c2c5df0561e34663517edae00
Author: Antony Riakiotakis
Date:   Thu Apr 24 02:31:30 2014 +0300
https://developer.blender.org/rB7033bd83d12ead3c2c5df0561e34663517edae00

Cleanup:

* Header clanup
* Hide Add slot operator for node based materials. This could be a per
engine callback, but for now just disable.

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

M	release/scripts/startup/bl_ui/space_view3d_toolbar.py
M	source/blender/blenkernel/BKE_material.h

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

diff --git a/release/scripts/startup/bl_ui/space_view3d_toolbar.py b/release/scripts/startup/bl_ui/space_view3d_toolbar.py
index 5545692..cbb6e18 100644
--- a/release/scripts/startup/bl_ui/space_view3d_toolbar.py
+++ b/release/scripts/startup/bl_ui/space_view3d_toolbar.py
@@ -1112,11 +1112,12 @@ class VIEW3D_PT_slots_projectpaint(View3DPanel, Panel):
             col.template_list("TEXTURE_UL_texpaintslots", "", mat, "texture_paint_slots", mat, "paint_active_slot", rows=2)
             #col.label("Only slots with UV mapping and image textures are available")
             
-            col.operator_menu_enum("paint.add_texture_paint_slot", "type")
+            if not mat.use_nodes:
+                col.operator_menu_enum("paint.add_texture_paint_slot", "type")
         
-        row = col.row(align=True)
-        row.prop(settings, "new_slot_xresolution")
-        row.prop(settings, "new_slot_yresolution")
+                row = col.row(align=True)
+                row.prop(settings, "new_slot_xresolution")
+                row.prop(settings, "new_slot_yresolution")
 
 
 class VIEW3D_PT_tools_brush_overlay(Panel, View3DPaintPanel):
diff --git a/source/blender/blenkernel/BKE_material.h b/source/blender/blenkernel/BKE_material.h
index 365e04b..17ef89b 100644
--- a/source/blender/blenkernel/BKE_material.h
+++ b/source/blender/blenkernel/BKE_material.h
@@ -45,8 +45,6 @@ struct MTFace;
 struct Scene;
 struct Image;
 struct MTex;
-struct ImageUser;
-struct bNode;
 
 /* materials */




More information about the Bf-blender-cvs mailing list