Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--source/blender/editors/animation/anim_filter.c29
-rw-r--r--source/blender/editors/interface/interface_templates.c17
-rw-r--r--source/blender/makesdna/DNA_action_types.h1
-rw-r--r--source/blender/makesdna/DNA_anim_types.h1
-rw-r--r--source/blender/makesrna/intern/rna_action.c6
5 files changed, 30 insertions, 24 deletions
diff --git a/source/blender/editors/animation/anim_filter.c b/source/blender/editors/animation/anim_filter.c
index 9f6f76dc3c1..2bd4ab34fa5 100644
--- a/source/blender/editors/animation/anim_filter.c
+++ b/source/blender/editors/animation/anim_filter.c
@@ -1667,7 +1667,7 @@ static int animdata_filter_dopesheet_ob (bAnimContext *ac, ListBase *anim_data,
return items;
/* Action, Drivers, or NLA */
- if (ob->adt) {
+ if (ob->adt && !(ads->filterflag & ADS_FILTER_NOOBJ)) {
adt= ob->adt;
ANIMDATA_FILTER_CASES(ob,
{ /* AnimData blocks - do nothing... */ },
@@ -2168,19 +2168,22 @@ static int animdata_filter_dopesheet (bAnimContext *ac, ListBase *anim_data, bDo
/* check filters for datatypes */
/* object */
actOk= 0;
+ if (!(ads->filterflag & ADS_FILTER_NOOBJ)) {
+ ANIMDATA_FILTER_CASES(ob,
+ {
+ /* for the special AnimData blocks only case, we only need to add
+ * the block if it is valid... then other cases just get skipped (hence ok=0)
+ */
+ ANIMDATA_ADD_ANIMDATA(ob);
+ actOk=0;
+ },
+ actOk= 1;,
+ actOk= 1;,
+ actOk= 1;)
+ }
+
keyOk= 0;
- ANIMDATA_FILTER_CASES(ob,
- {
- /* for the special AnimData blocks only case, we only need to add
- * the block if it is valid... then other cases just get skipped (hence ok=0)
- */
- ANIMDATA_ADD_ANIMDATA(ob);
- actOk=0;
- },
- actOk= 1;,
- actOk= 1;,
- actOk= 1;)
- if (key) {
+ if ((key) && !(ads->filterflag & ADS_FILTER_NOSHAPEKEYS)) {
/* shapekeys */
ANIMDATA_FILTER_CASES(key,
{
diff --git a/source/blender/editors/interface/interface_templates.c b/source/blender/editors/interface/interface_templates.c
index c327d4515d3..6de11e9486e 100644
--- a/source/blender/editors/interface/interface_templates.c
+++ b/source/blender/editors/interface/interface_templates.c
@@ -77,26 +77,23 @@ void uiTemplateDopeSheetFilter(uiLayout *layout, bContext *C, PointerRNA *ptr)
ScrArea *sa= CTX_wm_area(C);
uiLayout *row= layout;
short nlaActive= ((sa) && (sa->spacetype==SPACE_NLA));
-
+
/* more 'generic' filtering options */
- if (nlaActive)
- row= uiLayoutRow(layout, 1);
-
+ row= uiLayoutRow(layout, 1);
+
uiItemR(row, "", 0, ptr, "only_selected", 0);
-
+ uiItemR(row, "", 0, ptr, "display_transforms", 0); // xxx: include in another position instead?
+
if (nlaActive)
uiItemR(row, "", 0, ptr, "include_missing_nla", 0);
-
- if (nlaActive)
- row= layout;
-
+
/* datatype based - only available datatypes are shown */
row= uiLayoutRow(layout, 1);
uiItemR(row, "", 0, ptr, "display_scene", 0);
uiItemR(row, "", 0, ptr, "display_world", 0);
uiItemR(row, "", 0, ptr, "display_node", 0);
-
+
if (mainptr && mainptr->mesh.first)
uiItemR(row, "", 0, ptr, "display_mesh", 0);
if (mainptr && mainptr->key.first)
diff --git a/source/blender/makesdna/DNA_action_types.h b/source/blender/makesdna/DNA_action_types.h
index f76a7f6140e..91d3a7901c4 100644
--- a/source/blender/makesdna/DNA_action_types.h
+++ b/source/blender/makesdna/DNA_action_types.h
@@ -526,6 +526,7 @@ typedef enum eDopeSheet_FilterFlag {
/* datatype-based filtering */
ADS_FILTER_NOSHAPEKEYS = (1<<6),
ADS_FILTER_NOMESH = (1<<7),
+ ADS_FILTER_NOOBJ = (1<<8), /* for animdata on object level, if we only want to concentrate on materials/etc. */
// NOTE: there are a few more spaces for datablock filtering here...
ADS_FILTER_NOCAM = (1<<10),
ADS_FILTER_NOMAT = (1<<11),
diff --git a/source/blender/makesdna/DNA_anim_types.h b/source/blender/makesdna/DNA_anim_types.h
index 828c54fa6c7..d2755f71fa3 100644
--- a/source/blender/makesdna/DNA_anim_types.h
+++ b/source/blender/makesdna/DNA_anim_types.h
@@ -445,7 +445,6 @@ typedef enum eFCurve_Flags {
FCURVE_INT_VALUES = (1<<11),
/* curve can only have certain discrete-number values (no interpolation at all, for enums/booleans) */
FCURVE_DISCRETE_VALUES = (1<<12),
-
} eFCurve_Flags;
/* extrapolation modes (only simple value 'extending') */
diff --git a/source/blender/makesrna/intern/rna_action.c b/source/blender/makesrna/intern/rna_action.c
index 3033999ecde..e642d9546e8 100644
--- a/source/blender/makesrna/intern/rna_action.c
+++ b/source/blender/makesrna/intern/rna_action.c
@@ -112,6 +112,12 @@ static void rna_def_dopesheet(BlenderRNA *brna)
/* General DataType Filtering Settings */
+ prop= RNA_def_property(srna, "display_transforms", PROP_BOOLEAN, PROP_NONE);
+ RNA_def_property_boolean_negative_sdna(prop, NULL, "filterflag", ADS_FILTER_NOOBJ);
+ RNA_def_property_ui_text(prop, "Display Transforms", "Include visualization of Object-level Animation data (mostly Transforms)");
+ RNA_def_property_ui_icon(prop, ICON_MANIPUL, 0); // XXX?
+ RNA_def_property_update(prop, NC_ANIMATION|ND_ANIMCHAN_EDIT, NULL);
+
prop= RNA_def_property(srna, "display_shapekeys", PROP_BOOLEAN, PROP_NONE);
RNA_def_property_boolean_negative_sdna(prop, NULL, "filterflag", ADS_FILTER_NOSHAPEKEYS);
RNA_def_property_ui_text(prop, "Display Shapekeys", "Include visualization of ShapeKey related Animation data");