UDraggableWindow
#include <DraggableWindowUMG/DraggableWindow.h>class UDraggableWindowDefined in DraggableWindow.h:18
Inherits:
UUserWidget
Inheritance diagram
Section titled “Inheritance diagram”---
config:
class:
hideEmptyMembersBox: true
---
classDiagram
class UDraggableWindow["UDraggableWindow"]
class UUserWidget["UUserWidget"]
UUserWidget <|-- UDraggableWindow
Collaboration diagram
Section titled “Collaboration diagram”---
config:
class:
hideEmptyMembersBox: true
---
classDiagram
class UDraggableWindow["UDraggableWindow"]
class EOperatingSystemWindowStartupState["EOperatingSystemWindowStartupState"]
UDraggableWindow ..> EOperatingSystemWindowStartupState
Class detail
Section titled “Class detail”---
config:
class:
hideEmptyMembersBox: true
---
classDiagram
class UDraggableWindow {
+UDraggableWindow(const FObjectInitializer &ObjectInitializer
+SetWindowTitle(const FText &NewTitle)
+CloseWindow()
+GetWindowPosition() const TOptional< FVector2D >
+AddContentWidgetClass(TSubclassOf< class UUserWidget > InWidgetCl
+AddContentWidget(class UUserWidget *InWidget, const bool bCl
+ToggleMaximize() bool
+CenterWindowToScreen()
+UpdateWindowSize(const FVector2D &InNewSize) bool
+GetChildWidget(UUserWidget *&OutChildWidget) const bool
+SetPosition(const FVector2D NewPosition)
+IsMaximized() const bool
+CreateDraggableWindow(const UObject *WorldContextObject, TSubclas UDraggableWindow() *
+CreateDraggableWindowFromWidget(const UObject *WorldContextObject, TSubclas UDraggableWindow() *
+bEnableDrag : uint8
+bEnableResizing : uint8
+bEnableMaximizing : uint8
+MaximizeTaskbarOffset : float
+ResizeMinWidth : float
+ResizeMaxWidth : float
+ResizeMinHeight : float
+ResizeMaxHeight : float
+DragKey : FKey
+WindowTitleBorderWidget : UBorder *
+ChildWidgetCanvas : UCanvasPanel *
+ResizeAreaWidget : UBorder *
+ParentSlot : UCanvasPanelSlot *
+ChildWidget : UUserWidget *
+bIsMaximized : uint8
+LastMousePosition : FVector2D
+PreResizeAlignment : FVector2D
+PreResizeOffset : FVector2D
+PreDragSize : FVector2D
+StartSize : FVector2D
+CurrentZOrder : int32
+PreFullscreenAnchors : FAnchors
+PreFullscreenMargin : FMargin
+StartupState : EOperatingSystemWindowStartupState()
+NativeConstruct() override
+NativeOnMouseMove(const FGeometry &InGeometry, const FPointer FReply
+NativeOnMouseButtonUp(const FGeometry &InGeometry, const FPointer FReply
+OnCloseWindow()
+K2_OnCloseWindow()
+K2_OnSetWindowTitle(const FText &NewWindowTitle)
+K2_OnContentWidgetAdded(const UUserWidget *AddedUserWidget)
+K2_OnDragStart(const FPointerEvent &InMouseEvent)
+K2_OnResizeStart(const FPointerEvent &InMouseEvent)
+K2_StartMinimized()
+K2_OnWindowMaximizeToggled()
+Internal_OnMouseButtonUpEvent()
+Internal_DetermineNewSize(const FVector2D &InDelta) const FVector2D
+Internal_OnMouseButtonUp_WindowTitleBorder(FGeometry InGeometry, const FPointerEvent & FEventReply
+Internal_OnMouseButtonDown_WindowTitleBorder(FGeometry InGeometry, const FPointerEvent & FEventReply
+Internal_OnMouseButtonDown_ResizeArea(FGeometry InGeometry, const FPointerEvent & FEventReply
+Internal_AddContentWidget(const bool bClearPrevious)
}
User widget class that represents a draggable window widget. It allows users to create draggable windows with optional resizing and maximizing features.
Public Methods
Section titled “Public Methods”| Return | Name | Description |
|---|---|---|
UDraggableWindow | ||
void | SetWindowTitle inline | Sets the title of the window. |
void | CloseWindow | Closes the draggable window. |
TOptional< FVector2D > | GetWindowPosition const | Get the position of the draggable window. |
void | AddContentWidgetClass | Adds a content to this window. A new widget is created from the given class. |
void | AddContentWidget | Adds a content to this window. |
bool | ToggleMaximize | Maximizes or restores this window. |
void | CenterWindowToScreen | Center this window to screen. Will not work if window is maximized. |
bool | UpdateWindowSize | Updates the size of the draggable window. |
bool | GetChildWidget const | Returns the child widget (if any) of this draggable window. If the Return Value is true, then OutChildWidget will be valid. |
void | SetPosition | Set the position of the window to the specified coordinates. |
bool | IsMaximized const inline | Returns whether the window is currently maximized. |
UDraggableWindow
Section titled “UDraggableWindow”UDraggableWindow(const FObjectInitializer & ObjectInitializer)Defined in DraggableWindow.h:206
References
Section titled “References”bEnableDragbEnableMaximizingbEnableResizingbIsMaximizedCurrentZOrderDragKeyLastMousePositionMaximizeTaskbarOffsetPreDragSizePreResizeAlignmentPreResizeOffsetResizeMaxHeightResizeMaxWidthResizeMinHeightResizeMinWidthStartSize
SetWindowTitle
Section titled “SetWindowTitle”inline
inline void SetWindowTitle(const FText & NewTitle)Defined in DraggableWindow.h:286 Sets the title of the window.
Parameters
Section titled “Parameters”NewTitleThe new title of the window.
CloseWindow
Section titled “CloseWindow”void CloseWindow()Defined in DraggableWindow.h:300 Closes the draggable window.
This method is used to close the draggable window. It performs the following steps:
-
Calls the K2_OnCloseWindow() function.
-
Calls the OnCloseWindow() function.
-
Clears the children of the ChildWidgetCanvas if it is valid.
-
Removes the draggable window from its parent.
References
Section titled “References”GetWindowPosition
Section titled “GetWindowPosition”const
TOptional< FVector2D > GetWindowPosition() constDefined in DraggableWindow.h:310 Get the position of the draggable window.
This method retrieves the position of the draggable window. It checks if the ParentSlot is valid, and if so, it calls GetPosition() on the ParentSlot to get the window position. If the ParentSlot is not valid, it returns an empty TOptional<FVector2D> object.
Returns
Section titled “Returns”The position of the draggable window, or an empty TOptional<FVector2D> object if the ParentSlot is not valid.
References
Section titled “References”AddContentWidgetClass
Section titled “AddContentWidgetClass”void AddContentWidgetClass(TSubclassOf< class UUserWidget > InWidgetClass, const bool bClearPrevious = true)Defined in DraggableWindow.h:320 Adds a content to this window. A new widget is created from the given class.
@See AddContentWidget().
Parameters
Section titled “Parameters”-
InWidgetClass[TSubclassOf<class UUserWidget>] Widget class to use as content for this window. -
bClearPrevious[const bool] Should we clear all existing children from Child Widget Canvas? Recommended to keep this on.
References
Section titled “References”AddContentWidget
Section titled “AddContentWidget”void AddContentWidget(class UUserWidget * InWidget, const bool bClearPrevious = true)Defined in DraggableWindow.h:330 Adds a content to this window.
@See AddContentWidgetClass().
Parameters
Section titled “Parameters”-
InWidget[class UUserWidget*] Reference to an existing content. -
bClearPrevious[const bool] Should we clear all existing children from Child Widget Canvas? Recommended to keep this on.
Referenced by
Section titled “Referenced by”References
Section titled “References”ToggleMaximize
Section titled “ToggleMaximize”bool ToggleMaximize()Defined in DraggableWindow.h:338 Maximizes or restores this window.
Returns
Section titled “Returns”[bool] True if the window was maximized or restored.
Referenced by
Section titled “Referenced by”References
Section titled “References”bEnableMaximizingbEnableResizingbIsMaximizedK2_OnWindowMaximizeToggledMaximizeTaskbarOffsetParentSlotPreFullscreenAnchorsPreFullscreenMargin
CenterWindowToScreen
Section titled “CenterWindowToScreen”void CenterWindowToScreen()Defined in DraggableWindow.h:344 Center this window to screen. Will not work if window is maximized.
Referenced by
Section titled “Referenced by”References
Section titled “References”UpdateWindowSize
Section titled “UpdateWindowSize”bool UpdateWindowSize(const FVector2D & InNewSize)Defined in DraggableWindow.h:353 Updates the size of the draggable window.
Parameters
Section titled “Parameters”InNewSize[const FVector2D&] New size to change to.
Returns
Section titled “Returns”[bool] True if the size was changed successfully.
Referenced by
Section titled “Referenced by”References
Section titled “References”GetChildWidget
Section titled “GetChildWidget”const
bool GetChildWidget(UUserWidget *& OutChildWidget) constDefined in DraggableWindow.h:362 Returns the child widget (if any) of this draggable window. If the Return Value is true, then OutChildWidget will be valid.
Parameters
Section titled “Parameters”OutChildWidget[UUserWidget*&] Reference to the child widget created by this window.
Returns
Section titled “Returns”[bool] True if a valid child widget is available.
References
Section titled “References”SetPosition
Section titled “SetPosition”void SetPosition(const FVector2D NewPosition)Defined in DraggableWindow.h:373 Set the position of the window to the specified coordinates.
Parameters
Section titled “Parameters”NewPositionThe new position of the window as a 2D vector (FVector2D).
References
Section titled “References”IsMaximized
Section titled “IsMaximized”const inline
inline bool IsMaximized() constDefined in DraggableWindow.h:447 Returns whether the window is currently maximized.
Returns
Section titled “Returns”True if the window is maximized, false otherwise.
Public Static Methods
Section titled “Public Static Methods”| Return | Name | Description |
|---|---|---|
UDraggableWindow * | CreateDraggableWindow static | public static UDraggableWindow::CreateDraggableWindow Creates a draggable window widget instance from given widget class. You can optionally add a child widget also which will be the content for this window. |
UDraggableWindow * | CreateDraggableWindowFromWidget static | public static UDraggableWindow::CreateDraggableWindowFromWidget Creates a draggable window widget instance from given widget class. You can optionally add a child widget also which will be the content for this window. |
CreateDraggableWindow
Section titled “CreateDraggableWindow”static
static UDraggableWindow * CreateDraggableWindow(const UObject * WorldContextObject, TSubclassOf< UDraggableWindow > WindowClass, TSubclassOf< UUserWidget > ChildWidgetClass, const FVector2D StartSize = FVector2D(640.f, 480.f), const FVector2D ResizeWidth = FVector2D(640.f, 480.f), const FVector2D ResizeHeight = FVector2D(0.f, 0.f), const bool bCenterToScreen = true, const bool bCanDrag = true, const bool bCanResize = true, const EOperatingSystemWindowStartupState WindowStartupState = EOperatingSystemWindowStartupState::Default)Defined in DraggableWindow.h:224 public static UDraggableWindow::CreateDraggableWindow Creates a draggable window widget instance from given widget class. You can optionally add a child widget also which will be the content for this window.
Parameters
Section titled “Parameters”-
WorldContextObject[const UObject*] World context object. -
WindowClass[TSubclassOf<UDraggableWindow>] Window widget class to create. -
ChildWidgetClass[TSubclassOf<UUserWidget>] [OPTIONAL] Child content class to add to the newly created window widget. -
StartSize[const FVector2D] What size should we start the window. -
ResizeWidth[const FVector2D] Min (X) and Max (Y) width of this window. -
ResizeHeight[const FVector2D] Min (X) and Max (Y) height of this window. -
bCenterToScreen[const bool] Should we center the window to the player screen. -
bCanDrag[const bool] Determines if the window can be dragged. -
bCanResize[const bool] Determines if the window can be resized (You must have a Border widget with Is Variable set to true and variable name set to ResizeAreaWidget). -
WindowStartupState[const EOperatingSystemWindowStartupState] Window state to apply.
Returns
Section titled “Returns”[UDraggableWindow*] Newly created window widget.
References
Section titled “References”CreateDraggableWindowFromWidgetPRINT_ERRStartSize
CreateDraggableWindowFromWidget
Section titled “CreateDraggableWindowFromWidget”static
static UDraggableWindow * CreateDraggableWindowFromWidget(const UObject * WorldContextObject, TSubclassOf< UDraggableWindow > WindowClass, UUserWidget * NewChildWidget, const FVector2D StartSize = FVector2D(640.f, 480.f), const FVector2D ResizeWidth = FVector2D(640.f, 480.f), const FVector2D ResizeHeight = FVector2D(0.f, 0.f), const bool bCenterToScreen = true, const bool bCanDrag = true, const bool bCanResize = true, const EOperatingSystemWindowStartupState WindowStartupState = EOperatingSystemWindowStartupState::Default)Defined in DraggableWindow.h:249 public static UDraggableWindow::CreateDraggableWindowFromWidget Creates a draggable window widget instance from given widget class. You can optionally add a child widget also which will be the content for this window.
Parameters
Section titled “Parameters”-
WorldContextObject[const UObject*] World context object. -
WindowClass[TSubclassOf<UDraggableWindow>] Window widget class to create. -
NewChildWidget[UUserWidget*] [OPTIONAL] Child content to add to the newly created window widget. -
StartSize[const FVector2D] What size should we start the window. -
ResizeWidth[const FVector2D] Min (X) and Max (Y) width of this window. -
ResizeHeight[const FVector2D] Min (X) and Max (Y) height of this window. -
bCenterToScreen[const bool] Should we center the window to the player screen. -
bCanDrag[const bool] Determines if the window can be dragged. -
bCanResize[const bool] Determines if the window can be resized (You must have a Border widget with Is Variable set to true and variable name set to ResizeAreaWidget). -
WindowStartupState[const EOperatingSystemWindowStartupState] Window state to apply.
Returns
Section titled “Returns”[UDraggableWindow*] Newly created window widget.
Referenced by
Section titled “Referenced by”References
Section titled “References”AddContentWidgetbEnableDragbEnableResizingPRINT_ERRResizeMaxHeightResizeMaxWidthResizeMinHeightResizeMinWidthStartSizeStartupState
Protected Attributes
Section titled “Protected Attributes”| Return | Name | Description |
|---|---|---|
uint8 | bEnableDrag | |
uint8 | bEnableResizing | |
uint8 | bEnableMaximizing | |
float | MaximizeTaskbarOffset | |
float | ResizeMinWidth | |
float | ResizeMaxWidth | |
float | ResizeMinHeight | |
float | ResizeMaxHeight | |
FKey | DragKey | |
UBorder * | WindowTitleBorderWidget | A pointer to a UBorder widget that represents the window title border. |
UCanvasPanel * | ChildWidgetCanvas | Pointer to a UCanvasPanel object representing the child widget canvas of the draggable window. |
UBorder * | ResizeAreaWidget | Represents the resize area widget of the draggable window widget. |
UCanvasPanelSlot * | ParentSlot | A canvas panel slot is responsible for defining the layout and positioning of a widget within a canvas panel. The ParentSlot variable is used to access and manipulate the properties of the canvas panel slot associated with the parent widget. |
UUserWidget * | ChildWidget | Represents a child widget of a draggable window. |
uint8 | bIsMaximized | Flag indicating if the draggable window is maximized. |
FVector2D | LastMousePosition | The last recorded mouse position. |
FVector2D | PreResizeAlignment | A 2D vector that represents the alignment of a draggable window before resizing. |
FVector2D | PreResizeOffset | Offset value used for pre-resizing calculations. |
FVector2D | PreDragSize | PreDragSize is a variable of type FVector2D. It represents the size of the draggable window before it is dragged. |
FVector2D | StartSize | Represents the starting size of the draggable window. |
int32 | CurrentZOrder | The current Z-order of the window. |
FAnchors | PreFullscreenAnchors | The PreFullscreenAnchors variable is of type FAnchors and is used to store the original anchors of a draggable window before it enters fullscreen mode. |
FMargin | PreFullscreenMargin | This variable is of type FMargin, which is a struct that represents a rectangle’s margin. It is used to store the top, left, bottom, and right margins of the window before it enters full screen mode. |
EOperatingSystemWindowStartupState | StartupState | Enum representing the startup state of an operating system window. |
bEnableDrag
Section titled “bEnableDrag”uint8 bEnableDragDefined in DraggableWindow.h:26
Referenced by
Section titled “Referenced by”bEnableResizing
Section titled “bEnableResizing”uint8 bEnableResizingDefined in DraggableWindow.h:30
Referenced by
Section titled “Referenced by”bEnableMaximizing
Section titled “bEnableMaximizing”uint8 bEnableMaximizingDefined in DraggableWindow.h:34
Referenced by
Section titled “Referenced by”MaximizeTaskbarOffset
Section titled “MaximizeTaskbarOffset”float MaximizeTaskbarOffsetDefined in DraggableWindow.h:38
Referenced by
Section titled “Referenced by”ResizeMinWidth
Section titled “ResizeMinWidth”float ResizeMinWidthDefined in DraggableWindow.h:42
Referenced by
Section titled “Referenced by”ResizeMaxWidth
Section titled “ResizeMaxWidth”float ResizeMaxWidthDefined in DraggableWindow.h:46
Referenced by
Section titled “Referenced by”ResizeMinHeight
Section titled “ResizeMinHeight”float ResizeMinHeightDefined in DraggableWindow.h:50
Referenced by
Section titled “Referenced by”ResizeMaxHeight
Section titled “ResizeMaxHeight”float ResizeMaxHeightDefined in DraggableWindow.h:54
Referenced by
Section titled “Referenced by”DragKey
Section titled “DragKey”FKey DragKeyDefined in DraggableWindow.h:58
Referenced by
Section titled “Referenced by”Internal_OnMouseButtonDown_ResizeAreaInternal_OnMouseButtonDown_WindowTitleBorderNativeOnMouseButtonUpNativeOnMouseMoveUDraggableWindow
WindowTitleBorderWidget
Section titled “WindowTitleBorderWidget”UBorder * WindowTitleBorderWidgetDefined in DraggableWindow.h:71 A pointer to a UBorder widget that represents the window title border.
This variable is used in the DraggableWindow class to reference the UBorder widget that represents the window title border. The UBorder widget is a visual element that can be customized to display the title of the window and provide a draggable area for the window.
See also: DraggableWindow
Referenced by
Section titled “Referenced by”ChildWidgetCanvas
Section titled “ChildWidgetCanvas”UCanvasPanel * ChildWidgetCanvasDefined in DraggableWindow.h:79 Pointer to a UCanvasPanel object representing the child widget canvas of the draggable window.
Referenced by
Section titled “Referenced by”ResizeAreaWidget
Section titled “ResizeAreaWidget”UBorder * ResizeAreaWidgetDefined in DraggableWindow.h:88 Represents the resize area widget of the draggable window widget.
The resize area widget is used to specify the area where the user can click and drag to resize the window. If this widget is null, resizing will not be enabled for the window.
Referenced by
Section titled “Referenced by”ParentSlot
Section titled “ParentSlot”UCanvasPanelSlot * ParentSlotDefined in DraggableWindow.h:97 A canvas panel slot is responsible for defining the layout and positioning of a widget within a canvas panel. The ParentSlot variable is used to access and manipulate the properties of the canvas panel slot associated with the parent widget.
Referenced by
Section titled “Referenced by”CenterWindowToScreenGetWindowPositionInternal_DetermineNewSizeInternal_OnMouseButtonDown_ResizeAreaInternal_OnMouseButtonUpEventNativeConstructNativeOnMouseMoveSetPositionToggleMaximizeUpdateWindowSize
ChildWidget
Section titled “ChildWidget”UUserWidget * ChildWidgetDefined in DraggableWindow.h:106 Represents a child widget of a draggable window.
This variable is of type UUserWidget*. It represents a child widget that can be attached to a draggable window. The child widget will be displayed within the draggable window and can be manipulated along with it.
Referenced by
Section titled “Referenced by”bIsMaximized
Section titled “bIsMaximized”uint8 bIsMaximizedDefined in DraggableWindow.h:126 Flag indicating if the draggable window is maximized.
This flag is used to determine if the draggable window is currently maximized. It is a boolean flag with a width of 1 bit. When the flag is set to true (1), it means that the draggable window is maximized. When the flag is set to false (0), it means that the draggable window is not maximized.
Referenced by
Section titled “Referenced by”LastMousePosition
Section titled “LastMousePosition”FVector2D LastMousePositionDefined in DraggableWindow.h:143 The last recorded mouse position.
This variable stores the last known position of the mouse on the screen. It is of type FVector2D, which represents a 2D vector with X and Y coordinates. The X coordinate represents the horizontal position of the mouse, and the Y coordinate represents the vertical position of the mouse.
To access this variable, use the appropriate getter and setter methods provided by the class or structure that contains it. The methods should be named in accordance with the coding conventions and naming conventions followed in the application.
Referenced by
Section titled “Referenced by”Internal_OnMouseButtonDown_ResizeAreaInternal_OnMouseButtonDown_WindowTitleBorderNativeOnMouseMoveUDraggableWindow
PreResizeAlignment
Section titled “PreResizeAlignment”FVector2D PreResizeAlignmentDefined in DraggableWindow.h:150 A 2D vector that represents the alignment of a draggable window before resizing.
This vector stores the alignment of a draggable window before it is resized. It is used to determine the original position of the window before resizing it.
Referenced by
Section titled “Referenced by”PreResizeOffset
Section titled “PreResizeOffset”FVector2D PreResizeOffsetDefined in DraggableWindow.h:153 Offset value used for pre-resizing calculations.
Referenced by
Section titled “Referenced by”Internal_OnMouseButtonDown_ResizeAreaInternal_OnMouseButtonUpEventNativeOnMouseMoveUDraggableWindow
PreDragSize
Section titled “PreDragSize”FVector2D PreDragSizeDefined in DraggableWindow.h:160 PreDragSize is a variable of type FVector2D. It represents the size of the draggable window before it is dragged.
PreDragSize is typically updated whenever the size of the draggable window changes, but before it is actually dragged. It is useful for keeping track of the previous size of the window.
Referenced by
Section titled “Referenced by”StartSize
Section titled “StartSize”FVector2D StartSizeDefined in DraggableWindow.h:174 Represents the starting size of the draggable window.
This variable is of type FVector2D, which is a structure that holds a 2D vector. The vector represents the width and height of the window.
The StartSize variable is used to define the initial size of the draggable window when it is created. It determines the width and height of the window before any user interaction or resizing occurs.
See also: CreateDraggableWindowFromWidget
Referenced by
Section titled “Referenced by”CurrentZOrder
Section titled “CurrentZOrder”int32 CurrentZOrderDefined in DraggableWindow.h:185 The current Z-order of the window.
The Z-order determines the position of the window relative to other windows in the stacking order. A higher Z-order means the window will be displayed above windows with lower Z-orders.
Referenced by
Section titled “Referenced by”PreFullscreenAnchors
Section titled “PreFullscreenAnchors”FAnchors PreFullscreenAnchorsDefined in DraggableWindow.h:188 The PreFullscreenAnchors variable is of type FAnchors and is used to store the original anchors of a draggable window before it enters fullscreen mode.
Referenced by
Section titled “Referenced by”PreFullscreenMargin
Section titled “PreFullscreenMargin”FMargin PreFullscreenMarginDefined in DraggableWindow.h:191 This variable is of type FMargin, which is a struct that represents a rectangle’s margin. It is used to store the top, left, bottom, and right margins of the window before it enters full screen mode.
Referenced by
Section titled “Referenced by”StartupState
Section titled “StartupState”EOperatingSystemWindowStartupState StartupStateDefined in DraggableWindow.h:202 Enum representing the startup state of an operating system window.
The EOperatingSystemWindowStartupState enumeration represents the possible startup states for an operating system window. It is used to define how a window should behave when it is initially displayed.
See also: CreateDraggableWindowFromWidget
Referenced by
Section titled “Referenced by”Protected Methods
Section titled “Protected Methods”| Return | Name | Description |
|---|---|---|
void | NativeConstruct virtual override | |
FReply | NativeOnMouseMove virtual override | |
FReply | NativeOnMouseButtonUp virtual override | |
void | OnCloseWindow virtual inline | This virtual function is called when the window is being closed. It can be overridden by derived classes to provide custom behavior when the window is closed. |
void | K2_OnCloseWindow | protected UDraggableWindow::K2_OnCloseWindow Event called when this window is closed. C++ implementation calls RemoveFromParent automatically. |
void | K2_OnSetWindowTitle | protected UDraggableWindow::K2_OnSetWindowTitle Event called when a new title is set for this window. |
void | K2_OnContentWidgetAdded | protected UDraggableWindow::K2_OnContentWidgetAdded Event called when a new content is added to this window. |
void | K2_OnDragStart | protected UDraggableWindow::K2_OnDragStart Event called when resizing is started. Only called if Enable Drag is true. |
void | K2_OnResizeStart | protected UDraggableWindow::K2_OnResizeStart Event called when resizing is started. Only called if Enable Resizing is true. |
void | K2_StartMinimized | protected UDraggableWindow::K2_StartMinimized Event called when the window starts minimized. |
void | K2_OnWindowMaximizeToggled | protected UDraggableWindow::K2_OnWindowMaximizeToggled Event called when this window is maximized or restored. |
NativeConstruct
Section titled “NativeConstruct”virtual override
virtual void NativeConstruct() overrideDefined in DraggableWindow.h:261
References
Section titled “References”bEnableResizingCenterWindowToScreenParentSlotPRINT_ERRPRINT_LOGPRINT_WARNResizeAreaWidgetStartMaximizedStartMinimizedStartSizeStartupStateToggleMaximizeUpdateWindowSizeWindowTitleBorderWidget
NativeOnMouseMove
Section titled “NativeOnMouseMove”virtual override
virtual FReply NativeOnMouseMove(const FGeometry & InGeometry, const FPointerEvent & InMouseEvent) overrideDefined in DraggableWindow.h:262
References
Section titled “References”DragKeyInternal_DetermineNewSizeInternal_OnMouseButtonUpEventLastMousePositionParentSlotPreResizeOffset
NativeOnMouseButtonUp
Section titled “NativeOnMouseButtonUp”virtual override
virtual FReply NativeOnMouseButtonUp(const FGeometry & InGeometry, const FPointerEvent & InMouseEvent) overrideDefined in DraggableWindow.h:263
Referenced by
Section titled “Referenced by”References
Section titled “References”OnCloseWindow
Section titled “OnCloseWindow”virtual inline
virtual inline void OnCloseWindow()Defined in DraggableWindow.h:385 This virtual function is called when the window is being closed. It can be overridden by derived classes to provide custom behavior when the window is closed.
Referenced by
Section titled “Referenced by”K2_OnCloseWindow
Section titled “K2_OnCloseWindow”void K2_OnCloseWindow()Defined in DraggableWindow.h:392 protected UDraggableWindow::K2_OnCloseWindow Event called when this window is closed. C++ implementation calls RemoveFromParent automatically.
Referenced by
Section titled “Referenced by”K2_OnSetWindowTitle
Section titled “K2_OnSetWindowTitle”void K2_OnSetWindowTitle(const FText & NewWindowTitle)Defined in DraggableWindow.h:400 protected UDraggableWindow::K2_OnSetWindowTitle Event called when a new title is set for this window.
Parameters
Section titled “Parameters”NewWindowTitle[const FText &] New title.
K2_OnContentWidgetAdded
Section titled “K2_OnContentWidgetAdded”void K2_OnContentWidgetAdded(const UUserWidget * AddedUserWidget)Defined in DraggableWindow.h:408 protected UDraggableWindow::K2_OnContentWidgetAdded Event called when a new content is added to this window.
Parameters
Section titled “Parameters”AddedUserWidget[const UUserWidget*] Reference to the content that is being added.
Referenced by
Section titled “Referenced by”K2_OnDragStart
Section titled “K2_OnDragStart”void K2_OnDragStart(const FPointerEvent & InMouseEvent)Defined in DraggableWindow.h:416 protected UDraggableWindow::K2_OnDragStart Event called when resizing is started. Only called if Enable Drag is true.
Parameters
Section titled “Parameters”InMouseEvent[const FPointerEvent&] Mouse or touch action.
Referenced by
Section titled “Referenced by”K2_OnResizeStart
Section titled “K2_OnResizeStart”void K2_OnResizeStart(const FPointerEvent & InMouseEvent)Defined in DraggableWindow.h:424 protected UDraggableWindow::K2_OnResizeStart Event called when resizing is started. Only called if Enable Resizing is true.
Parameters
Section titled “Parameters”InMouseEvent[const FPointerEvent&] Mouse or touch action.
Referenced by
Section titled “Referenced by”K2_StartMinimized
Section titled “K2_StartMinimized”void K2_StartMinimized()Defined in DraggableWindow.h:431 protected UDraggableWindow::K2_StartMinimized Event called when the window starts minimized.
K2_OnWindowMaximizeToggled
Section titled “K2_OnWindowMaximizeToggled”void K2_OnWindowMaximizeToggled()Defined in DraggableWindow.h:438 protected UDraggableWindow::K2_OnWindowMaximizeToggled Event called when this window is maximized or restored.
Referenced by
Section titled “Referenced by”Private Methods
Section titled “Private Methods”| Return | Name | Description |
|---|---|---|
void | Internal_OnMouseButtonUpEvent | |
FVector2D | Internal_DetermineNewSize const | |
FEventReply | Internal_OnMouseButtonUp_WindowTitleBorder | |
FEventReply | Internal_OnMouseButtonDown_WindowTitleBorder | |
FEventReply | Internal_OnMouseButtonDown_ResizeArea | |
void | Internal_AddContentWidget |
Internal_OnMouseButtonUpEvent
Section titled “Internal_OnMouseButtonUpEvent”void Internal_OnMouseButtonUpEvent()Defined in DraggableWindow.h:267
Referenced by
Section titled “Referenced by”References
Section titled “References”Internal_DetermineNewSize
Section titled “Internal_DetermineNewSize”const
FVector2D Internal_DetermineNewSize(const FVector2D & InDelta) constDefined in DraggableWindow.h:268
Referenced by
Section titled “Referenced by”References
Section titled “References”Internal_OnMouseButtonUp_WindowTitleBorder
Section titled “Internal_OnMouseButtonUp_WindowTitleBorder”FEventReply Internal_OnMouseButtonUp_WindowTitleBorder(FGeometry InGeometry, const FPointerEvent & InMouseEvent)Defined in DraggableWindow.h:271
Referenced by
Section titled “Referenced by”References
Section titled “References”Internal_OnMouseButtonDown_WindowTitleBorder
Section titled “Internal_OnMouseButtonDown_WindowTitleBorder”FEventReply Internal_OnMouseButtonDown_WindowTitleBorder(FGeometry InGeometry, const FPointerEvent & InMouseEvent)Defined in DraggableWindow.h:274
References
Section titled “References”Internal_OnMouseButtonDown_ResizeArea
Section titled “Internal_OnMouseButtonDown_ResizeArea”FEventReply Internal_OnMouseButtonDown_ResizeArea(FGeometry InGeometry, const FPointerEvent & InMouseEvent)Defined in DraggableWindow.h:277
References
Section titled “References”DragKeyK2_OnResizeStartLastMousePositionParentSlotPreDragSizePreResizeAlignmentPreResizeOffset
Internal_AddContentWidget
Section titled “Internal_AddContentWidget”void Internal_AddContentWidget(const bool bClearPrevious)Defined in DraggableWindow.h:377