summaryrefslogtreecommitdiff
path: root/editor/editor_node.h
diff options
context:
space:
mode:
Diffstat (limited to 'editor/editor_node.h')
-rw-r--r--editor/editor_node.h81
1 files changed, 24 insertions, 57 deletions
diff --git a/editor/editor_node.h b/editor/editor_node.h
index f774fa0a2e..7aa060fe14 100644
--- a/editor/editor_node.h
+++ b/editor/editor_node.h
@@ -32,14 +32,15 @@
#define EDITOR_NODE_H
#include "core/print_string.h"
+#include "editor/audio_stream_preview.h"
#include "editor/connections_dialog.h"
#include "editor/create_dialog.h"
#include "editor/editor_about.h"
#include "editor/editor_data.h"
#include "editor/editor_export.h"
+#include "editor/editor_inspector.h"
#include "editor/editor_log.h"
#include "editor/editor_name_dialog.h"
-#include "editor/editor_path.h"
#include "editor/editor_plugin.h"
#include "editor/editor_resource_preview.h"
#include "editor/editor_run.h"
@@ -52,6 +53,7 @@
#include "editor/filesystem_dock.h"
#include "editor/groups_editor.h"
#include "editor/import_dock.h"
+#include "editor/inspector_dock.h"
#include "editor/node_dock.h"
#include "editor/pane_drag.h"
#include "editor/progress_dialog.h"
@@ -142,22 +144,10 @@ private:
EDIT_REVERT,
TOOLS_ORPHAN_RESOURCES,
TOOLS_CUSTOM,
- RESOURCE_NEW,
- RESOURCE_LOAD,
RESOURCE_SAVE,
RESOURCE_SAVE_AS,
- RESOURCE_UNREF,
- RESOURCE_COPY,
- RESOURCE_PASTE,
- OBJECT_COPY_PARAMS,
- OBJECT_PASTE_PARAMS,
- OBJECT_UNIQUE_RESOURCES,
- OBJECT_REQUEST_HELP,
RUN_PLAY,
- COLLAPSE_ALL,
- EXPAND_ALL,
-
RUN_STOP,
RUN_PLAY_SCENE,
RUN_PLAY_NATIVE,
@@ -181,7 +171,7 @@ private:
SETTINGS_LAYOUT_DEFAULT,
SETTINGS_MANAGE_EXPORT_TEMPLATES,
SETTINGS_PICK_MAIN_SCENE,
- SETTINGS_TOGGLE_FULLSCREN,
+ SETTINGS_TOGGLE_FULLSCREEN,
SETTINGS_HELP,
SCENE_TAB_CLOSE,
@@ -195,8 +185,6 @@ private:
IMPORT_PLUGIN_BASE = 100,
- OBJECT_METHOD_BASE = 500,
-
TOOL_MENU_BASE = 1000
};
@@ -247,7 +235,6 @@ private:
PopupMenu *tool_menu;
ToolButton *export_button;
ToolButton *prev_scene;
- MenuButton *object_menu;
ToolButton *play_button;
MenuButton *native_play_button;
ToolButton *pause_button;
@@ -264,24 +251,13 @@ private:
Ref<Theme> theme;
PopupMenu *recent_scenes;
- Button *property_back;
- Button *property_forward;
SceneTreeDock *scene_tree_dock;
- PropertyEditor *property_editor;
- Button *property_editable_warning;
- AcceptDialog *property_editable_warning_dialog;
- void _property_editable_warning_pressed();
+ InspectorDock *inspector_dock;
NodeDock *node_dock;
ImportDock *import_dock;
- VBoxContainer *prop_editor_vb;
FileSystemDock *filesystem_dock;
EditorRunNative *run_native;
- HBoxContainer *search_bar;
- LineEdit *search_box;
-
- CreateDialog *create_dialog;
-
ConfirmationDialog *confirmation;
ConfirmationDialog *save_confirmation;
ConfirmationDialog *import_confirmation;
@@ -314,11 +290,6 @@ private:
String defer_export_platform;
bool defer_export_debug;
Node *_last_instanced_scene;
- EditorPath *editor_path;
- ToolButton *resource_new_button;
- ToolButton *resource_load_button;
- MenuButton *resource_save_button;
- MenuButton *editor_history_menu;
EditorLog *log;
CenterContainer *tabs_center;
@@ -329,6 +300,7 @@ private:
Vector<ToolButton *> main_editor_buttons;
Vector<EditorPlugin *> editor_table;
+ AudioStreamPreviewGenerator *preview_gen;
ProgressDialog *progress_dialog;
BackgroundProgress *progress_hb;
@@ -405,7 +377,11 @@ private:
PanelContainer *bottom_panel;
HBoxContainer *bottom_panel_hb;
+ HBoxContainer *bottom_panel_hb_editors;
VBoxContainer *bottom_panel_vb;
+ ToolButton *bottom_panel_raise;
+
+ void _bottom_panel_raise_toggled(bool);
EditorInterface *editor_interface;
@@ -422,23 +398,12 @@ private:
void _dialog_display_load_error(String p_file, Error p_error);
int current_option;
- void _resource_created();
- void _resource_selected(const RES &p_res, const String &p_property = "");
void _menu_option(int p_option);
void _menu_confirm_current();
void _menu_option_confirm(int p_option, bool p_confirmed);
void _tool_menu_option(int p_idx);
void _update_debug_options();
- void _property_editor_forward();
- void _property_editor_back();
-
- void _menu_collapseall();
- void _menu_expandall();
-
- void _select_history(int p_idx);
- void _prepare_history();
-
void _fs_changed();
void _resources_reimported(const Vector<String> &p_resources);
void _sources_changed(bool p_exist);
@@ -462,9 +427,6 @@ private:
void _instance_request(const Vector<String> &p_files);
- void _property_keyed(const String &p_keyed, const Variant &p_value, bool p_advance);
- void _transform_keyed(Object *sp, const String &p_sub, const Transform &p_key);
-
void _hide_top_editors();
void _display_top_editors(bool p_display);
void _set_top_editors(Vector<EditorPlugin *> p_editor_plugins_over);
@@ -578,8 +540,6 @@ private:
void _update_layouts_menu();
void _layout_menu_option(int p_id);
- void _toggle_search_bar(bool p_pressed);
- void _clear_search_box();
void _clear_undo_history();
void _update_addon_config();
@@ -640,8 +600,9 @@ public:
EditorPluginList *get_editor_plugins_over() { return editor_plugins_over; }
EditorPluginList *get_editor_plugins_force_over() { return editor_plugins_force_over; }
EditorPluginList *get_editor_plugins_force_input_forwarding() { return editor_plugins_force_input_forwarding; }
- PropertyEditor *get_property_editor() { return property_editor; }
- VBoxContainer *get_property_editor_vb() { return prop_editor_vb; }
+ EditorInspector *get_inspector() { return inspector_dock->get_inspector(); }
+ Container *get_inspector_dock_addon_area() { return inspector_dock->get_addon_area(); }
+ ScriptCreateDialog *get_script_create_dialog() { return scene_tree_dock->get_script_create_dialog(); }
ProjectSettingsEditor *get_project_settings() { return project_settings; }
@@ -663,8 +624,8 @@ public:
bool is_addon_plugin_enabled(const String &p_addon) const;
void edit_node(Node *p_node);
- void edit_resource(const Ref<Resource> &p_resource);
- void open_resource(const String &p_type = "");
+ void edit_resource(const Ref<Resource> &p_resource) { inspector_dock->edit_resource(p_resource); };
+ void open_resource(const String &p_type) { inspector_dock->open_resource(p_type); };
void save_resource_in_path(const Ref<Resource> &p_resource, const String &p_path);
void save_resource(const Ref<Resource> &p_resource);
@@ -678,7 +639,9 @@ public:
static HBoxContainer *get_menu_hb() { return singleton->menu_hb; }
- void push_item(Object *p_object, const String &p_property = "");
+ void push_item(Object *p_object, const String &p_property = "", bool p_inspector_only = false);
+ void edit_item(Object *p_object);
+ bool item_has_editor(Object *p_object);
void open_request(const String &p_path);
@@ -713,6 +676,7 @@ public:
FileSystemDock *get_filesystem_dock();
ImportDock *get_import_dock();
SceneTreeDock *get_scene_tree_dock();
+ InspectorDock *get_inspector_dock();
static UndoRedo *get_undo_redo() { return &singleton->editor_data.get_undo_redo(); }
EditorSelection *get_editor_selection() { return editor_selection; }
@@ -726,6 +690,7 @@ public:
Ref<Theme> get_editor_theme() const { return theme; }
+ void show_accept(const String &p_text, const String &p_title);
void show_warning(const String &p_text, const String &p_title = "Warning!");
Error export_preset(const String &p_preset, const String &p_path, bool p_debug, const String &p_password, bool p_quit_after = false);
@@ -759,8 +724,6 @@ public:
void save_layout();
- void update_keying();
-
void open_export_template_manager();
void reload_scene(const String &p_path);
@@ -785,6 +748,10 @@ public:
void dim_editor(bool p_dimming);
+ void edit_current() { _edit_current(); };
+
+ void update_keying() const { inspector_dock->update_keying(); };
+
EditorNode();
~EditorNode();
void get_singleton(const char *arg1, bool arg2);