summaryrefslogtreecommitdiff
path: root/tools/editor
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <remi@verschelde.fr>2016-09-18 20:06:10 +0200
committerGitHub <noreply@github.com>2016-09-18 20:06:10 +0200
commitcfa868e9000e4c0eccfb3882626da007fd814cad (patch)
tree1e2d9de876cee264a600d145d93da4be2ff8dce5 /tools/editor
parent0e962311be7fa5565a456ecd328202c2d6f6ca13 (diff)
parent7904b2b4050dfc26db330da8c603d64bed462dc2 (diff)
Merge pull request #6525 from vnen/plugin-bottom-show-hide
Expose bottom panel show/hide for plugins
Diffstat (limited to 'tools/editor')
-rw-r--r--tools/editor/editor_plugin.cpp13
-rw-r--r--tools/editor/editor_plugin.h3
2 files changed, 16 insertions, 0 deletions
diff --git a/tools/editor/editor_plugin.cpp b/tools/editor/editor_plugin.cpp
index 42403cdb31..4b82d5e59c 100644
--- a/tools/editor/editor_plugin.cpp
+++ b/tools/editor/editor_plugin.cpp
@@ -320,6 +320,16 @@ Control *EditorPlugin::get_base_control() {
return EditorNode::get_singleton()->get_gui_base();
}
+void EditorPlugin::make_bottom_panel_item_visible(Control * p_item) {
+
+ EditorNode::get_singleton()->make_bottom_panel_item_visible(p_item);
+}
+
+void EditorPlugin::hide_bottom_panel() {
+
+ EditorNode::get_singleton()->hide_bottom_panel();
+}
+
void EditorPlugin::inspect_object(Object *p_obj,const String& p_for_property) {
EditorNode::get_singleton()->push_item(p_obj,p_for_property);
@@ -352,6 +362,9 @@ void EditorPlugin::_bind_methods() {
ObjectTypeDB::bind_method(_MD("inspect_object","object","for_property"),&EditorPlugin::inspect_object,DEFVAL(String()));
ObjectTypeDB::bind_method(_MD("update_canvas"),&EditorPlugin::update_canvas);
+ ObjectTypeDB::bind_method(_MD("make_bottom_panel_item_visible","item:Control"), &EditorPlugin::make_bottom_panel_item_visible);
+ ObjectTypeDB::bind_method(_MD("hide_bottom_panel"), &EditorPlugin::hide_bottom_panel);
+
ObjectTypeDB::bind_method(_MD("get_base_control:Control"),&EditorPlugin::get_base_control);
ObjectTypeDB::bind_method(_MD("get_undo_redo:UndoRedo"),&EditorPlugin::_get_undo_redo);
ObjectTypeDB::bind_method(_MD("get_selection:EditorSelection"),&EditorPlugin::get_selection);
diff --git a/tools/editor/editor_plugin.h b/tools/editor/editor_plugin.h
index b4cf821887..2700c49a6c 100644
--- a/tools/editor/editor_plugin.h
+++ b/tools/editor/editor_plugin.h
@@ -131,6 +131,9 @@ public:
Control *get_base_control();
+ void make_bottom_panel_item_visible(Control *p_item);
+ void hide_bottom_panel();
+
void add_import_plugin(const Ref<EditorImportPlugin>& p_editor_import);
void remove_import_plugin(const Ref<EditorImportPlugin>& p_editor_import);