Fix #136372: Outliner hierarchy modification not auto keying

When recursively modifying a property via the Outliner while holding Shift,
only the property that was actually clicked got keyed.

With this fix, the clicked property gets keyed twice. Once with the added call,
and once in the ui button code. This shouldn't be a performance concern though.

Pull Request: https://projects.blender.org/blender/blender/pulls/140131

Co-authored-by: Christoph Lendenfeld <chris.lenden@gmail.com>
Pull Request: https://projects.blender.org/blender/blender/pulls/141671
This commit is contained in:
Philipp Oeser
2025-07-09 14:42:48 +02:00
parent 495f4ee1e5
commit 70591f3d47
@@ -43,8 +43,10 @@
#include "BKE_object.hh"
#include "BKE_particle.h"
#include "BKE_report.hh"
#include "BKE_scene.hh"
#include "ANIM_bone_collections.hh"
#include "ANIM_keyframing.hh"
#include "DEG_depsgraph.hh"
#include "DEG_depsgraph_build.hh"
@@ -296,6 +298,8 @@ static void outliner_object_set_flag_recursive_fn(bContext *C,
ptr = RNA_pointer_create(&scene->id, &RNA_ObjectBase, base_iter);
}
RNA_property_boolean_set(&ptr, base_or_object_prop, value);
blender::animrig::autokeyframe_property(
C, scene, &ptr, base_or_object_prop, -1, BKE_scene_frame_get(scene), true);
}
}