diff options
Diffstat (limited to 'source/blender/windowmanager/intern/wm_operators.c')
-rw-r--r-- | source/blender/windowmanager/intern/wm_operators.c | 54 |
1 files changed, 27 insertions, 27 deletions
diff --git a/source/blender/windowmanager/intern/wm_operators.c b/source/blender/windowmanager/intern/wm_operators.c index 921ef006de2..ff4aeef9339 100644 --- a/source/blender/windowmanager/intern/wm_operators.c +++ b/source/blender/windowmanager/intern/wm_operators.c @@ -152,10 +152,10 @@ void WM_operatortype_append(void (*opfunc)(wmOperatorType*)) if(ot->name==NULL) { fprintf(stderr, "ERROR: Operator %s has no name property!\n", ot->idname); - ot->name= _("Dummy Name"); + ot->name= UI_translate_do_iface(N_("Dummy Name")); } - RNA_def_struct_ui_text(ot->srna, ot->name, ot->description ? ot->description:_("(undocumented operator)")); // XXX All ops should have a description but for now allow them not to. + RNA_def_struct_ui_text(ot->srna, ot->name, ot->description ? ot->description:UI_translate_do_iface(N_("(undocumented operator)"))); // XXX All ops should have a description but for now allow them not to. RNA_def_struct_identifier(ot->srna, ot->idname); BLI_ghash_insert(global_ops_hash, (void *)ot->idname, ot); @@ -168,7 +168,7 @@ void WM_operatortype_append_ptr(void (*opfunc)(wmOperatorType*, void*), void *us ot= MEM_callocN(sizeof(wmOperatorType), "operatortype"); ot->srna= RNA_def_struct(&BLENDER_RNA, "", "OperatorProperties"); opfunc(ot, userdata); - RNA_def_struct_ui_text(ot->srna, ot->name, ot->description ? ot->description:_("(undocumented operator)")); + RNA_def_struct_ui_text(ot->srna, ot->name, ot->description ? ot->description:UI_translate_do_iface(N_("(undocumented operator)"))); RNA_def_struct_identifier(ot->srna, ot->idname); BLI_ghash_insert(global_ops_hash, (void *)ot->idname, ot); @@ -362,7 +362,7 @@ wmOperatorType *WM_operatortype_append_macro(const char *idname, const char *nam ot->poll= NULL; if(!ot->description) - ot->description= _("(undocumented operator)"); + ot->description= UI_translate_do_iface(N_("(undocumented operator)")); RNA_def_struct_ui_text(ot->srna, ot->name, ot->description); // XXX All ops should have a description but for now allow them not to. RNA_def_struct_identifier(ot->srna, ot->idname); @@ -387,7 +387,7 @@ void WM_operatortype_append_macro_ptr(void (*opfunc)(wmOperatorType*, void*), vo ot->poll= NULL; if(!ot->description) - ot->description= _("(undocumented operator)"); + ot->description= UI_translate_do_iface(N_("(undocumented operator)")); opfunc(ot, userdata); @@ -784,7 +784,7 @@ int WM_operator_confirm_message(bContext *C, wmOperator *op, const char *message else properties= NULL; - pup= uiPupMenuBegin(C, _("OK?"), ICON_QUESTION); + pup= uiPupMenuBegin(C, UI_translate_do_iface(N_("OK?")), ICON_QUESTION); layout= uiPupMenuLayout(pup); uiItemFullO(layout, op->type->idname, message, ICON_NONE, properties, WM_OP_EXEC_REGION_WIN, 0); uiPupMenuEnd(C, pup); @@ -877,11 +877,11 @@ void WM_operator_properties_select_all(wmOperatorType *ot) { void WM_operator_properties_gesture_border(wmOperatorType *ot, int extend) { - RNA_def_int(ot->srna, "gesture_mode", 0, INT_MIN, INT_MAX, _("Gesture Mode"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "xmin", 0, INT_MIN, INT_MAX, _("X Min"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "xmax", 0, INT_MIN, INT_MAX, _("X Max"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "ymin", 0, INT_MIN, INT_MAX, _("Y Min"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "ymax", 0, INT_MIN, INT_MAX, _("Y Max"), "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "gesture_mode", 0, INT_MIN, INT_MAX, N_("Gesture Mode"), "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "xmin", 0, INT_MIN, INT_MAX, N_("X Min"), "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "xmax", 0, INT_MIN, INT_MAX, N_("X Max"), "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "ymin", 0, INT_MIN, INT_MAX, N_("Y Min"), "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "ymax", 0, INT_MIN, INT_MAX, N_("Y Max"), "", INT_MIN, INT_MAX); if(extend) RNA_def_boolean(ot->srna, "extend", 1, _("Extend"), _("Extend selection instead of deselecting everything first")); @@ -889,13 +889,13 @@ void WM_operator_properties_gesture_border(wmOperatorType *ot, int extend) void WM_operator_properties_gesture_straightline(wmOperatorType *ot, int cursor) { - RNA_def_int(ot->srna, "xstart", 0, INT_MIN, INT_MAX, _("X Start"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "xend", 0, INT_MIN, INT_MAX, _("X End"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "ystart", 0, INT_MIN, INT_MAX, _("Y Start"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "yend", 0, INT_MIN, INT_MAX, _("Y End"), "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "xstart", 0, INT_MIN, INT_MAX, N_("X Start"), "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "xend", 0, INT_MIN, INT_MAX, N_("X End"), "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "ystart", 0, INT_MIN, INT_MAX, N_("Y Start"), "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "yend", 0, INT_MIN, INT_MAX, N_("Y End"), "", INT_MIN, INT_MAX); if(cursor) - RNA_def_int(ot->srna, "cursor", cursor, 0, INT_MAX, _("Cursor"), _("Mouse cursor style to use during the modal operator"), 0, INT_MAX); + RNA_def_int(ot->srna, "cursor", cursor, 0, INT_MAX, N_("Cursor"), N_("Mouse cursor style to use during the modal operator"), 0, INT_MAX); } @@ -1026,7 +1026,7 @@ static uiBlock *wm_block_dialog_create(bContext *C, ARegion *ar, void *userData) col= uiLayoutColumn(layout, FALSE); col_block= uiLayoutGetBlock(col); /* Create OK button, the callback of which will execute op */ - btn= uiDefBut(col_block, BUT, 0, _("OK"), 0, -30, 0, UI_UNIT_Y, NULL, 0, 0, 0, 0, ""); + btn= uiDefBut(col_block, BUT, 0, UI_translate_do_iface(N_("OK")), 0, -30, 0, UI_UNIT_Y, NULL, 0, 0, 0, 0, ""); uiButSetFunc(btn, dialog_exec_cb, data, col_block); } @@ -1272,19 +1272,19 @@ static uiBlock *wm_block_create_splash(bContext *C, ARegion *ar, void *UNUSED(ar split = uiLayoutSplit(layout, 0, 0); col = uiLayoutColumn(split, 0); uiItemL(col, "Links", ICON_NONE); - uiItemStringO(col, _("Donations"), ICON_URL, "WM_OT_url_open", "url", "http://www.blender.org/blenderorg/blender-foundation/donation-payment"); - uiItemStringO(col, _("Credits"), ICON_URL, "WM_OT_url_open", "url", "http://www.blender.org/development/credits"); - uiItemStringO(col, _("Release Log"), ICON_URL, "WM_OT_url_open", "url", "http://www.blender.org/development/release-logs/blender-259"); - uiItemStringO(col, _("Manual"), ICON_URL, "WM_OT_url_open", "url", "http://wiki.blender.org/index.php/Doc:2.5/Manual"); - uiItemStringO(col, _("Blender Website"), ICON_URL, "WM_OT_url_open", "url", "http://www.blender.org"); - uiItemStringO(col, _("User Community"), ICON_URL, "WM_OT_url_open", "url", "http://www.blender.org/community/user-community"); + uiItemStringO(col, UI_translate_do_iface(N_("Donations")), ICON_URL, "WM_OT_url_open", "url", "http://www.blender.org/blenderorg/blender-foundation/donation-payment"); + uiItemStringO(col, UI_translate_do_iface(N_("Credits")), ICON_URL, "WM_OT_url_open", "url", "http://www.blender.org/development/credits"); + uiItemStringO(col, UI_translate_do_iface(N_("Release Log")), ICON_URL, "WM_OT_url_open", "url", "http://www.blender.org/development/release-logs/blender-259"); + uiItemStringO(col, UI_translate_do_iface(N_("Manual")), ICON_URL, "WM_OT_url_open", "url", "http://wiki.blender.org/index.php/Doc:2.5/Manual"); + uiItemStringO(col, UI_translate_do_iface(N_("Blender Website")), ICON_URL, "WM_OT_url_open", "url", "http://www.blender.org"); + uiItemStringO(col, UI_translate_do_iface(N_("User Community")), ICON_URL, "WM_OT_url_open", "url", "http://www.blender.org/community/user-community"); if(strcmp(STRINGIFY(BLENDER_VERSION_CYCLE), "release")==0) { BLI_snprintf(url, sizeof(url), "http://www.blender.org/documentation/blender_python_api_%d_%d" STRINGIFY(BLENDER_VERSION_CHAR) "_release", BLENDER_VERSION/100, BLENDER_VERSION%100); } else { BLI_snprintf(url, sizeof(url), "http://www.blender.org/documentation/blender_python_api_%d_%d_%d", BLENDER_VERSION/100, BLENDER_VERSION%100, BLENDER_SUBVERSION); } - uiItemStringO(col, _("Python API Reference"), ICON_URL, "WM_OT_url_open", "url", url); + uiItemStringO(col, UI_translate_do_iface(N_("Python API Reference")), ICON_URL, "WM_OT_url_open", "url", url); uiItemL(col, "", ICON_NONE); col = uiLayoutColumn(split, 0); @@ -1294,7 +1294,7 @@ static uiBlock *wm_block_create_splash(bContext *C, ARegion *ar, void *UNUSED(ar uiItemS(col); } - uiItemL(col, _("Recent"), ICON_NONE); + uiItemL(col, UI_translate_do_iface(N_("Recent")), ICON_NONE); for(recent = G.recent_files.first, i=0; (i<5) && (recent); recent = recent->next, i++) { uiItemStringO(col, BLI_path_basename(recent->filepath), ICON_FILE_BLEND, "WM_OT_open_mainfile", "filepath", recent->filepath); } @@ -1863,9 +1863,9 @@ static void untitled(char *name) char *c= BLI_last_slash(name); if(c) - strcpy(&c[1], _("untitled.blend")); + strcpy(&c[1], "untitled.blend"); else - strcpy(name, _("untitled.blend")); + strcpy(name, "untitled.blend"); } } |