UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
DragAndDrop.h File Reference
#include "CoreMinimal.h"
#include "Input/CursorReply.h"
#include "Input/Events.h"
#include "Input/DragAndDrop.inl"

Go to the source code of this file.

Classes

class  FDragDropOperation
 
class  FDragDropEvent
 
class  FExternalDragOperation
 
class  FGameDragDropOperation
 

Macros

#define DRAG_DROP_OPERATOR_TYPE(TYPE, BASE)
 

Functions

 DECLARE_DELEGATE_TwoParams (FOnDragDropEnded, bool, const FDragDropEvent &) DECLARE_DELEGATE_OneParam(FOnDragDropUpdate
 

Macro Definition Documentation

◆ DRAG_DROP_OPERATOR_TYPE

#define DRAG_DROP_OPERATOR_TYPE (   TYPE,
  BASE 
)
Value:
static const FString& GetTypeId() { static FString Type = TEXT(#TYPE); return Type; } \
virtual bool IsOfTypeImpl(const FString& Type) const override { return GetTypeId() == Type || BASE::IsOfTypeImpl(Type); }
#define TEXT(x)
Definition Platform.h:1272
UE_FORCEINLINE_HINT TSharedRef< CastToType, Mode > StaticCastSharedRef(TSharedRef< CastFromType, Mode > const &InSharedRef)
Definition SharedPointer.h:127

All drag drop operations that require type checking must include this macro. Example Usage: class FMyDragDropOp : public FDragDropOperation { public: DRAG_DROP_OPERATOR_TYPE(FMyDragDropOp, FDragDropOperation) ... };

Function Documentation

◆ DECLARE_DELEGATE_TwoParams()

DECLARE_DELEGATE_TwoParams ( FOnDragDropEnded  ,
bool  ,
const FDragDropEvent  
)

Invoked when a drag and drop is finished. This allows the widget that started the drag/drop to respond to the end of the operation.

Parameters
bWasDropHandledTrue when the drag and drop operation was handled by some widget; False when no widget handled the drop.
DragDropEventThe Drop event that terminated the whole DragDrop operation A delegate invoked on the initiator of the DragDrop operation. This delegate is invoked periodically during the DragDrop, and gives the initiator an opportunity to respond to the current state of the process. e.g. Create and update a custom cursor.