[Bf-blender-cvs] [3dd0cfb] tmp-id-users: Link to valid set values
Campbell Barton
noreply at git.blender.org
Wed Jan 6 19:39:42 CET 2016
Commit: 3dd0cfb4ed350b43ae7481c6bc131802c8797594
Author: Campbell Barton
Date: Thu Jan 7 05:30:57 2016 +1100
Branches: tmp-id-users
https://developer.blender.org/rB3dd0cfb4ed350b43ae7481c6bc131802c8797594
Link to valid set values
===================================================================
M source/blender/python/intern/bpy_rna_id_collection.c
===================================================================
diff --git a/source/blender/python/intern/bpy_rna_id_collection.c b/source/blender/python/intern/bpy_rna_id_collection.c
index 9375958..0970e67 100644
--- a/source/blender/python/intern/bpy_rna_id_collection.c
+++ b/source/blender/python/intern/bpy_rna_id_collection.c
@@ -133,7 +133,7 @@ static bool foreach_libblock_id_user_map_callback(void *user_data, ID **id_p, in
* \param type_convert_sign: Maps signed to unsuigned range,
* needed when we want to use the full range of a signed short/char.
*/
-static BLI_bitmap *pyrna_set_to_bitmap(
+static BLI_bitmap *pyrna_set_to_enum_bitmap(
EnumPropertyItem *items, PyObject *value,
int type_size, bool type_convert_sign,
int bitmap_size,
@@ -194,6 +194,8 @@ PyDoc_STRVAR(bpy_user_map_doc,
"\n"
" Returns a mapping of all ID datablocks in current ``bpy.data`` to a set of all datablocks using them.\n"
"\n"
+" For list of valid set members for key_types & value_types, see: :class:`bpy.types.KeyingSetPath.id_type`.\n"
+"\n"
" :arg subset: When passed, only these data-blocks and their users will be included as keys/values in the map.\n"
" :type subset: sequence\n"
" :arg key_types: Filter the keys mapped by ID types.\n"
@@ -233,7 +235,7 @@ static PyObject *bpy_user_map(PyObject *UNUSED(self), PyObject *args, PyObject *
}
if (key_types) {
- key_types_bitmap = pyrna_set_to_bitmap(
+ key_types_bitmap = pyrna_set_to_enum_bitmap(
rna_enum_id_type_items, key_types, sizeof(short), true, USHRT_MAX, "key types");
if (key_types_bitmap == NULL) {
goto error;
@@ -241,7 +243,7 @@ static PyObject *bpy_user_map(PyObject *UNUSED(self), PyObject *args, PyObject *
}
if (val_types) {
- val_types_bitmap = pyrna_set_to_bitmap(
+ val_types_bitmap = pyrna_set_to_enum_bitmap(
rna_enum_id_type_items, val_types, sizeof(short), true, USHRT_MAX, "value types");
if (val_types_bitmap == NULL) {
goto error;
More information about the Bf-blender-cvs
mailing list