[Bf-extensions-cvs] [1be0b321] master: Bone Selection Sets: USE_INSERTION on CollectionProperties

Demeter Dzadik noreply at git.blender.org
Mon Sep 21 17:59:41 CEST 2020


Commit: 1be0b3210d8a3a30e99a853b50703a7ca7e8ac1e
Author: Demeter Dzadik
Date:   Mon Sep 21 17:59:13 2020 +0200
Branches: master
https://developer.blender.org/rBA1be0b3210d8a3a30e99a853b50703a7ca7e8ac1e

Bone Selection Sets: USE_INSERTION on CollectionProperties

Use the new 'USE_INSERTION' override flag (rBdb314ee7a472) to allow creating new entries of Selection Sets on overridden rigs. I tested including saving and reloading, assigning and removing bones from a set:

- Can create and name new, local sets
- Can add and remove bones to and from those local sets
- Can add bones to original, non-local sets and remove those same bones
- Can NOT remove original sets
- Can NOT remove originally assigned bones bones from originally existing sets

To me this all seems to be working as intended, so might as well use it!

Reviewed By: mont29

Differential Revision: https://developer.blender.org/D8971

===================================================================

M	bone_selection_sets.py

===================================================================

diff --git a/bone_selection_sets.py b/bone_selection_sets.py
index 86338da2..563a4d9d 100644
--- a/bone_selection_sets.py
+++ b/bone_selection_sets.py
@@ -55,7 +55,10 @@ class SelectionEntry(PropertyGroup):
 
 class SelectionSet(PropertyGroup):
     name: StringProperty(name="Set Name", override={'LIBRARY_OVERRIDABLE'})
-    bone_ids: CollectionProperty(type=SelectionEntry, override={'LIBRARY_OVERRIDABLE'})
+    bone_ids: CollectionProperty(
+        type=SelectionEntry, 
+        override={'LIBRARY_OVERRIDABLE', 'USE_INSERTION'}
+    )  
     is_selected: BoolProperty(name="Is Selected", override={'LIBRARY_OVERRIDABLE'})
 
 
@@ -546,7 +549,7 @@ def register():
         type=SelectionSet,
         name="Selection Sets",
         description="List of groups of bones for easy selection",
-        override={'LIBRARY_OVERRIDABLE'}
+        override={'LIBRARY_OVERRIDABLE', 'USE_INSERTION'}
     )
     bpy.types.Object.active_selection_set = IntProperty(
         name="Active Selection Set",



More information about the Bf-extensions-cvs mailing list