i18n stuff: adds translation_context to RNA structs (used for there ui name), and...
authorBastien Montagne <montagne29@wanadoo.fr>
Fri, 16 Mar 2012 15:39:25 +0000 (15:39 +0000)
committerBastien Montagne <montagne29@wanadoo.fr>
Fri, 16 Mar 2012 15:39:25 +0000 (15:39 +0000)
commit2caa507b7eaa7d55a0be7bda513f08ecfe4791f1
tree86e65a98805030b6191643571c2eea1962da9ea7
parent4e6669cee38ed81dc2e9be52f2900885295506f3
i18n stuff: adds translation_context to RNA structs (used for there ui name), and a first default "Operator" one for all operators' label.

The fact is, operators' label are nearly always verbs, while properties labels are nearly always nouns. So this should already solve many translations' problems regarding noun/verb confusion.

This commit also simplifies a bit i18n usage:
*Now IFACE_ and TIP_ macros (or there context versions, CTX_IFACE_/TIP_) are used nearly everywhere (with one exception, where code is a bit complex and needs to manually test whether ui/tip translations is allowed, so no need to redo it later through those macros).
*Also, those macros are now defined to NOP in case WITH_INTERNATIONAL is false, which avoid testing that define everywhere in code!
12 files changed:
source/blender/blenfont/BLF_translation.h
source/blender/blenfont/intern/blf_translation.c
source/blender/editors/interface/interface.c
source/blender/editors/interface/interface_layout.c
source/blender/makesrna/RNA_define.h
source/blender/makesrna/intern/makesrna.c
source/blender/makesrna/intern/rna_access.c
source/blender/makesrna/intern/rna_define.c
source/blender/makesrna/intern/rna_internal_types.h
source/blender/makesrna/intern/rna_rna.c
source/blender/windowmanager/WM_types.h
source/blender/windowmanager/intern/wm_operators.c