diff options
Diffstat (limited to 'source/blender/editors')
-rw-r--r-- | source/blender/editors/curve/editcurve.c | 28 | ||||
-rw-r--r-- | source/blender/editors/mesh/editmesh_add.c | 20 | ||||
-rw-r--r-- | source/blender/editors/object/object_add.c | 18 |
3 files changed, 34 insertions, 32 deletions
diff --git a/source/blender/editors/curve/editcurve.c b/source/blender/editors/curve/editcurve.c index 5c8a755b391..8bd1830a289 100644 --- a/source/blender/editors/curve/editcurve.c +++ b/source/blender/editors/curve/editcurve.c @@ -6150,20 +6150,20 @@ static const char *get_curve_defname(int type) if ((type & CU_TYPE) == CU_BEZIER) { switch (stype) { - case CU_PRIM_CURVE: return "BezierCurve"; - case CU_PRIM_CIRCLE: return "BezierCircle"; - case CU_PRIM_PATH: return "CurvePath"; + case CU_PRIM_CURVE: return DATA_("BezierCurve"); + case CU_PRIM_CIRCLE: return DATA_("BezierCircle"); + case CU_PRIM_PATH: return DATA_("CurvePath"); default: - return "Curve"; + return DATA_("Curve"); } } else { switch (stype) { - case CU_PRIM_CURVE: return "NurbsCurve"; - case CU_PRIM_CIRCLE: return "NurbsCircle"; - case CU_PRIM_PATH: return "NurbsPath"; + case CU_PRIM_CURVE: return DATA_("NurbsCurve"); + case CU_PRIM_CIRCLE: return DATA_("NurbsCircle"); + case CU_PRIM_PATH: return DATA_("NurbsPath"); default: - return "Curve"; + return DATA_("Curve"); } } } @@ -6173,13 +6173,13 @@ static const char *get_surf_defname(int type) int stype = type & CU_PRIMITIVE; switch (stype) { - case CU_PRIM_CURVE: return "SurfCurve"; - case CU_PRIM_CIRCLE: return "SurfCircle"; - case CU_PRIM_PATCH: return "SurfPatch"; - case CU_PRIM_SPHERE: return "SurfSphere"; - case CU_PRIM_DONUT: return "SurfTorus"; + case CU_PRIM_CURVE: return DATA_("SurfCurve"); + case CU_PRIM_CIRCLE: return DATA_("SurfCircle"); + case CU_PRIM_PATCH: return DATA_("SurfPatch"); + case CU_PRIM_SPHERE: return DATA_("SurfSphere"); + case CU_PRIM_DONUT: return DATA_("SurfTorus"); default: - return "Surface"; + return DATA_("Surface"); } } diff --git a/source/blender/editors/mesh/editmesh_add.c b/source/blender/editors/mesh/editmesh_add.c index bcff5adb345..29a7b599983 100644 --- a/source/blender/editors/mesh/editmesh_add.c +++ b/source/blender/editors/mesh/editmesh_add.c @@ -34,6 +34,8 @@ #include "BLI_math.h" +#include "BLF_translation.h" + #include "BKE_context.h" #include "BKE_library.h" #include "BKE_tessmesh.h" @@ -106,7 +108,7 @@ static int add_primitive_plane_exec(bContext *C, wmOperator *op) unsigned int layer; ED_object_add_generic_get_opts(C, op, loc, rot, &enter_editmode, &layer, NULL); - obedit = make_prim_init(C, "Plane", &dia, mat, &state, loc, rot, layer); + obedit = make_prim_init(C, DATA_("Plane"), &dia, mat, &state, loc, rot, layer); em = BMEdit_FromObject(obedit); if (!EDBM_op_call_and_selectf(em, op, "verts.out", @@ -147,7 +149,7 @@ static int add_primitive_cube_exec(bContext *C, wmOperator *op) unsigned int layer; ED_object_add_generic_get_opts(C, op, loc, rot, &enter_editmode, &layer, NULL); - obedit = make_prim_init(C, "Cube", &dia, mat, &state, loc, rot, layer); + obedit = make_prim_init(C, DATA_("Cube"), &dia, mat, &state, loc, rot, layer); em = BMEdit_FromObject(obedit); if (!EDBM_op_call_and_selectf(em, op, "verts.out", "create_cube matrix=%m4 size=%f", mat, dia * 2.0f)) { @@ -196,7 +198,7 @@ static int add_primitive_circle_exec(bContext *C, wmOperator *op) cap_tri = (cap_end == 2); ED_object_add_generic_get_opts(C, op, loc, rot, &enter_editmode, &layer, NULL); - obedit = make_prim_init(C, "Circle", &dia, mat, &state, loc, rot, layer); + obedit = make_prim_init(C, DATA_("Circle"), &dia, mat, &state, loc, rot, layer); em = BMEdit_FromObject(obedit); if (!EDBM_op_call_and_selectf(em, op, "verts.out", @@ -251,7 +253,7 @@ static int add_primitive_cylinder_exec(bContext *C, wmOperator *op) cap_tri = (cap_end == 2); ED_object_add_generic_get_opts(C, op, loc, rot, &enter_editmode, &layer, NULL); - obedit = make_prim_init(C, "Cylinder", &dia, mat, &state, loc, rot, layer); + obedit = make_prim_init(C, DATA_("Cylinder"), &dia, mat, &state, loc, rot, layer); em = BMEdit_FromObject(obedit); if (!EDBM_op_call_and_selectf( @@ -312,7 +314,7 @@ static int add_primitive_cone_exec(bContext *C, wmOperator *op) cap_tri = (cap_end == 2); ED_object_add_generic_get_opts(C, op, loc, rot, &enter_editmode, &layer, NULL); - obedit = make_prim_init(C, "Cone", &dia, mat, &state, loc, rot, layer); + obedit = make_prim_init(C, DATA_("Cone"), &dia, mat, &state, loc, rot, layer); em = BMEdit_FromObject(obedit); if (!EDBM_op_call_and_selectf( @@ -369,7 +371,7 @@ static int add_primitive_grid_exec(bContext *C, wmOperator *op) unsigned int layer; ED_object_add_generic_get_opts(C, op, loc, rot, &enter_editmode, &layer, NULL); - obedit = make_prim_init(C, "Grid", &dia, mat, &state, loc, rot, layer); + obedit = make_prim_init(C, DATA_("Grid"), &dia, mat, &state, loc, rot, layer); em = BMEdit_FromObject(obedit); if (!EDBM_op_call_and_selectf(em, op, "verts.out", @@ -425,7 +427,7 @@ static int add_primitive_monkey_exec(bContext *C, wmOperator *op) if (!view_aligned) rot[0] += (float)M_PI / 2.0f; - obedit = make_prim_init(C, "Suzanne", &dia, mat, &state, loc, rot, layer); + obedit = make_prim_init(C, DATA_("Suzanne"), &dia, mat, &state, loc, rot, layer); mat[0][0] *= dia; mat[1][1] *= dia; mat[2][2] *= dia; @@ -468,7 +470,7 @@ static int add_primitive_uvsphere_exec(bContext *C, wmOperator *op) unsigned int layer; ED_object_add_generic_get_opts(C, op, loc, rot, &enter_editmode, &layer, NULL); - obedit = make_prim_init(C, "Sphere", &dia, mat, &state, loc, rot, layer); + obedit = make_prim_init(C, DATA_("Sphere"), &dia, mat, &state, loc, rot, layer); em = BMEdit_FromObject(obedit); if (!EDBM_op_call_and_selectf(em, op, "verts.out", @@ -520,7 +522,7 @@ static int add_primitive_icosphere_exec(bContext *C, wmOperator *op) unsigned int layer; ED_object_add_generic_get_opts(C, op, loc, rot, &enter_editmode, &layer, NULL); - obedit = make_prim_init(C, "Icosphere", &dia, mat, &state, loc, rot, layer); + obedit = make_prim_init(C, DATA_("Icosphere"), &dia, mat, &state, loc, rot, layer); em = BMEdit_FromObject(obedit); if (!EDBM_op_call_and_selectf( diff --git a/source/blender/editors/object/object_add.c b/source/blender/editors/object/object_add.c index 312cceac77d..1cc428b3deb 100644 --- a/source/blender/editors/object/object_add.c +++ b/source/blender/editors/object/object_add.c @@ -452,7 +452,7 @@ static int effector_add_exec(bContext *C, wmOperator *op) if (!ob) return OPERATOR_CANCELLED; - rename_id(&ob->id, "CurveGuide"); + rename_id(&ob->id, DATA_("CurveGuide")); ((Curve *)ob->data)->flag |= CU_PATH | CU_3D; ED_object_enter_editmode(C, 0); ED_object_new_primitive_matrix(C, ob, loc, rot, mat, FALSE); @@ -465,7 +465,7 @@ static int effector_add_exec(bContext *C, wmOperator *op) if (!ob) return OPERATOR_CANCELLED; - rename_id(&ob->id, "Field"); + rename_id(&ob->id, DATA_("Field")); if (ELEM(type, PFIELD_WIND, PFIELD_VORTEX)) ob->empty_drawtype = OB_SINGLE_ARROW; } @@ -822,13 +822,13 @@ void OBJECT_OT_drop_named_image(wmOperatorType *ot) static const char *get_lamp_defname(int type) { switch (type) { - case LA_LOCAL: return "Point"; - case LA_SUN: return "Sun"; - case LA_SPOT: return "Spot"; - case LA_HEMI: return "Hemi"; - case LA_AREA: return "Area"; + case LA_LOCAL: return DATA_("Point"); + case LA_SUN: return DATA_("Sun"); + case LA_SPOT: return DATA_("Spot"); + case LA_HEMI: return DATA_("Hemi"); + case LA_AREA: return DATA_("Area"); default: - return "Lamp"; + return DATA_("Lamp"); } } @@ -980,7 +980,7 @@ static int object_speaker_add_exec(bContext *C, wmOperator *op) BKE_nlatrack_add_strip(nlt, strip); /* auto-name the strip, and give the track an interesting name */ - strcpy(nlt->name, "SoundTrack"); + strcpy(nlt->name, DATA_("SoundTrack")); BKE_nlastrip_validate_name(adt, strip); WM_event_add_notifier(C, NC_ANIMATION | ND_NLA | NA_EDITED, NULL); |