diff options
-rw-r--r-- | source/blender/editors/space_outliner/tree/tree_element_overrides.cc | 27 |
1 files changed, 19 insertions, 8 deletions
diff --git a/source/blender/editors/space_outliner/tree/tree_element_overrides.cc b/source/blender/editors/space_outliner/tree/tree_element_overrides.cc index 51ca2eff9ee..203ad18f85c 100644 --- a/source/blender/editors/space_outliner/tree/tree_element_overrides.cc +++ b/source/blender/editors/space_outliner/tree/tree_element_overrides.cc @@ -71,18 +71,29 @@ void TreeElementOverridesBase::expand(SpaceOutliner &space_outliner) const const bool is_rna_path_valid = BKE_lib_override_rna_property_find( &idpoin, override_prop, &override_rna_ptr, &override_rna_prop, &rnaprop_index); - if (is_rna_path_valid && !show_system_overrides && - ELEM(override_prop->rna_prop_type, PROP_POINTER, PROP_COLLECTION) && - RNA_struct_is_ID(RNA_property_pointer_type(&override_rna_ptr, override_rna_prop))) { + /* Check for conditions where the liboverride property should be considered as a system + * override, if needed. */ + if (is_rna_path_valid && !show_system_overrides) { bool do_continue = true; - for (auto *override_prop_op : - ListBaseWrapper<IDOverrideLibraryPropertyOperation>(override_prop->operations)) { - if ((override_prop_op->flag & IDOVERRIDE_LIBRARY_FLAG_IDPOINTER_MATCH_REFERENCE) == 0) { - do_continue = false; - break; + + /* Matching ID pointers are considered as system overrides. */ + if (ELEM(override_prop->rna_prop_type, PROP_POINTER, PROP_COLLECTION) && + RNA_struct_is_ID(RNA_property_pointer_type(&override_rna_ptr, override_rna_prop))) { + for (auto *override_prop_op : + ListBaseWrapper<IDOverrideLibraryPropertyOperation>(override_prop->operations)) { + if ((override_prop_op->flag & IDOVERRIDE_LIBRARY_FLAG_IDPOINTER_MATCH_REFERENCE) == 0) { + do_continue = false; + break; + } } } + /* Animated/driven properties are considered as system overrides. */ + if (!BKE_lib_override_library_property_is_animated( + &id, override_prop, override_rna_prop, rnaprop_index)) { + do_continue = false; + } + if (do_continue) { continue; } |