From 99ec29193aee1c4d1469091492746c6ec416384f Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Fri, 16 Oct 2009 18:03:38 +0000 Subject: [PATCH] bisplay shapekeys as sliders in the dope sheet editor --- release/scripts/ui/buttons_data_mesh.py | 2 +- source/blender/editors/animation/anim_channels_defines.c | 2 +- source/blender/makesrna/intern/rna_key.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/release/scripts/ui/buttons_data_mesh.py b/release/scripts/ui/buttons_data_mesh.py index eeee1512978..35d0ecafdf1 100644 --- a/release/scripts/ui/buttons_data_mesh.py +++ b/release/scripts/ui/buttons_data_mesh.py @@ -146,7 +146,7 @@ class DATA_PT_shape_keys(DataButtonsPanel): row = layout.row() row.enabled = ob.shape_key_lock == False - row.itemR(kb, "value", slider=True) + row.itemR(kb, "value") row.itemO("object.shape_key_clear", icon='ICON_X', text="") split = layout.split() diff --git a/source/blender/editors/animation/anim_channels_defines.c b/source/blender/editors/animation/anim_channels_defines.c index 2cd41b0ffb7..54a08cf4702 100644 --- a/source/blender/editors/animation/anim_channels_defines.c +++ b/source/blender/editors/animation/anim_channels_defines.c @@ -2147,7 +2147,7 @@ void ANIM_channel_setting_set (bAnimContext *ac, bAnimListElem *ale, int setting // XXX hardcoded size of icons #define ICON_WIDTH 17 // XXX hardcoded width of sliders -#define SLIDER_WIDTH 70 +#define SLIDER_WIDTH 80 /* Draw the given channel */ // TODO: make this use UI controls for the buttons diff --git a/source/blender/makesrna/intern/rna_key.c b/source/blender/makesrna/intern/rna_key.c index e1551404438..230ed90c131 100644 --- a/source/blender/makesrna/intern/rna_key.c +++ b/source/blender/makesrna/intern/rna_key.c @@ -363,7 +363,7 @@ static void rna_def_keyblock(BlenderRNA *brna) RNA_def_property_update(prop, 0, "rna_Key_update_data"); /* for now, this is editable directly, as users can set this even if they're not animating them (to test results) */ - prop= RNA_def_property(srna, "value", PROP_FLOAT, PROP_NONE); + prop= RNA_def_property(srna, "value", PROP_FLOAT, PROP_FACTOR); RNA_def_property_float_sdna(prop, NULL, "curval"); RNA_def_property_float_funcs(prop, NULL, "rna_ShapeKey_value_set", "rna_ShapeKey_value_range"); RNA_def_property_ui_text(prop, "Value", "Value of shape key at the current frame.");