mirror of
https://github.com/ahwootech/BRUTAL.git
synced 2026-11-25 20:48:24 +01:00
43 lines
2.4 KiB
C#
43 lines
2.4 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 that may receive a payload. If this returns true, you can call
|
|
/// AcceptDragDropPayload() + EndDragDropTarget()
|
|
/// </para>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/RocketWerkz/imgui/blob/v1.92.2-docking-brutal/imgui.h#L999">imgui.h:999</see>
|
|
/// ,
|
|
/// <see href="https://github.com/RocketWerkz/imgui/blob/v1.92.2-docking-brutal/imgui.cpp#L15381">imgui.cpp:15381</see>
|
|
/// <br/><c>bool BeginDragDropTarget()</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>
|
|
/// We don't use BeginDragDropTargetCustom() and duplicate its code because:
|
|
/// 1) we use LastItemData's ImGuiItemStatusFlags_HoveredRect which handles items that push a temporarily clip rectangle in their code. Calling BeginDragDropTargetCustom(LastItemRect) would not handle them.
|
|
/// 2) and it's faster. as this code may be very frequently called, we want to early out as fast as we can.
|
|
/// Also note how the HoveredWindow test is positioned differently in both functions (in both functions we optimize for the cheapest early out case)
|
|
/// </code>
|
|
/// </remarks>
|
|
[LibraryImport("imgui")]
|
|
public static unsafe partial Bool8 BeginDragDropTarget();
|
|
}
|
|
}
|
|
}
|