Object transparency setting should only show on MESH type

This commit is contained in:
Daniel Salazar
2010-12-05 10:38:45 +00:00
parent 0400745c0a
commit 57d1d4f78c
2 changed files with 3 additions and 2 deletions

View File

@@ -217,7 +217,8 @@ class OBJECT_PT_display(ObjectButtonsPanel, bpy.types.Panel):
col = split.column()
col.prop(ob, "show_texture_space", text="Texture Space")
col.prop(ob, "show_x_ray", text="X-Ray")
col.prop(ob, "show_transparent", text="Transparency")
if ob.type == 'MESH':
col.prop(ob, "show_transparent", text="Transparency")
class OBJECT_PT_duplication(ObjectButtonsPanel, bpy.types.Panel):

View File

@@ -2159,7 +2159,7 @@ static void rna_def_object(BlenderRNA *brna)
prop= RNA_def_property(srna, "show_transparent", PROP_BOOLEAN, PROP_NONE);
RNA_def_property_boolean_sdna(prop, NULL, "dtx", OB_DRAWTRANSP);
RNA_def_property_ui_text(prop, "Draw Transparent", "Enables transparent materials for the object (Mesh only)");
RNA_def_property_ui_text(prop, "Draw Transparent", "Displays material transparency in the object");
RNA_def_property_update(prop, NC_OBJECT|ND_DRAW, NULL);
prop= RNA_def_property(srna, "show_x_ray", PROP_BOOLEAN, PROP_NONE);