I want a callback for Collection selections in the Outliner. So far I already found a common solution for object selections:
handle = object()
subscribe_to = bpy.types.LayerObjects, 'active'
def notify_test():
print('Notify')
bpy.msgbus.subscribe_rna(
key=subscribe_to,
owner=handle,
args=(),
notify=notify_test,
)
bpy.msgbus.publish_rna(key=subscribe_to)
But what bpy.types do I subscribe to when I want a callback for collection selections? When I select a different collection in the outliner. There is:
bpy.types.LayerCollections
But there are no 'active' or 'selected' properties for this certain type.
Any help would be appreciated.