diff options
Diffstat (limited to 'source/blender/blentranslation')
-rw-r--r-- | source/blender/blentranslation/BLT_lang.h | 5 | ||||
-rw-r--r-- | source/blender/blentranslation/BLT_translation.h | 5 | ||||
-rw-r--r-- | source/blender/blentranslation/intern/blt_translation.c | 24 |
3 files changed, 14 insertions, 20 deletions
diff --git a/source/blender/blentranslation/BLT_lang.h b/source/blender/blentranslation/BLT_lang.h index 6ce9a0ba71c..dcd4de10416 100644 --- a/source/blender/blentranslation/BLT_lang.h +++ b/source/blender/blentranslation/BLT_lang.h @@ -21,8 +21,7 @@ * \ingroup blt */ -#ifndef __BLT_LANG_H__ -#define __BLT_LANG_H__ +#pragma once #ifdef __cplusplus extern "C" { @@ -60,5 +59,3 @@ struct EnumPropertyItem *BLT_lang_RNA_enum_properties(void); #ifdef __cplusplus }; #endif - -#endif /* __BLT_LANG_H__ */ diff --git a/source/blender/blentranslation/BLT_translation.h b/source/blender/blentranslation/BLT_translation.h index 817b99e8b91..b8979caa909 100644 --- a/source/blender/blentranslation/BLT_translation.h +++ b/source/blender/blentranslation/BLT_translation.h @@ -21,8 +21,7 @@ * \ingroup blt */ -#ifndef __BLT_TRANSLATION_H__ -#define __BLT_TRANSLATION_H__ +#pragma once #include "BLI_utildefines.h" /* for bool type */ @@ -221,5 +220,3 @@ typedef struct { #ifdef __cplusplus }; #endif - -#endif /* __BLT_TRANSLATION_H__ */ diff --git a/source/blender/blentranslation/intern/blt_translation.c b/source/blender/blentranslation/intern/blt_translation.c index 0ca068d4263..00118bc72e6 100644 --- a/source/blender/blentranslation/intern/blt_translation.c +++ b/source/blender/blentranslation/intern/blt_translation.c @@ -120,9 +120,9 @@ const char *BLT_translate_do(const char *msgctxt, const char *msgid) if (BLT_translate()) { return BLT_pgettext(msgctxt, msgid); } - else { - return msgid; - } + + return msgid; + #else (void)msgctxt; return msgid; @@ -135,9 +135,9 @@ const char *BLT_translate_do_iface(const char *msgctxt, const char *msgid) if (BLT_translate_iface()) { return BLT_pgettext(msgctxt, msgid); } - else { - return msgid; - } + + return msgid; + #else (void)msgctxt; return msgid; @@ -150,9 +150,9 @@ const char *BLT_translate_do_tooltip(const char *msgctxt, const char *msgid) if (BLT_translate_tooltips()) { return BLT_pgettext(msgctxt, msgid); } - else { - return msgid; - } + + return msgid; + #else (void)msgctxt; return msgid; @@ -165,9 +165,9 @@ const char *BLT_translate_do_new_dataname(const char *msgctxt, const char *msgid if (BLT_translate_new_dataname()) { return BLT_pgettext(msgctxt, msgid); } - else { - return msgid; - } + + return msgid; + #else (void)msgctxt; return msgid; |