From ea63a7448e729090b57fc6c77d4e790cc2df3055 Mon Sep 17 00:00:00 2001 From: AzaezelX Date: Fri, 29 Dec 2023 12:15:30 -0600 Subject: [PATCH] expose guiwindowctrl resize margin to script also up the default to 5 pixels --- Engine/source/gui/containers/guiWindowCtrl.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Engine/source/gui/containers/guiWindowCtrl.cpp b/Engine/source/gui/containers/guiWindowCtrl.cpp index 2da707a60..069064355 100644 --- a/Engine/source/gui/containers/guiWindowCtrl.cpp +++ b/Engine/source/gui/containers/guiWindowCtrl.cpp @@ -79,7 +79,7 @@ GuiWindowCtrl::GuiWindowCtrl() mResizeEdge(edgeNone), mResizeHeight(true), mCanMove(true), - mResizeMargin(2.f), + mResizeMargin(5.f), mCanClose(true), mCanMinimize(true), mCanMaximize(true), @@ -143,6 +143,8 @@ void GuiWindowCtrl::initPersistFields() "Whether the window can be resized horizontally." ); addField( "resizeHeight", TypeBool, Offset( mResizeHeight, GuiWindowCtrl ), "Whether the window can be resized vertically." ); + addField("resizeMargin", TypeF32, Offset(mResizeMargin, GuiWindowCtrl), + "Margin along the window edge to allow grabbing."); addField( "canMove", TypeBool, Offset( mCanMove, GuiWindowCtrl ), "Whether the window can be moved by dragging its titlebar." ); addField( "canClose", TypeBool, Offset( mCanClose, GuiWindowCtrl ),