1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-12 13:20:55 +00:00

Signals became a tab

added icons to contextual scene tree menu
This commit is contained in:
Juan Linietsky
2016-06-03 21:03:09 -03:00
parent cd56cad9ac
commit 26332479d3
8 changed files with 95 additions and 76 deletions

View File

@@ -1533,6 +1533,7 @@ void EditorNode::push_item(Object *p_object,const String& p_property) {
if (!p_object) {
property_editor->edit(NULL);
connections_dock->set_node(NULL);
scene_tree_dock->set_selected(NULL);
return;
}
@@ -1678,6 +1679,7 @@ void EditorNode::_edit_current() {
scene_tree_dock->set_selected(NULL);
property_editor->edit( NULL );
connections_dock->set_node(NULL);
object_menu->set_disabled(true);
_display_top_editors(false);
@@ -1697,6 +1699,7 @@ void EditorNode::_edit_current() {
ERR_FAIL_COND(!current_res);
scene_tree_dock->set_selected(NULL);
property_editor->edit( current_res );
connections_dock->set_node(NULL);
object_menu->set_disabled(false);
//resources_dock->add_resource(Ref<Resource>(current_res));
@@ -1713,6 +1716,7 @@ void EditorNode::_edit_current() {
property_editor->edit( current_node );
connections_dock->set_node( current_node );
scene_tree_dock->set_selected(current_node);
object_menu->get_popup()->clear();
@@ -1721,6 +1725,7 @@ void EditorNode::_edit_current() {
} else {
property_editor->edit( current_obj );
connections_dock->set_node(NULL);
//scene_tree_dock->set_selected(current_node);
//object_menu->get_popup()->clear();
@@ -5785,14 +5790,20 @@ EditorNode::EditorNode() {
debug_button->set_tooltip(TTR("Debug options"));
p=debug_button->get_popup();
p->add_check_item(TTR("Remote Debug Deploys"),RUN_DEPLOY_REMOTE_DEBUG);
p->add_check_item(TTR("Use PC Filesystem for Deploys"),RUN_FILE_SERVER);
p->add_check_item(TTR("Deploy with Remote Debug"),RUN_DEPLOY_REMOTE_DEBUG);
p->set_item_tooltip(p->get_item_count()-1,TTR("When exporting or deploying, the resulting executable will attempt to connect to the IP of this computer in order to be debugged."));
p->add_check_item(TTR("Small Deploy with Network FS"),RUN_FILE_SERVER);
p->set_item_tooltip(p->get_item_count()-1,TTR("When this option is enabled, export or deploy will produce a minimal executable.\nThe filesystem will be provided from the project by the editor over the network. On Android, deploy will use the USB cable for faster performance. This option speeds up testing for games with a large footprint."));
p->add_separator();
p->add_check_item(TTR("Visible Collision Shapes"),RUN_DEBUG_COLLISONS);
p->set_item_tooltip(p->get_item_count()-1,TTR("Collision shapes and raycast nodes (for 2D and 3D) will be visible on the running game if this option is turned on."));
p->add_check_item(TTR("Visible Navigation"),RUN_DEBUG_NAVIGATION);
p->set_item_tooltip(p->get_item_count()-1,TTR("Navigation meshes and polygons will be visible on the running game if this option is turned on."));
p->add_separator();
p->add_check_item(TTR("Mirror Scene Editing"),RUN_LIVE_DEBUG);
p->add_check_item(TTR("Mirror Script Changes"),RUN_RELOAD_SCRIPTS);
p->add_check_item(TTR("Sync Scene Changes"),RUN_LIVE_DEBUG);
p->set_item_tooltip(p->get_item_count()-1,TTR("When this option is turned on, any changes made to the scene in the editor will be replicated in the running game.\nThis works remotely, and is more efficient with networked filesystem."));
p->add_check_item(TTR("Sync Script Changes"),RUN_RELOAD_SCRIPTS);
p->set_item_tooltip(p->get_item_count()-1,TTR("When this option is turned on, any script that is saved will be reloaded on the running game.\nThis works remotely, and is more efficient with networked filesystem."));
p->connect("item_pressed",this,"_menu_option");
/*
@@ -5917,7 +5928,7 @@ EditorNode::EditorNode() {
scene_tree_dock = memnew( SceneTreeDock(this,scene_root,editor_selection,editor_data) );
scene_tree_dock->set_name(TTR("Scene"));
//top_pallete->add_child(scene_tree_dock);
dock_slot[DOCK_SLOT_LEFT_UR]->add_child(scene_tree_dock);
dock_slot[DOCK_SLOT_RIGHT_UL]->add_child(scene_tree_dock);
#if 0
resources_dock = memnew( ResourcesDock(this) );
resources_dock->set_name("Resources");
@@ -5925,7 +5936,7 @@ EditorNode::EditorNode() {
dock_slot[DOCK_SLOT_RIGHT_BL]->add_child(resources_dock);
//top_pallete->set_v_size_flags(Control::SIZE_EXPAND_FILL);
#endif
dock_slot[DOCK_SLOT_RIGHT_BL]->hide();
dock_slot[DOCK_SLOT_LEFT_BR]->hide();
/*Control *editor_spacer = memnew( Control );
editor_spacer->set_custom_minimum_size(Size2(260,200));
editor_spacer->set_v_size_flags(Control::SIZE_EXPAND_FILL);
@@ -5947,7 +5958,7 @@ EditorNode::EditorNode() {
VBoxContainer *prop_editor_base = memnew( VBoxContainer );
prop_editor_base->set_name(TTR("Inspector")); // Properties?
dock_slot[DOCK_SLOT_RIGHT_UL]->add_child(prop_editor_base);
dock_slot[DOCK_SLOT_RIGHT_BL]->add_child(prop_editor_base);
HBoxContainer *prop_editor_hb = memnew( HBoxContainer );
@@ -6059,10 +6070,14 @@ EditorNode::EditorNode() {
property_editor->set_undo_redo(&editor_data.get_undo_redo());
connections_dock = memnew( ConnectionsDock(this) );
connections_dock->set_undoredo(&editor_data.get_undo_redo());
dock_slot[DOCK_SLOT_RIGHT_BL]->add_child(connections_dock);
scenes_dock = memnew( ScenesDock(this) );
scenes_dock->set_name(TTR("FileSystem"));
scenes_dock->set_use_thumbnails(int(EditorSettings::get_singleton()->get("file_dialog/display_mode"))==EditorFileDialog::DISPLAY_THUMBNAILS);
dock_slot[DOCK_SLOT_LEFT_BR]->add_child(scenes_dock);
dock_slot[DOCK_SLOT_LEFT_UR]->add_child(scenes_dock);
//prop_pallete->add_child(scenes_dock);
scenes_dock->connect("open",this,"open_request");
scenes_dock->connect("instance",this,"_instance_request");