brutal/Brutal.ImGui/Generated/PInvoke/BeginDragDropSource.gen.cs
Rian Drake b578433e37 first
2026-10-15 17:10:50 +13:00

46 lines
2.6 KiB
C#

// <auto-generated/>
// Generated by Brutal.ImGui.Generator; do not edit by hand.
#nullable enable
namespace Brutal.ImGuiApi
{
public partial class ImGui
{
public unsafe partial class PInvoke
{
/// <summary>
/// <para>
/// call after submitting an item which may be dragged. when this return true, you can call
/// SetDragDropPayload() + EndDragDropSource()
/// </para>
/// <para>
/// C++:
/// <see href="https://github.com/RocketWerkz/imgui/blob/v1.92.2-docking-brutal/imgui.h#L996">imgui.h:996</see>
/// ,
/// <see href="https://github.com/RocketWerkz/imgui/blob/v1.92.2-docking-brutal/imgui.cpp#L15174">imgui.cpp:15174</see>
/// <br/><c>bool BeginDragDropSource(ImGuiDragDropFlags flags = 0)</c>
/// </para>
/// </summary>
/// <remarks>
/// <code>
/// Drag and Drop
/// - On source items, call BeginDragDropSource(), if it returns true also call SetDragDropPayload() + EndDragDropSource().
/// - On target candidates, call BeginDragDropTarget(), if it returns true also call AcceptDragDropPayload() + EndDragDropTarget().
/// - If you stop calling BeginDragDropSource() the payload is preserved however it won't have a preview tooltip (we currently display a fallback "..." tooltip, see #1725)
/// - An item can be both drag source and drop target.
/// </code>
/// <code>
/// When this returns true you need to: a) call SetDragDropPayload() exactly once, b) you may render the payload visual/description, c) call EndDragDropSource()
/// If the item has an identifier:
/// - This assume/require the item to be activated (typically via ButtonBehavior).
/// - Therefore if you want to use this with a mouse button other than left mouse button, it is up to the item itself to activate with another button.
/// - We then pull and use the mouse button that was used to activate the item and use it to carry on the drag.
/// If the item has no identifier:
/// - Currently always assume left mouse button.
/// </code>
/// </remarks>
[LibraryImport("imgui")]
public static unsafe partial Bool8 BeginDragDropSource(ImGuiDragDropFlags flags);
}
}
}