From fe5f0bc196038f979d5538854f546a847733a88d Mon Sep 17 00:00:00 2001 From: Relintai Date: Wed, 15 Jun 2022 17:56:14 +0200 Subject: [PATCH] Det anchors properly,a nd connect gui_input In PolygonEditor. --- .../editor/widgets/polygon_edit/polygon_editor.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/modules/material_maker/editor/widgets/polygon_edit/polygon_editor.cpp b/modules/material_maker/editor/widgets/polygon_edit/polygon_editor.cpp index f157f098f..92f793394 100644 --- a/modules/material_maker/editor/widgets/polygon_edit/polygon_editor.cpp +++ b/modules/material_maker/editor/widgets/polygon_edit/polygon_editor.cpp @@ -80,6 +80,7 @@ void PolygonEditor::_on_resize() { } PolygonEditor::PolygonEditor() { + set_anchors_and_margins_preset(PRESET_WIDE, PRESET_MODE_MINSIZE, 10); } PolygonEditor::~PolygonEditor() { @@ -87,6 +88,7 @@ PolygonEditor::~PolygonEditor() { void PolygonEditor::_notification(int p_what) { if (p_what == NOTIFICATION_POSTINITIALIZE) { + connect("gui_input", this, "_on_PolygonEditor_gui_input"); update_controls(); } }