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:
authorSergey Sharybin <sergey.vfx@gmail.com>2014-02-27 13:06:05 +0400
committerSergey Sharybin <sergey.vfx@gmail.com>2014-02-27 13:07:25 +0400
commitd971c5785e0806ef3a49185b4e76a8d10e1a5bd0 (patch)
treeaa7f706d2c207189cbaf28c50e52a8a1d150e2c5 /source/blender/makesrna/intern/rna_access.c
parent317f29d753ae601d9c4817769059c7fb2aadfbd1 (diff)
Fix root of the issue of bad_cast bug in localization
No need to call l10n stuff when it's disabled in the preferences. Reviewed by @mont29, thanks!
Diffstat (limited to 'source/blender/makesrna/intern/rna_access.c')
-rw-r--r--source/blender/makesrna/intern/rna_access.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/source/blender/makesrna/intern/rna_access.c b/source/blender/makesrna/intern/rna_access.c
index 4bb04b792ef..86ef2f1b74f 100644
--- a/source/blender/makesrna/intern/rna_access.c
+++ b/source/blender/makesrna/intern/rna_access.c
@@ -1444,7 +1444,11 @@ bool RNA_property_enum_name_gettexted(bContext *C, PointerRNA *ptr, PropertyRNA
result = RNA_property_enum_name(C, ptr, prop, value, name);
if (result) {
- *name = BLF_pgettext(prop->translation_context, *name);
+ if (!(prop->flag & PROP_ENUM_NO_TRANSLATE)) {
+ if (BLF_translate_iface()) {
+ *name = BLF_pgettext(prop->translation_context, *name);
+ }
+ }
}
return result;