diff options
author | Bastien Montagne <montagne29@wanadoo.fr> | 2016-01-14 18:00:15 +0300 |
---|---|---|
committer | Bastien Montagne <montagne29@wanadoo.fr> | 2016-01-14 19:00:16 +0300 |
commit | 46a7b46c303f0217069a26db16974b4f637604e5 (patch) | |
tree | cc69e6057ade6856cee0cf526342ed4739347bc8 /release | |
parent | 8f3bb8d578451df60d93b99ee0cba5353eb71b9c (diff) |
Fix broken i18n messages extracting script with new py code.
Some py devs are way too smart for our own good... :P
Diffstat (limited to 'release')
-rw-r--r-- | release/scripts/modules/bl_i18n_utils/bl_extract_messages.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/release/scripts/modules/bl_i18n_utils/bl_extract_messages.py b/release/scripts/modules/bl_i18n_utils/bl_extract_messages.py index baa9140aaef..ce09b156d85 100644 --- a/release/scripts/modules/bl_i18n_utils/bl_extract_messages.py +++ b/release/scripts/modules/bl_i18n_utils/bl_extract_messages.py @@ -493,7 +493,11 @@ def dump_py_messages_from_files(msgs, reports, files, settings): return i18n_contexts.default def _op_to_ctxt(node): - opname, _ = extract_strings(node) + # Some smart coders like things like: + # >>> row.operator("wm.addon_disable" if is_enabled else "wm.addon_enable", ...) + # We only take first arg into account here! + bag = extract_strings_split(node) + opname, _ = bag[0] if not opname: return i18n_contexts.default op = bpy.ops |