rename layout.red_alert to alert, may be themeable some day.

This commit is contained in:
2011-01-03 13:33:07 +00:00
parent 72e8a0c552
commit a41ec761fd
3 changed files with 8 additions and 8 deletions

View File

@@ -722,7 +722,7 @@ class OBJECT_PT_constraints(ConstraintButtonsPanel, bpy.types.Panel):
if ob.mode == 'POSE': if ob.mode == 'POSE':
box = layout.box() box = layout.box()
box.red_alert = True; box.alert = True;
box.label(icon='INFO', text="See Bone Constraints tab to Add Constraints to active bone") box.label(icon='INFO', text="See Bone Constraints tab to Add Constraints to active bone")
else: else:
layout.operator_menu_enum("object.constraint_add", "type") layout.operator_menu_enum("object.constraint_add", "type")

View File

@@ -546,7 +546,7 @@ class PARTICLE_PT_physics(ParticleButtonsPanel, bpy.types.Panel):
if part.physics_type == 'KEYED': if part.physics_type == 'KEYED':
col = row.column() col = row.column()
#doesn't work yet #doesn't work yet
#col.red_alert = key.valid #col.alert = key.valid
col.prop(key, "object", text="") col.prop(key, "object", text="")
col.prop(key, "system", text="System") col.prop(key, "system", text="System")
col = row.column() col = row.column()
@@ -556,7 +556,7 @@ class PARTICLE_PT_physics(ParticleButtonsPanel, bpy.types.Panel):
elif part.physics_type == 'BOIDS': elif part.physics_type == 'BOIDS':
sub = row.row() sub = row.row()
#doesn't work yet #doesn't work yet
#sub.red_alert = key.valid #sub.alert = key.valid
sub.prop(key, "object", text="") sub.prop(key, "object", text="")
sub.prop(key, "system", text="System") sub.prop(key, "system", text="System")
@@ -564,7 +564,7 @@ class PARTICLE_PT_physics(ParticleButtonsPanel, bpy.types.Panel):
elif part.physics_type == 'FLUID': elif part.physics_type == 'FLUID':
sub = row.row() sub = row.row()
#doesn't work yet #doesn't work yet
#sub.red_alert = key.valid #sub.alert = key.valid
sub.prop(key, "object", text="") sub.prop(key, "object", text="")
sub.prop(key, "system", text="System") sub.prop(key, "system", text="System")

View File

@@ -449,12 +449,12 @@ static void rna_UILayout_active_set(PointerRNA *ptr, int value)
uiLayoutSetActive(ptr->data, value); uiLayoutSetActive(ptr->data, value);
} }
static int rna_UILayout_red_alert_get(PointerRNA *ptr) static int rna_UILayout_alert_get(PointerRNA *ptr)
{ {
return uiLayoutGetRedAlert(ptr->data); return uiLayoutGetRedAlert(ptr->data);
} }
static void rna_UILayout_red_alert_set(PointerRNA *ptr, int value) static void rna_UILayout_alert_set(PointerRNA *ptr, int value)
{ {
uiLayoutSetRedAlert(ptr->data, value); uiLayoutSetRedAlert(ptr->data, value);
} }
@@ -562,8 +562,8 @@ static void rna_def_ui_layout(BlenderRNA *brna)
RNA_def_property_boolean_funcs(prop, "rna_UILayout_enabled_get", "rna_UILayout_enabled_set"); RNA_def_property_boolean_funcs(prop, "rna_UILayout_enabled_get", "rna_UILayout_enabled_set");
RNA_def_property_ui_text(prop, "Enabled", "When false, this (sub)layout is greyed out."); RNA_def_property_ui_text(prop, "Enabled", "When false, this (sub)layout is greyed out.");
prop= RNA_def_property(srna, "red_alert", PROP_BOOLEAN, PROP_NONE); prop= RNA_def_property(srna, "alert", PROP_BOOLEAN, PROP_NONE);
RNA_def_property_boolean_funcs(prop, "rna_UILayout_red_alert_get", "rna_UILayout_red_alert_set"); RNA_def_property_boolean_funcs(prop, "rna_UILayout_alert_get", "rna_UILayout_alert_set");
prop= RNA_def_property(srna, "alignment", PROP_ENUM, PROP_NONE); prop= RNA_def_property(srna, "alignment", PROP_ENUM, PROP_NONE);
RNA_def_property_enum_items(prop, alignment_items); RNA_def_property_enum_items(prop, alignment_items);