Class DropTarget
- Namespace
- Gtk
- Assembly
- Gtk-4.0.dll
public class DropTarget : EventController, IDisposable, NativeObject, GTypeProvider, InstanceFactory
- Inheritance
-
DropTarget
- Implements
- Inherited Members
Constructors
DropTarget(params ConstructArgument[])
[Obsolete("Regular C# constructors on native classes will be removed in a future version. Please see the linked documentation for more details. It contains scenarios and possible solutions to prepare for the upcoming changes.", DiagnosticId = "GirCore1007", UrlFormat = "https://gircore.github.io/docs/integration/diagnostic/1007.html")]
public DropTarget(params ConstructArgument[] constructArguments)
Parameters
constructArgumentsConstructArgument[]
DropTarget(CreationData)
[Obsolete("This constructor is a workaround to keep legacy APIs alive. Do not use it.")]
protected DropTarget(CreationData data)
Parameters
dataCreationData
DropTarget(DropTargetHandle)
protected DropTarget(DropTargetHandle handle)
Parameters
handleDropTargetHandle
Fields
AcceptSignal
Signal Descriptor for OnAccept.
public static readonly ReturningSignal<DropTarget, DropTarget.AcceptSignalArgs, bool> AcceptSignal
Field Value
ActionsPropertyDefinition
public static readonly Property<DragAction, DropTarget> ActionsPropertyDefinition
Field Value
CurrentDropPropertyDefinition
public static readonly Property<Drop?, DropTarget> CurrentDropPropertyDefinition
Field Value
DropPropertyDefinition
public static readonly Property<Drop?, DropTarget> DropPropertyDefinition
Field Value
DropSignal
Signal Descriptor for OnDrop.
public static readonly ReturningSignal<DropTarget, DropTarget.DropSignalArgs, bool> DropSignal
Field Value
EnterSignal
Signal Descriptor for OnEnter.
public static readonly ReturningSignal<DropTarget, DropTarget.EnterSignalArgs, DragAction> EnterSignal
Field Value
FormatsPropertyDefinition
public static readonly Property<ContentFormats, DropTarget> FormatsPropertyDefinition
Field Value
LeaveSignal
Signal Descriptor for OnLeave.
public static readonly Signal<DropTarget> LeaveSignal
Field Value
MotionSignal
Signal Descriptor for OnMotion.
public static readonly ReturningSignal<DropTarget, DropTarget.MotionSignalArgs, DragAction> MotionSignal
Field Value
PreloadPropertyDefinition
public static readonly Property<bool, DropTarget> PreloadPropertyDefinition
Field Value
ValuePropertyDefinition
public static readonly Property<Value, DropTarget> ValuePropertyDefinition
Field Value
Properties
Actions
public DragAction Actions { get; set; }
Property Value
CurrentDrop
public Drop? CurrentDrop { get; }
Property Value
Drop
public Drop? Drop { get; }
Property Value
Formats
public ContentFormats Formats { get; }
Property Value
Preload
public bool Preload { get; set; }
Property Value
Value
public Value Value { get; }
Property Value
Methods
GetActions()
public DragAction GetActions()
Returns
GetCurrentDrop()
[Version("4.4")]
public Drop? GetCurrentDrop()
Returns
GetDrop()
public Drop? GetDrop()
Returns
GetFormats()
public ContentFormats? GetFormats()
Returns
GetGType()
public static Type GetGType()
Returns
GetGtypes()
public Type[] GetGtypes()
Returns
- Type[]
GetPreload()
public bool GetPreload()
Returns
GetValue()
public Value? GetValue()
Returns
New(Type, DragAction)
public static DropTarget New(Type type, DragAction actions)
Parameters
typeTypeactionsDragAction
Returns
NewFromPointer(nint, bool)
Creates a new managed DropTarget instance for a given pointer.
public static DropTarget NewFromPointer(nint ptr, bool ownsHandle)
Parameters
Returns
NewWithProperties(ConstructArgument[])
Creates a new DropTarget and sets the properties specified by the construct arguments.
public static DropTarget NewWithProperties(ConstructArgument[] constructArguments)
Parameters
constructArgumentsConstructArgument[]The properties to set.
Returns
Reject()
public void Reject()
SetActions(DragAction)
public void SetActions(DragAction actions)
Parameters
actionsDragAction
SetPreload(bool)
public void SetPreload(bool preload)
Parameters
preloadbool
Events
OnAccept
public event ReturningSignalHandler<DropTarget, DropTarget.AcceptSignalArgs, bool> OnAccept
Event Type
OnDrop
public event ReturningSignalHandler<DropTarget, DropTarget.DropSignalArgs, bool> OnDrop
Event Type
OnEnter
public event ReturningSignalHandler<DropTarget, DropTarget.EnterSignalArgs, DragAction> OnEnter
Event Type
OnLeave
public event SignalHandler<DropTarget> OnLeave
Event Type
OnMotion
public event ReturningSignalHandler<DropTarget, DropTarget.MotionSignalArgs, DragAction> OnMotion