mirror of
https://github.com/tiennm99/godot.git
synced 2026-07-06 21:13:12 +00:00
Remove set_area_as_parent_rect and replace it by set_anchors_and_margins_preset(PRESET_WIDE)
This commit is contained in:
committed by
Gilles Roudiere
parent
92f062696a
commit
05bb8e0c10
@@ -241,7 +241,7 @@ MeshLibraryEditor::MeshLibraryEditor(EditorNode *p_editor) {
|
||||
file->connect("file_selected", this, "_import_scene_cbk");
|
||||
|
||||
Panel *panel = memnew(Panel);
|
||||
panel->set_area_as_parent_rect();
|
||||
panel->set_anchors_and_margins_preset(Control::PRESET_WIDE);
|
||||
add_child(panel);
|
||||
MenuButton *options = memnew(MenuButton);
|
||||
panel->add_child(options);
|
||||
@@ -289,7 +289,7 @@ MeshLibraryEditorPlugin::MeshLibraryEditorPlugin(EditorNode *p_node) {
|
||||
theme_editor = memnew(MeshLibraryEditor(p_node));
|
||||
|
||||
p_node->get_viewport()->add_child(theme_editor);
|
||||
theme_editor->set_area_as_parent_rect();
|
||||
theme_editor->set_anchors_and_margins_preset(Control::PRESET_WIDE);
|
||||
theme_editor->set_anchor(MARGIN_BOTTOM, Control::ANCHOR_BEGIN);
|
||||
theme_editor->set_end(Point2(0, 22));
|
||||
theme_editor->hide();
|
||||
|
||||
Reference in New Issue
Block a user