Fix various i18n ambiguous issues reported in T43295.
authorBastien Montagne <montagne29@wanadoo.fr>
Fri, 24 Mar 2017 19:01:32 +0000 (20:01 +0100)
committerBastien Montagne <montagne29@wanadoo.fr>
Fri, 24 Mar 2017 19:02:15 +0000 (20:02 +0100)
source/blender/editors/space_outliner/outliner_edit.c
source/blender/editors/space_sequencer/sequencer_add.c
source/blender/makesrna/intern/rna_action.c
source/blender/makesrna/intern/rna_animation.c
source/blender/makesrna/intern/rna_fcurve.c
source/blender/makesrna/intern/rna_nodetree.c

index bf220784371680b6f5301008eb85178305a75523..335eb95da0eb08db8d89ad26b69f79f498d07982 100644 (file)
@@ -519,7 +519,8 @@ void OUTLINER_OT_id_remap(wmOperatorType *ot)
 
        ot->flag = 0;
 
-       RNA_def_enum(ot->srna, "id_type", rna_enum_id_type_items, ID_OB, "ID Type", "");
+       prop = RNA_def_enum(ot->srna, "id_type", rna_enum_id_type_items, ID_OB, "ID Type", "");
+       RNA_def_property_translation_context(prop, BLT_I18NCONTEXT_ID_ID);
 
        prop = RNA_def_enum(ot->srna, "old_id", DummyRNA_NULL_items, 0, "Old ID", "Old ID to replace");
        RNA_def_property_enum_funcs_runtime(prop, NULL, NULL, outliner_id_itemf);
index ede6b7ce469be318fc354415736f263254861136..46f212e3679a52160bf16ef6d39c88bd8753e6d7 100644 (file)
@@ -38,6 +38,8 @@
 #include "BLI_math.h"
 #include "BLI_utildefines.h"
 
+#include "BLT_translation.h"
+
 #include "DNA_scene_types.h"
 #include "DNA_mask_types.h"
 
@@ -445,6 +447,7 @@ void SEQUENCER_OT_movieclip_strip_add(struct wmOperatorType *ot)
        sequencer_generic_props__internal(ot, SEQPROP_STARTFRAME);
        prop = RNA_def_enum(ot->srna, "clip", DummyRNA_NULL_items, 0, "Clip", "");
        RNA_def_enum_funcs(prop, RNA_movieclip_itemf);
+       RNA_def_property_translation_context(prop, BLT_I18NCONTEXT_ID_MOVIECLIP);
        RNA_def_property_flag(prop, PROP_ENUM_NO_TRANSLATE);
        ot->prop = prop;
 }
index 0c4c7ddac816d045d76ec4bd092a6b0fc7a2d263..d398ce95a52241038e58db71f763982d09dba83b 100644 (file)
@@ -34,6 +34,8 @@
 
 #include "BLI_utildefines.h"
 
+#include "BLT_translation.h"
+
 #include "BKE_action.h"
 
 #include "RNA_access.h"
@@ -731,6 +733,7 @@ static void rna_def_action(BlenderRNA *brna)
        RNA_def_property_ui_text(prop, "ID Root Type",
                                 "Type of ID block that action can be used on - "
                                 "DO NOT CHANGE UNLESS YOU KNOW WHAT YOU ARE DOING");
+       RNA_def_property_translation_context(prop, BLT_I18NCONTEXT_ID_ID);
        
        /* API calls */
        RNA_api_action(srna);
index 9adbf5f6b2e73e7fe2de554a8dd2e0b6d5caf67c..f271bccd326ca850caa47c4b20a0bbc0fc002af2 100644 (file)
@@ -32,6 +32,8 @@
 
 #include "BLI_utildefines.h"
 
+#include "BLT_translation.h"
+
 #include "MEM_guardedalloc.h"
 
 #include "RNA_access.h"
@@ -742,6 +744,7 @@ static void rna_def_keyingset_path(BlenderRNA *brna)
        RNA_def_property_enum_default(prop, ID_OB);
        RNA_def_property_enum_funcs(prop, NULL, "rna_ksPath_id_type_set", NULL);
        RNA_def_property_ui_text(prop, "ID Type", "Type of ID-block that can be used");
+       RNA_def_property_translation_context(prop, BLT_I18NCONTEXT_ID_ID);
        RNA_def_property_update(prop, NC_SCENE | ND_KEYINGSET | NA_EDITED, NULL); /* XXX: maybe a bit too noisy */
        
        /* Group */
index 4acdee490b89be63a313ba069eb82b598b2641dd..bccc47aa95dac0ac87d2e2de5bdbf7b4728f7e83 100644 (file)
@@ -35,6 +35,8 @@
 
 #include "BLI_math.h"
 
+#include "BLT_translation.h"
+
 #include "BKE_action.h"
 
 #include "RNA_access.h"
@@ -1448,6 +1450,7 @@ static void rna_def_drivertarget(BlenderRNA *brna)
        RNA_def_property_enum_funcs(prop, NULL, "rna_DriverTarget_id_type_set", NULL);
        RNA_def_property_editable_func(prop, "rna_DriverTarget_id_type_editable");
        RNA_def_property_ui_text(prop, "ID Type", "Type of ID-block that can be used");
+       RNA_def_property_translation_context(prop, BLT_I18NCONTEXT_ID_ID);
        RNA_def_property_update(prop, 0, "rna_DriverTarget_update_data");
        
        /* Target Properties - Property to Drive */
index 784004182ddcdf1282c60aabefe7c8a4a1c56b62..8d42d746e1c6d1d4b1d2f5b87a59bad8da4a3418 100644 (file)
@@ -3327,6 +3327,7 @@ static void def_frame(StructRNA *srna)
        RNA_def_property_update(prop, NC_NODE | NA_EDITED, "rna_Node_update");
 
        RNA_def_struct_sdna_from(srna, "NodeFrame", "storage");
+       RNA_def_struct_translation_context(srna, BLT_I18NCONTEXT_ID_NODETREE);
        
        prop = RNA_def_property(srna, "shrink", PROP_BOOLEAN, PROP_NONE);
        RNA_def_property_boolean_sdna(prop, NULL, "flag", NODE_FRAME_SHRINK);