Extract editor main screen

This commit is contained in:
kit 2024-08-19 18:08:31 -04:00
parent d0dc3896ad
commit 5e1c9d68aa
27 changed files with 484 additions and 354 deletions

View file

@ -44,6 +44,7 @@
#include "editor/editor_command_palette.h"
#include "editor/editor_help_search.h"
#include "editor/editor_interface.h"
#include "editor/editor_main_screen.h"
#include "editor/editor_node.h"
#include "editor/editor_paths.h"
#include "editor/editor_script.h"
@ -4612,7 +4613,7 @@ ScriptEditorPlugin::ScriptEditorPlugin() {
Ref<Shortcut> make_floating_shortcut = ED_SHORTCUT_AND_COMMAND("script_editor/make_floating", TTR("Make Floating"));
window_wrapper->set_wrapped_control(script_editor, make_floating_shortcut);
EditorNode::get_singleton()->get_main_screen_control()->add_child(window_wrapper);
EditorNode::get_singleton()->get_editor_main_screen()->get_control()->add_child(window_wrapper);
window_wrapper->set_v_size_flags(Control::SIZE_EXPAND_FILL);
window_wrapper->hide();
window_wrapper->connect("window_visibility_changed", callable_mp(this, &ScriptEditorPlugin::_window_visibility_changed));