[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [22830] branches/blender2.5/blender/ release/ui/space_view3d_toolbar.py: * Tweak texture paint view3d settings, make projection paint options dependent on the tool, rather than (weirdly) the tool's availability dependent on projection paint settings.
Matt Ebb
matt at mke3.net
Fri Aug 28 04:24:15 CEST 2009
Revision: 22830
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=22830
Author: broken
Date: 2009-08-28 04:24:14 +0200 (Fri, 28 Aug 2009)
Log Message:
-----------
* Tweak texture paint view3d settings, make projection paint options dependent on the tool, rather than (weirdly) the tool's availability dependent on projection paint settings.
Modified Paths:
--------------
branches/blender2.5/blender/release/ui/space_view3d_toolbar.py
Modified: branches/blender2.5/blender/release/ui/space_view3d_toolbar.py
===================================================================
--- branches/blender2.5/blender/release/ui/space_view3d_toolbar.py 2009-08-27 23:29:07 UTC (rev 22829)
+++ branches/blender2.5/blender/release/ui/space_view3d_toolbar.py 2009-08-28 02:24:14 UTC (rev 22830)
@@ -362,10 +362,8 @@
col = layout.column(align=True)
col.item_enumR(settings, "tool", 'DRAW')
col.item_enumR(settings, "tool", 'SOFTEN')
- if settings.use_projection:
- col.item_enumR(settings, "tool", 'CLONE')
- else:
- col.item_enumR(settings, "tool", 'SMEAR')
+ col.item_enumR(settings, "tool", 'CLONE')
+ col.item_enumR(settings, "tool", 'SMEAR')
col = layout.column()
col.itemR(brush, "color", text="")
@@ -540,12 +538,22 @@
# col.itemR(vpaint, "mul", text="")
-# ********** default tools for texturepaint ****************
+# ********** options for projection paint ****************
-class VIEW3D_PT_tools_texturepaint(View3DPanel):
+class VIEW3D_PT_tools_projectpaint(View3DPanel):
__context__ = "texturepaint"
- __label__ = "Options"
+ __label__ = "Project Paint"
+
+ def poll(self, context):
+ return context.tool_settings.image_paint.tool != 'SMEAR'
+
+ def draw_header(self, context):
+ layout = self.layout
+
+ ipaint = context.tool_settings.image_paint
+ layout.itemR(ipaint, "use_projection", text="")
+
def draw(self, context):
layout = self.layout
@@ -554,7 +562,6 @@
use_projection= ipaint.use_projection
col = layout.column()
- col.itemR(ipaint, "use_projection")
sub = col.column()
sub.active = use_projection
sub.itemR(ipaint, "use_occlude")
@@ -631,5 +638,5 @@
bpy.types.register(VIEW3D_PT_sculpt_options)
bpy.types.register(VIEW3D_PT_tools_vertexpaint)
bpy.types.register(VIEW3D_PT_tools_weightpaint)
-bpy.types.register(VIEW3D_PT_tools_texturepaint)
+bpy.types.register(VIEW3D_PT_tools_projectpaint)
bpy.types.register(VIEW3D_PT_tools_particlemode)
More information about the Bf-blender-cvs
mailing list