Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--source/blender/blenkernel/BKE_idtype.h2
-rw-r--r--source/blender/blenkernel/intern/idtype.c14
2 files changed, 8 insertions, 8 deletions
diff --git a/source/blender/blenkernel/BKE_idtype.h b/source/blender/blenkernel/BKE_idtype.h
index 93bcfe5323d..05545216217 100644
--- a/source/blender/blenkernel/BKE_idtype.h
+++ b/source/blender/blenkernel/BKE_idtype.h
@@ -183,7 +183,7 @@ const char *BKE_idtype_idcode_to_translation_context(const short idcode);
bool BKE_idtype_idcode_is_linkable(const short idcode);
bool BKE_idtype_idcode_is_valid(const short idcode);
-short BKE_idtype_idcode_from_name(const char *name);
+short BKE_idtype_idcode_from_name(const char *idtype_name);
uint64_t BKE_idtype_idcode_to_idfilter(const short idcode);
short BKE_idtype_idcode_from_idfilter(const uint64_t idfilter);
diff --git a/source/blender/blenkernel/intern/idtype.c b/source/blender/blenkernel/intern/idtype.c
index b7fc167cf33..5a6e8f532c9 100644
--- a/source/blender/blenkernel/intern/idtype.c
+++ b/source/blender/blenkernel/intern/idtype.c
@@ -124,10 +124,10 @@ const IDTypeInfo *BKE_idtype_get_info_from_id(const ID *id)
return BKE_idtype_get_info_from_idcode(GS(id->name));
}
-static const IDTypeInfo *idtype_get_info_from_name(const char *str)
+static const IDTypeInfo *idtype_get_info_from_name(const char *idtype_name)
{
for (int i = ARRAY_SIZE(id_types); i--;) {
- if (id_types[i] != NULL && STREQ(str, id_types[i]->name)) {
+ if (id_types[i] != NULL && STREQ(idtype_name, id_types[i]->name)) {
return id_types[i];
}
}
@@ -179,14 +179,14 @@ const char *BKE_idtype_idcode_to_translation_context(const short idcode)
}
/**
- * Convert a name into an idcode (ie. ID_SCE)
+ * Convert an IDType name into an idcode (ie. ID_SCE)
*
- * \param name: The name to convert.
- * \return The code for the name, or 0 if invalid.
+ * \param idtype_name: The IDType's 'user visible name' to convert.
+ * \return The idcode for the name, or 0 if invalid.
*/
-short BKE_idtype_idcode_from_name(const char *name)
+short BKE_idtype_idcode_from_name(const char *idtype_name)
{
- const IDTypeInfo *id_type = idtype_get_info_from_name(name);
+ const IDTypeInfo *id_type = idtype_get_info_from_name(idtype_name);
BLI_assert(id_type);
return id_type != NULL ? id_type->id_code : 0;
}