diff options
| author | Andreas Haas | 2017-08-23 22:25:14 +0200 |
|---|---|---|
| committer | Rémi Verschelde | 2017-08-25 18:49:45 +0200 |
| commit | 6134d8741d6b255751e7b2811be85b60ef916269 (patch) | |
| tree | 27edc499e4ecced86630715232f7adfa62f9b3c4 /editor/plugins | |
| parent | a1c03a69d2940fb69d7221800e919f4a183fec0c (diff) | |
| download | godot-6134d87.tar.gz godot-6134d87.tar.zst godot-6134d87.zip | |
Editor: Add some more translatable strings.
Diffstat (limited to 'editor/plugins')
| -rw-r--r-- | editor/plugins/animation_player_editor_plugin.cpp | 1 | ||||
| -rw-r--r-- | editor/plugins/animation_tree_editor_plugin.cpp | 2 | ||||
| -rw-r--r-- | editor/plugins/collision_polygon_2d_editor_plugin.cpp | 2 | ||||
| -rw-r--r-- | editor/plugins/light_occluder_2d_editor_plugin.cpp | 2 | ||||
| -rw-r--r-- | editor/plugins/particles_2d_editor_plugin.cpp | 2 | ||||
| -rw-r--r-- | editor/plugins/particles_editor_plugin.cpp | 2 | ||||
| -rw-r--r-- | editor/plugins/resource_preloader_editor_plugin.cpp | 1 | ||||
| -rw-r--r-- | editor/plugins/script_editor_plugin.cpp | 4 | ||||
| -rw-r--r-- | editor/plugins/script_text_editor.cpp | 2 | ||||
| -rw-r--r-- | editor/plugins/spatial_editor_plugin.cpp | 4 | ||||
| -rw-r--r-- | editor/plugins/texture_region_editor_plugin.cpp | 2 | ||||
| -rw-r--r-- | editor/plugins/theme_editor_plugin.cpp | 4 | ||||
| -rw-r--r-- | editor/plugins/tile_map_editor_plugin.cpp | 8 |
13 files changed, 17 insertions, 19 deletions
diff --git a/editor/plugins/animation_player_editor_plugin.cpp b/editor/plugins/animation_player_editor_plugin.cpp index a1fec795f..43d6c22bc 100644 --- a/editor/plugins/animation_player_editor_plugin.cpp +++ b/editor/plugins/animation_player_editor_plugin.cpp @@ -1395,7 +1395,6 @@ AnimationPlayerEditor::AnimationPlayerEditor(EditorNode *p_editor) { error_dialog = memnew(ConfirmationDialog); error_dialog->get_ok()->set_text(TTR("Close")); - //error_dialog->get_cancel()->set_text("Close"); error_dialog->set_text(TTR("Error!")); add_child(error_dialog); diff --git a/editor/plugins/animation_tree_editor_plugin.cpp b/editor/plugins/animation_tree_editor_plugin.cpp index 9d150150a..f3ff91550 100644 --- a/editor/plugins/animation_tree_editor_plugin.cpp +++ b/editor/plugins/animation_tree_editor_plugin.cpp @@ -285,7 +285,7 @@ void AnimationTreeEditor::_popup_edit_dialog() { AnimationPlayer *ap = Object::cast_to<AnimationPlayer>(anim_tree->get_node(anim_tree->get_master_player())); master_anim_popup->clear(); - master_anim_popup->add_item("Edit Filters"); + master_anim_popup->add_item(TTR("Edit Filters")); master_anim_popup->add_separator(); List<StringName> sn; ap->get_animation_list(&sn); diff --git a/editor/plugins/collision_polygon_2d_editor_plugin.cpp b/editor/plugins/collision_polygon_2d_editor_plugin.cpp index dd9bd6c34..09c75b9e8 100644 --- a/editor/plugins/collision_polygon_2d_editor_plugin.cpp +++ b/editor/plugins/collision_polygon_2d_editor_plugin.cpp @@ -384,7 +384,7 @@ CollisionPolygon2DEditor::CollisionPolygon2DEditor(EditorNode *p_editor) { add_child(button_edit); button_edit->connect("pressed", this, "_menu_option", varray(MODE_EDIT)); button_edit->set_toggle_mode(true); - button_edit->set_tooltip("Edit existing polygon:\nLMB: Move Point.\nCtrl+LMB: Split Segment.\nRMB: Erase Point."); + button_edit->set_tooltip(TTR("Edit existing polygon:\nLMB: Move Point.\nCtrl+LMB: Split Segment.\nRMB: Erase Point.")); //add_constant_override("separation",0); diff --git a/editor/plugins/light_occluder_2d_editor_plugin.cpp b/editor/plugins/light_occluder_2d_editor_plugin.cpp index 14d9f3991..e83cd779c 100644 --- a/editor/plugins/light_occluder_2d_editor_plugin.cpp +++ b/editor/plugins/light_occluder_2d_editor_plugin.cpp @@ -106,7 +106,7 @@ bool LightOccluder2DEditor::forward_gui_input(const Ref<InputEvent> &p_event) { if (node->get_occluder_polygon().is_null()) { Ref<InputEventMouseButton> mb = p_event; if (mb.is_valid() && mb->get_button_index() == 1 && mb->is_pressed()) { - create_poly->set_text("No OccluderPolygon2D resource on this node.\nCreate and assign one?"); + create_poly->set_text(TTR("No OccluderPolygon2D resource on this node.\nCreate and assign one?")); create_poly->popup_centered_minsize(); } return (mb.is_valid() && mb->get_button_index() == 1); diff --git a/editor/plugins/particles_2d_editor_plugin.cpp b/editor/plugins/particles_2d_editor_plugin.cpp index 076e27c74..98972f8f9 100644 --- a/editor/plugins/particles_2d_editor_plugin.cpp +++ b/editor/plugins/particles_2d_editor_plugin.cpp @@ -354,7 +354,7 @@ Particles2DEditorPlugin::Particles2DEditorPlugin(EditorNode *p_node) { menu->get_popup()->add_separator(); menu->get_popup()->add_item(TTR("Load Emission Mask"), MENU_LOAD_EMISSION_MASK); // menu->get_popup()->add_item(TTR("Clear Emission Mask"), MENU_CLEAR_EMISSION_MASK); - menu->set_text("Particles"); + menu->set_text(TTR("Particles")); toolbar->add_child(menu); file = memnew(EditorFileDialog); diff --git a/editor/plugins/particles_editor_plugin.cpp b/editor/plugins/particles_editor_plugin.cpp index ef959682c..4dfae5174 100644 --- a/editor/plugins/particles_editor_plugin.cpp +++ b/editor/plugins/particles_editor_plugin.cpp @@ -389,7 +389,7 @@ ParticlesEditor::ParticlesEditor() { particles_editor_hb->add_child(options); particles_editor_hb->hide(); - options->set_text("Particles"); + options->set_text(TTR("Particles")); options->get_popup()->add_item(TTR("Generate AABB"), MENU_OPTION_GENERATE_AABB); options->get_popup()->add_separator(); options->get_popup()->add_item(TTR("Create Emission Points From Mesh"), MENU_OPTION_CREATE_EMISSION_VOLUME_FROM_MESH); diff --git a/editor/plugins/resource_preloader_editor_plugin.cpp b/editor/plugins/resource_preloader_editor_plugin.cpp index 001db2cbc..8a7e86922 100644 --- a/editor/plugins/resource_preloader_editor_plugin.cpp +++ b/editor/plugins/resource_preloader_editor_plugin.cpp @@ -157,7 +157,6 @@ void ResourcePreloaderEditor::_paste_pressed() { if (!r.is_valid()) { dialog->set_text(TTR("Resource clipboard is empty!")); dialog->set_title(TTR("Error!")); - //dialog->get_cancel()->set_text("Close"); dialog->get_ok()->set_text(TTR("Close")); dialog->popup_centered_minsize(); return; ///beh should show an error i guess diff --git a/editor/plugins/script_editor_plugin.cpp b/editor/plugins/script_editor_plugin.cpp index 5b0891e0c..a6db0f6e5 100644 --- a/editor/plugins/script_editor_plugin.cpp +++ b/editor/plugins/script_editor_plugin.cpp @@ -602,7 +602,7 @@ void ScriptEditor::_close_all_tabs() { } void ScriptEditor::_ask_close_current_unsaved_tab(ScriptEditorBase *current) { - erase_tab_confirm->set_text("Close and save changes?\n\"" + current->get_name() + "\""); + erase_tab_confirm->set_text(TTR("Close and save changes?\n\"") + current->get_name() + "\""); erase_tab_confirm->popup_centered_minsize(); } @@ -1568,7 +1568,7 @@ void ScriptEditor::_update_script_names() { String name = eh->get_class(); Ref<Texture> icon = get_icon("Help", "EditorIcons"); - String tooltip = name + " Class Reference"; + String tooltip = name + TTR(" Class Reference"); _ScriptEditorItemData sd; sd.icon = icon; diff --git a/editor/plugins/script_text_editor.cpp b/editor/plugins/script_text_editor.cpp index e86ff8cac..d3bfbf17f 100644 --- a/editor/plugins/script_text_editor.cpp +++ b/editor/plugins/script_text_editor.cpp @@ -1230,7 +1230,7 @@ void ScriptTextEditor::drop_data_fw(const Point2 &p_point, const Variant &p_data } if (res->get_path().is_resource_file()) { - EditorNode::get_singleton()->show_warning("Only resources from filesystem can be dropped."); + EditorNode::get_singleton()->show_warning(TTR("Only resources from filesystem can be dropped.")); return; } diff --git a/editor/plugins/spatial_editor_plugin.cpp b/editor/plugins/spatial_editor_plugin.cpp index c4e405053..b269f2903 100644 --- a/editor/plugins/spatial_editor_plugin.cpp +++ b/editor/plugins/spatial_editor_plugin.cpp @@ -2483,7 +2483,7 @@ SpatialEditorViewport::SpatialEditorViewport(SpatialEditor *p_spatial_editor, Ed preview_camera->set_toggle_mode(true); preview_camera->set_anchor_and_margin(MARGIN_LEFT, ANCHOR_END, -90 * EDSCALE); preview_camera->set_anchor_and_margin(MARGIN_TOP, ANCHOR_BEGIN, 10 * EDSCALE); - preview_camera->set_text("preview"); + preview_camera->set_text(TTR("preview")); surface->add_child(preview_camera); preview_camera->hide(); preview_camera->connect("toggled", this, "_toggle_camera_preview"); @@ -3829,7 +3829,7 @@ SpatialEditor::SpatialEditor(EditorNode *p_editor) { tool_button[TOOL_MODE_SELECT]->set_pressed(true); button_binds[0] = MENU_TOOL_SELECT; tool_button[TOOL_MODE_SELECT]->connect("pressed", this, "_menu_item_pressed", button_binds); - tool_button[TOOL_MODE_SELECT]->set_tooltip("Select Mode (Q)\n" + keycode_get_string(KEY_MASK_CMD) + "Drag: Rotate\nAlt+Drag: Move\nAlt+RMB: Depth list selection"); + tool_button[TOOL_MODE_SELECT]->set_tooltip(TTR("Select Mode (Q)\n") + keycode_get_string(KEY_MASK_CMD) + TTR("Drag: Rotate\nAlt+Drag: Move\nAlt+RMB: Depth list selection")); tool_button[TOOL_MODE_MOVE] = memnew(ToolButton); diff --git a/editor/plugins/texture_region_editor_plugin.cpp b/editor/plugins/texture_region_editor_plugin.cpp index d9e310a58..640665523 100644 --- a/editor/plugins/texture_region_editor_plugin.cpp +++ b/editor/plugins/texture_region_editor_plugin.cpp @@ -280,7 +280,7 @@ void TextureRegionEditor::_region_input(const Ref<InputEvent> &p_input) { rect.expand_to(r.position); rect.expand_to(r.position + r.size); } - undo_redo->create_action("Set Region Rect"); + undo_redo->create_action(TTR("Set Region Rect")); if (node_sprite) { undo_redo->add_do_method(node_sprite, "set_region_rect", rect); undo_redo->add_undo_method(node_sprite, "set_region_rect", node_sprite->get_region_rect()); diff --git a/editor/plugins/theme_editor_plugin.cpp b/editor/plugins/theme_editor_plugin.cpp index 9cf43e656..c55bc46b2 100644 --- a/editor/plugins/theme_editor_plugin.cpp +++ b/editor/plugins/theme_editor_plugin.cpp @@ -529,8 +529,8 @@ void ThemeEditor::_theme_menu_cbk(int p_option) { } else if (p_option == POPUP_CLASS_REMOVE) { - add_del_dialog->set_title("Remove All Items"); - add_del_dialog->get_ok()->set_text("Remove All"); + add_del_dialog->set_title(TTR("Remove All Items")); + add_del_dialog->get_ok()->set_text(TTR("Remove All")); add_del_dialog->popup_centered(Size2(240, 85) * EDSCALE); base_theme = Theme::get_default(); diff --git a/editor/plugins/tile_map_editor_plugin.cpp b/editor/plugins/tile_map_editor_plugin.cpp index d89fe43ed..6749f2420 100644 --- a/editor/plugins/tile_map_editor_plugin.cpp +++ b/editor/plugins/tile_map_editor_plugin.cpp @@ -106,7 +106,7 @@ void TileMapEditor::_menu_option(int p_option) { if (!selection_active) return; - undo_redo->create_action("Erase Selection"); + undo_redo->create_action(TTR("Erase Selection")); for (int i = rectangle.position.y; i <= rectangle.position.y + rectangle.size.y; i++) { for (int j = rectangle.position.x; j <= rectangle.position.x + rectangle.size.x; j++) { @@ -730,7 +730,7 @@ bool TileMapEditor::forward_gui_input(const Ref<InputEvent> &p_event) { if (id != TileMap::INVALID_CELL) { - undo_redo->create_action("Line Draw"); + undo_redo->create_action(TTR("Line Draw")); for (Map<Point2i, CellOp>::Element *E = paint_undo.front(); E; E = E->next()) { _set_cell(E->key(), id, flip_h, flip_v, transpose, true); @@ -747,7 +747,7 @@ bool TileMapEditor::forward_gui_input(const Ref<InputEvent> &p_event) { if (id != TileMap::INVALID_CELL) { - undo_redo->create_action("Rectangle Paint"); + undo_redo->create_action(TTR("Rectangle Paint")); for (int i = rectangle.position.y; i <= rectangle.position.y + rectangle.size.y; i++) { for (int j = rectangle.position.x; j <= rectangle.position.x + rectangle.size.x; j++) { @@ -796,7 +796,7 @@ bool TileMapEditor::forward_gui_input(const Ref<InputEvent> &p_event) { op["flip_v"] = flip_v; op["transpose"] = transpose; - undo_redo->create_action("Bucket Fill"); + undo_redo->create_action(TTR("Bucket Fill")); undo_redo->add_do_method(this, "_fill_points", points, op); undo_redo->add_undo_method(this, "_fill_points", points, pop); |
