Fix #106943: driver on inactive view layer doesn't work #107031

Manually merged
Sybren A. Stüvel merged 3 commits from dr.sybren/blender:anim/106943-bg-view-layer-driver into main 2023-04-17 13:02:55 +02:00

3 Commits

Author SHA1 Message Date
Sybren A. Stüvel 7a30360289 Merge remote-tracking branch 'origin/main' into anim/106943-bg-view-layer-driver 2023-04-17 12:45:28 +02:00
Sybren A. Stüvel e5a5259371 Feedback from Sergey 2023-04-17 12:45:23 +02:00
Sybren A. Stüvel 94dde6866c Fix #106943: driver on inactive view layer doesn't work
Animation data (including drivers) on inactive view layers now work.
The removal of such view layers was too optimistic; they are now kept
around. The bases are still removed, mostly for safety sake and to keep
the changes to a minimum.

`scene_remove_unused_view_layers()` has been renamed to
`scene_minimize_unused_view_layers()` to reflect its new functionality.

For compatibility with assumptions in other areas of the code, the function
still ensures the input view layer is at index 0.
2023-04-17 11:35:18 +02:00