Torque3D Documentation / _generateds / GuiDragAndDropControl

GuiDragAndDropControl

Engine/source/gui/containers/guiDragAndDropCtrl.h

A special control that implements drag-and-drop behavior.

More...

Public Types

Parent 

Private Attributes

bool

If true, the control deletes itself when the left mouse button is released.

Controls may want to react when they are dragged over, entered or exited.

The mouse down offset from the upper left of the control.

Private Functions

findDragTarget(Point2I mousePoint, const char * method)

Public Functions

DECLARE_CALLBACK(void , onControlDragCancelled , () )
DECLARE_CATEGORY("Gui Other" )
DECLARE_DESCRIPTION("A special <a href="/coding/file/guieditctrl_8cpp/#guieditctrl_8cpp_1abb04e3738c4c5a96b3ade6fa47013a6c">control</a> that implements drag&drop <a href="/coding/file/cmdscan_8cpp/#cmdscan_8cpp_1aeab71244afb687f16d8c4f5ee9d6ef0e">behavior.\n</a>" "The <a href="/coding/file/guieditctrl_8cpp/#guieditctrl_8cpp_1abb04e3738c4c5a96b3ade6fa47013a6c">control</a> will <a href="/coding/file/gamefunctions_8cpp/#gamefunctions_8cpp_1aa17ef8ef4f36199ef68ab2859f9fbda4">notify</a> other controls as it moves across the <a href="/coding/file/cmdscan_8cpp/#cmdscan_8cpp_1aeab71244afb687f16d8c4f5ee9d6ef0e">canvas.\n</a>" "Content can be attached through dynamic fields or child objects." )

Public Static Functions

Detailed Description

A special control that implements drag-and-drop behavior.

Public Types

typedef GuiControl Parent 

Private Attributes

bool mDeleteOnMouseUp 

If true, the control deletes itself when the left mouse button is released.

SimObjectPtr< GuiControl > mLastTarget 

Controls may want to react when they are dragged over, entered or exited.

Point2I mOffset 

The mouse down offset from the upper left of the control.

bool mUseWholeCanvas 

Private Functions

findDragTarget(Point2I mousePoint, const char * method)

getDropPoint()

Public Functions

GuiDragAndDropControl()

DECLARE_CALLBACK(void , onControlDragCancelled , () )

DECLARE_CATEGORY("Gui Other" )

DECLARE_CONOBJECT(GuiDragAndDropControl )

DECLARE_DESCRIPTION("A special <a href="/coding/file/guieditctrl_8cpp/#guieditctrl_8cpp_1abb04e3738c4c5a96b3ade6fa47013a6c">control</a> that implements drag&drop <a href="/coding/file/cmdscan_8cpp/#cmdscan_8cpp_1aeab71244afb687f16d8c4f5ee9d6ef0e">behavior.\n</a>" "The <a href="/coding/file/guieditctrl_8cpp/#guieditctrl_8cpp_1abb04e3738c4c5a96b3ade6fa47013a6c">control</a> will <a href="/coding/file/gamefunctions_8cpp/#gamefunctions_8cpp_1aa17ef8ef4f36199ef68ab2859f9fbda4">notify</a> other controls as it moves across the <a href="/coding/file/cmdscan_8cpp/#cmdscan_8cpp_1aeab71244afb687f16d8c4f5ee9d6ef0e">canvas.\n</a>" "Content can be attached through dynamic fields or child objects." )

onMouseDown(const GuiEvent & event)

Reimplemented from: GuiControl

onMouseDragged(const GuiEvent & event)

Reimplemented from: GuiControl

onMouseUp(const GuiEvent & event)

Reimplemented from: GuiControl

startDragging(Point2I offset)

Public Static Functions

initPersistFields()