diff options
author | Juan Linietsky <reduzio@gmail.com> | 2017-01-12 00:51:08 -0300 |
---|---|---|
committer | Juan Linietsky <reduzio@gmail.com> | 2017-01-12 00:51:08 -0300 |
commit | 83cb84753fb17d0c3e4dbe15388279ee93f97e3e (patch) | |
tree | 202b22d5061cc3b79d2ffca8280d50e1ad107a72 /tools/editor | |
parent | c84d618b4ea944e5c386d21f45265f9cb6fa783e (diff) |
Renamed most signals so they refer to:
-An action being requested to the user in present tense: (ie, draw, gui_input, etc)
-A notification that an action happened, in past tense (ie, area_entered, modal_closed, etc).
Diffstat (limited to 'tools/editor')
-rw-r--r-- | tools/editor/animation_editor.cpp | 4 | ||||
-rw-r--r-- | tools/editor/editor_data.cpp | 4 | ||||
-rw-r--r-- | tools/editor/editor_log.cpp | 2 | ||||
-rw-r--r-- | tools/editor/editor_node.cpp | 2 | ||||
-rw-r--r-- | tools/editor/editor_profiler.cpp | 2 | ||||
-rw-r--r-- | tools/editor/plugins/canvas_item_editor_plugin.cpp | 4 | ||||
-rw-r--r-- | tools/editor/plugins/spatial_editor_plugin.cpp | 8 | ||||
-rw-r--r-- | tools/editor/plugins/texture_region_editor_plugin.cpp | 10 | ||||
-rw-r--r-- | tools/editor/plugins/tile_map_editor_plugin.cpp | 16 | ||||
-rw-r--r-- | tools/editor/property_editor.cpp | 4 |
10 files changed, 28 insertions, 28 deletions
diff --git a/tools/editor/animation_editor.cpp b/tools/editor/animation_editor.cpp index a98a435ea2..be4d5f48e2 100644 --- a/tools/editor/animation_editor.cpp +++ b/tools/editor/animation_editor.cpp @@ -3248,12 +3248,12 @@ void AnimationKeyEditor::set_animation(const Ref<Animation>& p_anim) { void AnimationKeyEditor::set_root(Node *p_root) { if (root) - root->disconnect("exit_tree",this,"_root_removed"); + root->disconnect("tree_exited",this,"_root_removed"); root=p_root; if (root) - root->connect("exit_tree",this,"_root_removed",make_binds(),CONNECT_ONESHOT); + root->connect("tree_exited",this,"_root_removed",make_binds(),CONNECT_ONESHOT); } diff --git a/tools/editor/editor_data.cpp b/tools/editor/editor_data.cpp index f27fe79a85..710d955326 100644 --- a/tools/editor/editor_data.cpp +++ b/tools/editor/editor_data.cpp @@ -851,7 +851,7 @@ void EditorSelection::add_node(Node *p_node) { } selection[p_node]=meta; - p_node->connect("exit_tree",this,"_node_removed",varray(p_node),CONNECT_ONESHOT); + p_node->connect("tree_exited",this,"_node_removed",varray(p_node),CONNECT_ONESHOT); //emit_signal("selection_changed"); } @@ -869,7 +869,7 @@ void EditorSelection::remove_node(Node *p_node) { if (meta) memdelete(meta); selection.erase(p_node); - p_node->disconnect("exit_tree",this,"_node_removed"); + p_node->disconnect("tree_exited",this,"_node_removed"); //emit_signal("selection_changed"); } bool EditorSelection::is_selected(Node * p_node) const { diff --git a/tools/editor/editor_log.cpp b/tools/editor/editor_log.cpp index 06459928f0..16dfb7afb2 100644 --- a/tools/editor/editor_log.cpp +++ b/tools/editor/editor_log.cpp @@ -200,7 +200,7 @@ EditorLog::EditorLog() { pc = memnew( PanelContainer ); ec->add_child(pc); pc->set_area_as_parent_rect(); - pc->connect("enter_tree", this, "_override_logger_styles"); + pc->connect("tree_entered", this, "_override_logger_styles"); log = memnew( RichTextLabel ); log->set_scroll_follow(true); diff --git a/tools/editor/editor_node.cpp b/tools/editor/editor_node.cpp index 096999d5e7..98c59208d2 100644 --- a/tools/editor/editor_node.cpp +++ b/tools/editor/editor_node.cpp @@ -5621,7 +5621,7 @@ EditorNode::EditorNode() { dock_select->set_custom_minimum_size(Size2(128,64)*EDSCALE); dock_select->connect("gui_input",this,"_dock_select_input"); dock_select->connect("draw",this,"_dock_select_draw"); - dock_select->connect("mouse_exit",this,"_dock_popup_exit"); + dock_select->connect("mouse_exited",this,"_dock_popup_exit"); dock_select->set_v_size_flags(Control::SIZE_EXPAND_FILL); dock_vb->add_child(dock_select); diff --git a/tools/editor/editor_profiler.cpp b/tools/editor/editor_profiler.cpp index 162e1d05f5..c527aae385 100644 --- a/tools/editor/editor_profiler.cpp +++ b/tools/editor/editor_profiler.cpp @@ -714,7 +714,7 @@ EditorProfiler::EditorProfiler() //graph->set_ignore_mouse(false); graph->connect("draw",this,"_graph_tex_draw"); graph->connect("gui_input",this,"_graph_tex_input"); - graph->connect("mouse_exit",this,"_graph_tex_mouse_exit"); + graph->connect("mouse_exited",this,"_graph_tex_mouse_exit"); h_split->add_child(graph); graph->set_h_size_flags(SIZE_EXPAND_FILL); diff --git a/tools/editor/plugins/canvas_item_editor_plugin.cpp b/tools/editor/plugins/canvas_item_editor_plugin.cpp index 5fce9f8f53..1abbac4539 100644 --- a/tools/editor/plugins/canvas_item_editor_plugin.cpp +++ b/tools/editor/plugins/canvas_item_editor_plugin.cpp @@ -3971,9 +3971,9 @@ void CanvasItemEditorViewport::drop_data(const Point2& p_point,const Variant& p_ void CanvasItemEditorViewport::_notification(int p_what) { if (p_what==NOTIFICATION_ENTER_TREE) { - connect("mouse_exit",this,"_on_mouse_exit"); + connect("mouse_exited",this,"_on_mouse_exit"); } else if (p_what==NOTIFICATION_EXIT_TREE) { - disconnect("mouse_exit",this,"_on_mouse_exit"); + disconnect("mouse_exited",this,"_on_mouse_exit"); } } diff --git a/tools/editor/plugins/spatial_editor_plugin.cpp b/tools/editor/plugins/spatial_editor_plugin.cpp index 6a1098bc6e..f508ab95c2 100644 --- a/tools/editor/plugins/spatial_editor_plugin.cpp +++ b/tools/editor/plugins/spatial_editor_plugin.cpp @@ -1853,7 +1853,7 @@ void SpatialEditorViewport::_notification(int p_what) { surface->connect("draw",this,"_draw"); surface->connect("gui_input",this,"_sinput"); - surface->connect("mouse_enter",this,"_smouseenter"); + surface->connect("mouse_entered",this,"_smouseenter"); preview_camera->set_icon(get_icon("Camera","EditorIcons")); _init_gizmo_instance(index); } @@ -2150,7 +2150,7 @@ void SpatialEditorViewport::_toggle_camera_preview(bool p_activate) { if (!p_activate) { - previewing->disconnect("exit_tree",this,"_preview_exited_scene"); + previewing->disconnect("tree_exited",this,"_preview_exited_scene"); previewing=NULL; VS::get_singleton()->viewport_attach_camera( viewport->get_viewport(), camera->get_camera() ); //restore if (!preview) @@ -2161,7 +2161,7 @@ void SpatialEditorViewport::_toggle_camera_preview(bool p_activate) { } else { previewing=preview; - previewing->connect("exit_tree",this,"_preview_exited_scene"); + previewing->connect("tree_exited",this,"_preview_exited_scene"); VS::get_singleton()->viewport_attach_camera( viewport->get_viewport(), preview->get_camera() ); //replace view_menu->hide(); surface->update(); @@ -2266,7 +2266,7 @@ void SpatialEditorViewport::set_state(const Dictionary& p_state) { Node *pv = EditorNode::get_singleton()->get_edited_scene()->get_node(p_state["previewing"]); if (pv && pv->cast_to<Camera>()) { previewing=pv->cast_to<Camera>(); - previewing->connect("exit_tree",this,"_preview_exited_scene"); + previewing->connect("tree_exited",this,"_preview_exited_scene"); VS::get_singleton()->viewport_attach_camera( viewport->get_viewport(), previewing->get_camera() ); //replace view_menu->hide(); surface->update(); diff --git a/tools/editor/plugins/texture_region_editor_plugin.cpp b/tools/editor/plugins/texture_region_editor_plugin.cpp index 15fe95075c..50e2cfb199 100644 --- a/tools/editor/plugins/texture_region_editor_plugin.cpp +++ b/tools/editor/plugins/texture_region_editor_plugin.cpp @@ -653,17 +653,17 @@ void TextureRegionEditor::edit(Object *p_obj) p_obj->connect("texture_changed",this,"_edit_region"); } p_obj->add_change_receptor(this); - p_obj->connect("exit_tree",this,"_node_removed",varray(p_obj),CONNECT_ONESHOT); + p_obj->connect("tree_exited",this,"_node_removed",varray(p_obj),CONNECT_ONESHOT); _edit_region(); } else { if(node_sprite) - node_sprite->disconnect("exit_tree",this,"_node_removed"); + node_sprite->disconnect("tree_exited",this,"_node_removed"); else if(node_patch9) - node_patch9->disconnect("exit_tree",this,"_node_removed"); + node_patch9->disconnect("tree_exited",this,"_node_removed"); else if(obj_styleBox.is_valid()) - obj_styleBox->disconnect("exit_tree",this,"_node_removed"); + obj_styleBox->disconnect("tree_exited",this,"_node_removed"); else if(atlas_tex.is_valid()) - atlas_tex->disconnect("exit_tree",this,"_node_removed"); + atlas_tex->disconnect("tree_exited",this,"_node_removed"); node_sprite = NULL; node_patch9 = NULL; diff --git a/tools/editor/plugins/tile_map_editor_plugin.cpp b/tools/editor/plugins/tile_map_editor_plugin.cpp index 0d384ea3a2..2c64f7cd89 100644 --- a/tools/editor/plugins/tile_map_editor_plugin.cpp +++ b/tools/editor/plugins/tile_map_editor_plugin.cpp @@ -1302,10 +1302,10 @@ void TileMapEditor::edit(Node *p_tile_map) { node=p_tile_map->cast_to<TileMap>(); if (!canvas_item_editor->is_connected("draw",this,"_canvas_draw")) canvas_item_editor->connect("draw",this,"_canvas_draw"); - if (!canvas_item_editor->is_connected("mouse_enter",this,"_canvas_mouse_enter")) - canvas_item_editor->connect("mouse_enter",this,"_canvas_mouse_enter"); - if (!canvas_item_editor->is_connected("mouse_exit",this,"_canvas_mouse_exit")) - canvas_item_editor->connect("mouse_exit",this,"_canvas_mouse_exit"); + if (!canvas_item_editor->is_connected("mouse_entered",this,"_canvas_mouse_enter")) + canvas_item_editor->connect("mouse_entered",this,"_canvas_mouse_enter"); + if (!canvas_item_editor->is_connected("mouse_exited",this,"_canvas_mouse_exit")) + canvas_item_editor->connect("mouse_exited",this,"_canvas_mouse_exit"); _update_palette(); @@ -1314,10 +1314,10 @@ void TileMapEditor::edit(Node *p_tile_map) { if (canvas_item_editor->is_connected("draw",this,"_canvas_draw")) canvas_item_editor->disconnect("draw",this,"_canvas_draw"); - if (canvas_item_editor->is_connected("mouse_enter",this,"_canvas_mouse_enter")) - canvas_item_editor->disconnect("mouse_enter",this,"_canvas_mouse_enter"); - if (canvas_item_editor->is_connected("mouse_exit",this,"_canvas_mouse_exit")) - canvas_item_editor->disconnect("mouse_exit",this,"_canvas_mouse_exit"); + if (canvas_item_editor->is_connected("mouse_entered",this,"_canvas_mouse_enter")) + canvas_item_editor->disconnect("mouse_entered",this,"_canvas_mouse_enter"); + if (canvas_item_editor->is_connected("mouse_exited",this,"_canvas_mouse_exit")) + canvas_item_editor->disconnect("mouse_exited",this,"_canvas_mouse_exit"); _update_palette(); } diff --git a/tools/editor/property_editor.cpp b/tools/editor/property_editor.cpp index e748abdc4e..59538ffc6a 100644 --- a/tools/editor/property_editor.cpp +++ b/tools/editor/property_editor.cpp @@ -2000,8 +2000,8 @@ CustomPropertyEditor::CustomPropertyEditor() { value_editor[i]->hide(); value_label[i]->hide(); value_editor[i]->connect("text_entered", this,"_modified"); - value_editor[i]->connect("focus_enter", this, "_focus_enter"); - value_editor[i]->connect("focus_exit", this, "_focus_exit"); + value_editor[i]->connect("focus_entered", this, "_focus_enter"); + value_editor[i]->connect("focus_exited", this, "_focus_exit"); } for(int i=0;i<4;i++) { |