Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorXiao Xiangquan <xiaoxiangquan@gmail.com>2011-06-15 15:41:15 +0400
committerXiao Xiangquan <xiaoxiangquan@gmail.com>2011-06-15 15:41:15 +0400
commitde12f8049a2fbd6e4feab02bc252411a8f5d5d1f (patch)
tree8188e6fc5c899330a54fc6076c594b325c53cc95 /source/blender/editors/interface
parent40981d872f0410caf1870194c8e15ebaed864dea (diff)
translate left panel
Diffstat (limited to 'source/blender/editors/interface')
-rw-r--r--source/blender/editors/interface/interface_layout.c4
-rw-r--r--source/blender/editors/interface/interface_ops.c14
-rw-r--r--source/blender/editors/interface/interface_utils.c4
-rw-r--r--source/blender/editors/interface/view2d_ops.c44
4 files changed, 37 insertions, 29 deletions
diff --git a/source/blender/editors/interface/interface_layout.c b/source/blender/editors/interface/interface_layout.c
index 55c1488291b..c7361180367 100644
--- a/source/blender/editors/interface/interface_layout.c
+++ b/source/blender/editors/interface/interface_layout.c
@@ -43,6 +43,8 @@
#include "BLI_string.h"
#include "BLI_utildefines.h"
+#include "BLF_api.h"
+
#include "BKE_context.h"
#include "BKE_global.h"
#include "BKE_idprop.h"
@@ -2781,7 +2783,7 @@ void uiLayoutOperatorButs(const bContext *C, uiLayout *layout, wmOperator *op,in
empty= uiDefAutoButsRNA(layout, &ptr, check_prop, label_align) == 0;
if(empty && (flag & UI_LAYOUT_OP_SHOW_EMPTY)) {
- uiItemL(layout, "No Properties.", ICON_NONE);
+ uiItemL(layout, _("No Properties."), ICON_NONE);
}
}
diff --git a/source/blender/editors/interface/interface_ops.c b/source/blender/editors/interface/interface_ops.c
index e9fad382beb..e2bfedcf3ea 100644
--- a/source/blender/editors/interface/interface_ops.c
+++ b/source/blender/editors/interface/interface_ops.c
@@ -44,6 +44,8 @@
#include "BLI_math_color.h"
#include "BLI_utildefines.h"
+#include "BLF_api.h"
+
#include "BKE_context.h"
#include "BKE_global.h"
#include "BKE_text.h" /* for UI_OT_reports_to_text */
@@ -305,9 +307,9 @@ static int reset_default_button_exec(bContext *C, wmOperator *op)
static void UI_OT_reset_default_button(wmOperatorType *ot)
{
/* identifiers */
- ot->name= "Reset to Default Value";
+ ot->name= _("Reset to Default Value");
ot->idname= "UI_OT_reset_default_button";
- ot->description= "Reset this property's value to its default value";
+ ot->description= _("Reset this property's value to its default value");
/* callbacks */
ot->poll= reset_default_button_poll;
@@ -317,7 +319,7 @@ static void UI_OT_reset_default_button(wmOperatorType *ot)
ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO;
/* properties */
- RNA_def_boolean(ot->srna, "all", 1, "All", "Reset to default values all elements of the array.");
+ RNA_def_boolean(ot->srna, "all", 1, _("All"), _("Reset to default values all elements of the array."));
}
/* Copy To Selected Operator ------------------------ */
@@ -397,9 +399,9 @@ static int copy_to_selected_button_exec(bContext *C, wmOperator *op)
static void UI_OT_copy_to_selected_button(wmOperatorType *ot)
{
/* identifiers */
- ot->name= "Copy To Selected";
+ ot->name= _("Copy To Selected");
ot->idname= "UI_OT_copy_to_selected_button";
- ot->description= "Copy property from this object to selected objects or bones";
+ ot->description= _("Copy property from this object to selected objects or bones");
/* callbacks */
ot->poll= copy_to_selected_button_poll;
@@ -409,7 +411,7 @@ static void UI_OT_copy_to_selected_button(wmOperatorType *ot)
ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO;
/* properties */
- RNA_def_boolean(ot->srna, "all", 1, "All", "Reset to default values all elements of the array.");
+ RNA_def_boolean(ot->srna, "all", 1, _("All"), _("Reset to default values all elements of the array."));
}
/* Reports to Textblock Operator ------------------------ */
diff --git a/source/blender/editors/interface/interface_utils.c b/source/blender/editors/interface/interface_utils.c
index 1ec125c2f26..8f20f47f539 100644
--- a/source/blender/editors/interface/interface_utils.c
+++ b/source/blender/editors/interface/interface_utils.c
@@ -37,6 +37,8 @@
#include "BLI_utildefines.h"
+#include "BLF_api.h"
+
#include "BKE_context.h"
@@ -117,7 +119,7 @@ uiBut *uiDefAutoButR(uiBlock *block, PointerRNA *ptr, PropertyRNA *prop, int ind
}
case PROP_COLLECTION: {
char text[256];
- sprintf(text, "%d items", RNA_property_collection_length(ptr, prop));
+ sprintf(text, _("%d items"), RNA_property_collection_length(ptr, prop));
but= uiDefBut(block, LABEL, 0, text, x1, y1, x2, y2, NULL, 0, 0, 0, 0, NULL);
uiButSetFlag(but, UI_BUT_DISABLED);
break;
diff --git a/source/blender/editors/interface/view2d_ops.c b/source/blender/editors/interface/view2d_ops.c
index 434334258af..979732b6044 100644
--- a/source/blender/editors/interface/view2d_ops.c
+++ b/source/blender/editors/interface/view2d_ops.c
@@ -39,6 +39,8 @@
#include "BLI_blenlib.h"
#include "BLI_utildefines.h"
+#include "BLF_api.h"
+
#include "BKE_context.h"
#include "RNA_access.h"
@@ -306,8 +308,8 @@ static void VIEW2D_OT_pan(wmOperatorType *ot)
ot->flag= OPTYPE_BLOCKING|OPTYPE_GRAB_POINTER;
/* rna - must keep these in sync with the other operators */
- RNA_def_int(ot->srna, "deltax", 0, INT_MIN, INT_MAX, "Delta X", "", INT_MIN, INT_MAX);
- RNA_def_int(ot->srna, "deltay", 0, INT_MIN, INT_MAX, "Delta Y", "", INT_MIN, INT_MAX);
+ RNA_def_int(ot->srna, "deltax", 0, INT_MIN, INT_MAX, _("Delta X"), "", INT_MIN, INT_MAX);
+ RNA_def_int(ot->srna, "deltay", 0, INT_MIN, INT_MAX, _("Delta Y"), "", INT_MIN, INT_MAX);
}
/* ------------------ Scrollwheel Versions (2) ---------------------- */
@@ -350,8 +352,8 @@ static void VIEW2D_OT_scroll_right(wmOperatorType *ot)
ot->exec= view_scrollright_exec;
/* rna - must keep these in sync with the other operators */
- RNA_def_int(ot->srna, "deltax", 0, INT_MIN, INT_MAX, "Delta X", "", INT_MIN, INT_MAX);
- RNA_def_int(ot->srna, "deltay", 0, INT_MIN, INT_MAX, "Delta Y", "", INT_MIN, INT_MAX);
+ RNA_def_int(ot->srna, "deltax", 0, INT_MIN, INT_MAX, _("Delta X"), "", INT_MIN, INT_MAX);
+ RNA_def_int(ot->srna, "deltay", 0, INT_MIN, INT_MAX, _("Delta Y"), "", INT_MIN, INT_MAX);
}
@@ -394,8 +396,8 @@ static void VIEW2D_OT_scroll_left(wmOperatorType *ot)
ot->exec= view_scrollleft_exec;
/* rna - must keep these in sync with the other operators */
- RNA_def_int(ot->srna, "deltax", 0, INT_MIN, INT_MAX, "Delta X", "", INT_MIN, INT_MAX);
- RNA_def_int(ot->srna, "deltay", 0, INT_MIN, INT_MAX, "Delta Y", "", INT_MIN, INT_MAX);
+ RNA_def_int(ot->srna, "deltax", 0, INT_MIN, INT_MAX, _("Delta X"), "", INT_MIN, INT_MAX);
+ RNA_def_int(ot->srna, "deltay", 0, INT_MIN, INT_MAX, _("Delta Y"), "", INT_MIN, INT_MAX);
}
@@ -434,17 +436,17 @@ static int view_scrolldown_exec(bContext *C, wmOperator *op)
static void VIEW2D_OT_scroll_down(wmOperatorType *ot)
{
/* identifiers */
- ot->name= "Scroll Down";
- ot->description= "Scroll the view down";
+ ot->name= _("Scroll Down");
+ ot->description= _("Scroll the view down");
ot->idname= "VIEW2D_OT_scroll_down";
/* api callbacks */
ot->exec= view_scrolldown_exec;
/* rna - must keep these in sync with the other operators */
- RNA_def_int(ot->srna, "deltax", 0, INT_MIN, INT_MAX, "Delta X", "", INT_MIN, INT_MAX);
- RNA_def_int(ot->srna, "deltay", 0, INT_MIN, INT_MAX, "Delta Y", "", INT_MIN, INT_MAX);
- RNA_def_boolean(ot->srna, "page", 0, "Page", "Scroll down one page.");
+ RNA_def_int(ot->srna, "deltax", 0, INT_MIN, INT_MAX, _("Delta X"), "", INT_MIN, INT_MAX);
+ RNA_def_int(ot->srna, "deltay", 0, INT_MIN, INT_MAX, _("Delta Y"), "", INT_MIN, INT_MAX);
+ RNA_def_boolean(ot->srna, "page", 0, _("Page"), _("Scroll down one page."));
}
@@ -484,17 +486,17 @@ static int view_scrollup_exec(bContext *C, wmOperator *op)
static void VIEW2D_OT_scroll_up(wmOperatorType *ot)
{
/* identifiers */
- ot->name= "Scroll Up";
- ot->description= "Scroll the view up";
+ ot->name= _("Scroll Up");
+ ot->description= _("Scroll the view up");
ot->idname= "VIEW2D_OT_scroll_up";
/* api callbacks */
ot->exec= view_scrollup_exec;
/* rna - must keep these in sync with the other operators */
- RNA_def_int(ot->srna, "deltax", 0, INT_MIN, INT_MAX, "Delta X", "", INT_MIN, INT_MAX);
- RNA_def_int(ot->srna, "deltay", 0, INT_MIN, INT_MAX, "Delta Y", "", INT_MIN, INT_MAX);
- RNA_def_boolean(ot->srna, "page", 0, "Page", "Scroll up one page.");
+ RNA_def_int(ot->srna, "deltax", 0, INT_MIN, INT_MAX, _("Delta X"), "", INT_MIN, INT_MAX);
+ RNA_def_int(ot->srna, "deltay", 0, INT_MIN, INT_MAX, _("Delta Y"), "", INT_MIN, INT_MAX);
+ RNA_def_boolean(ot->srna, "page", 0, _("Page"), _("Scroll up one page."));
}
/* ********************************************************* */
@@ -1178,11 +1180,11 @@ static void VIEW2D_OT_zoom_border(wmOperatorType *ot)
ot->poll= view_zoom_poll;
/* rna */
- 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, _("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);
}
/* ********************************************************* */