From 25c173ffd12c0b46de4cc9919b8dbcc125f7e5ec Mon Sep 17 00:00:00 2001 From: Philipp Oeser Date: Tue, 19 Oct 2021 16:24:23 +0200 Subject: Tracking: support editing all selected tracks This patch adds a "selected_movieclip_tracks" context member and enables editing properties of multiple selected tracks via the usual Alt-click editing (as well as the "Copy To Selected" operator). Both use UI_context_copy_to_selected_list() to gather a list of other selected items [which are now taken via said new context member]. Strictly speaking, this could be done without the context member as well [just gathering other selected tracks in UI_context_copy_to_selected_list() without relying on a context member], but this might come in handy in other places (e.g. Addons). note: some could be desired for markers (e.g. editing pattern/search areas of all selected track markers, but since this is burried in a uiTemplate, this is a bit more work for another patch). Differential Revision: https://developer.blender.org/D12923 --- source/blender/editors/interface/interface_ops.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'source/blender/editors/interface/interface_ops.c') diff --git a/source/blender/editors/interface/interface_ops.c b/source/blender/editors/interface/interface_ops.c index 423950d4dbd..69a3cc959c9 100644 --- a/source/blender/editors/interface/interface_ops.c +++ b/source/blender/editors/interface/interface_ops.c @@ -849,6 +849,9 @@ bool UI_context_copy_to_selected_list(bContext *C, else if (RNA_struct_is_a(ptr->type, &RNA_NlaStrip)) { *r_lb = CTX_data_collection_get(C, "selected_nla_strips"); } + else if (RNA_struct_is_a(ptr->type, &RNA_MovieTrackingTrack)) { + *r_lb = CTX_data_collection_get(C, "selected_movieclip_tracks"); + } else if (RNA_struct_is_a(ptr->type, &RNA_Constraint) && (path_from_bone = RNA_path_resolve_from_type_to_property(ptr, prop, &RNA_PoseBone)) != NULL) { -- cgit v1.2.3