[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [23944] trunk/blender/release/scripts/ui: Fix #19633: material & texture didn't use autocomplete for
Brecht Van Lommel
brecht at blender.org
Mon Oct 19 13:00:45 CEST 2009
Revision: 23944
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=23944
Author: blendix
Date: 2009-10-19 13:00:43 +0200 (Mon, 19 Oct 2009)
Log Message:
-----------
Fix #19633: material & texture didn't use autocomplete for
selecting uv layers yet.
Modified Paths:
--------------
trunk/blender/release/scripts/ui/buttons_material.py
trunk/blender/release/scripts/ui/buttons_texture.py
Modified: trunk/blender/release/scripts/ui/buttons_material.py
===================================================================
--- trunk/blender/release/scripts/ui/buttons_material.py 2009-10-19 10:49:46 UTC (rev 23943)
+++ trunk/blender/release/scripts/ui/buttons_material.py 2009-10-19 11:00:43 UTC (rev 23944)
@@ -150,7 +150,9 @@
col = split.column()
col.itemL(text="Shading:")
col.itemR(tan, "width_fade")
- col.itemR(tan, "uv_layer")
+ ob = context.object
+ if ob and ob.type == 'MESH': col.item_pointerR(tan, "uv_layer", ob.data, "uv_textures", text="")
+ else: col.itemR(tan, "uv_layer", text="")
col.itemS()
sub = col.column()
sub.active = (not mat.shadeless)
Modified: trunk/blender/release/scripts/ui/buttons_texture.py
===================================================================
--- trunk/blender/release/scripts/ui/buttons_texture.py 2009-10-19 10:49:46 UTC (rev 23943)
+++ trunk/blender/release/scripts/ui/buttons_texture.py 2009-10-19 11:00:43 UTC (rev 23944)
@@ -171,7 +171,9 @@
elif tex.texture_coordinates == 'UV':
split = layout.split(percentage=0.3)
split.itemL(text="Layer:")
- split.itemR(tex, "uv_layer", text="")
+ ob = context.object
+ if ob and ob.type == 'MESH': split.item_pointerR(tex, "uv_layer", ob.data, "uv_textures", text="")
+ else: split.itemR(tex, "uv_layer", text="")
elif tex.texture_coordinates == 'OBJECT':
split = layout.split(percentage=0.3)
split.itemL(text="Object:")
More information about the Bf-blender-cvs
mailing list