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:
authorBastien Montagne <b.mont29@gmail.com>2020-03-19 21:37:00 +0300
committerBastien Montagne <b.mont29@gmail.com>2020-03-19 21:39:23 +0300
commit12b621059a6f1337e8ae8fdd9533e7808225e71e (patch)
treed04a2fddc28152235191e2d93884f4d143410d85 /source/blender/editors/interface
parent0b7854323d41f3a1a55a40ddf76a90e2017a0784 (diff)
Cleanup/refactor: remove BKE_idcode, in favour of BKE_idtype.
Mpving utils from idcode to idtype proved to be somewhat painful for some reasons, but now all looks good. Had to add a fake/empty shell for the special snowflake too, `ID_LINK_PLACEHOLDER/INDEX_ID_NULL`...
Diffstat (limited to 'source/blender/editors/interface')
-rw-r--r--source/blender/editors/interface/interface_eyedropper_datablock.c4
-rw-r--r--source/blender/editors/interface/interface_templates.c6
2 files changed, 5 insertions, 5 deletions
diff --git a/source/blender/editors/interface/interface_eyedropper_datablock.c b/source/blender/editors/interface/interface_eyedropper_datablock.c
index 46164ebac69..93599b8727a 100644
--- a/source/blender/editors/interface/interface_eyedropper_datablock.c
+++ b/source/blender/editors/interface/interface_eyedropper_datablock.c
@@ -37,7 +37,7 @@
#include "BLT_translation.h"
#include "BKE_context.h"
-#include "BKE_idcode.h"
+#include "BKE_idtype.h"
#include "BKE_report.h"
#include "BKE_screen.h"
@@ -115,7 +115,7 @@ static int datadropper_init(bContext *C, wmOperator *op)
BLI_assert(ddr->idcode != 0);
/* Note we can translate here (instead of on draw time),
* because this struct has very short lifetime. */
- ddr->idcode_name = TIP_(BKE_idcode_to_name(ddr->idcode));
+ ddr->idcode_name = TIP_(BKE_idtype_idcode_to_name(ddr->idcode));
PointerRNA ptr = RNA_property_pointer_get(&ddr->ptr, ddr->prop);
ddr->init_id = ptr.owner_id;
diff --git a/source/blender/editors/interface/interface_templates.c b/source/blender/editors/interface/interface_templates.c
index a1a4c15bdf6..4489dcda989 100644
--- a/source/blender/editors/interface/interface_templates.c
+++ b/source/blender/editors/interface/interface_templates.c
@@ -59,7 +59,7 @@
#include "BKE_curveprofile.h"
#include "BKE_global.h"
#include "BKE_gpencil_modifier.h"
-#include "BKE_idcode.h"
+#include "BKE_idtype.h"
#include "BKE_idprop.h"
#include "BKE_layer.h"
#include "BKE_lib_id.h"
@@ -687,7 +687,7 @@ static const char *template_id_browse_tip(const StructRNA *type)
static const char *template_id_context(StructRNA *type)
{
if (type) {
- return BKE_idcode_to_translation_context(RNA_type_to_ID_code(type));
+ return BKE_idtype_idcode_to_translation_context(RNA_type_to_ID_code(type));
}
return BLT_I18NCONTEXT_DEFAULT;
}
@@ -2779,7 +2779,7 @@ void uiTemplatePreview(uiLayout *layout,
if (!preview_id || (preview_id[0] == '\0')) {
/* If no identifier given, generate one from ID type. */
- BLI_snprintf(_preview_id, UI_MAX_NAME_STR, "uiPreview_%s", BKE_idcode_to_name(GS(id->name)));
+ BLI_snprintf(_preview_id, UI_MAX_NAME_STR, "uiPreview_%s", BKE_idtype_idcode_to_name(GS(id->name)));
preview_id = _preview_id;
}