//
// Generated by Brutal.ImGui.Generator; do not edit by hand.
#nullable enable
using System.Runtime.CompilerServices;
namespace Brutal.ImGuiApi
{
///
///
/// User data payload for drag and drop operations
///
///
/// C++:
/// imgui.h:202
///
struct ImGuiPayload
///
///
///
///
/// Forward declarations: ImGui layer
///
///
[StructLayout(LayoutKind.Explicit, Size = 64)]
public unsafe partial struct ImGuiPayload
{
///
///
/// Data (copied and owned by dear imgui)
///
///
/// C++:
/// imgui.h:2769
///
void* Data
///
///
///
///
/// Members
///
///
[FieldOffset(0)]
public nint Data;
///
///
/// Data size
///
///
/// C++:
/// imgui.h:2770
///
int DataSize
///
///
///
///
/// Members
///
///
[FieldOffset(8)]
public int DataSize;
///
///
/// Source item id
///
///
/// C++:
/// imgui.h:2773
///
ImGuiID SourceId
///
///
///
///
/// [Internal]
///
///
[FieldOffset(12)]
public ImGuiID SourceId;
///
///
/// Source parent id (if available)
///
///
/// C++:
/// imgui.h:2774
///
ImGuiID SourceParentId
///
///
///
///
/// [Internal]
///
///
[FieldOffset(16)]
public ImGuiID SourceParentId;
///
///
/// Data timestamp
///
///
/// C++:
/// imgui.h:2775
///
int DataFrameCount
///
///
///
///
/// [Internal]
///
///
[FieldOffset(20)]
public int DataFrameCount;
///
/// Data type tag (short user-supplied string, 32 characters max)
///
[FieldOffset(24)]
public fixed byte DataType[33];
///
///
/// Set when AcceptDragDropPayload() was called and mouse has been hovering the target item (nb: handle
/// overlapping drag targets)
///
///
/// C++:
/// imgui.h:2777
///
bool Preview
///
///
///
///
/// [Internal]
///
///
[FieldOffset(57)]
public Bool8 Preview;
///
///
/// Set when AcceptDragDropPayload() was called and mouse button is released over the target item.
///
///
/// C++:
/// imgui.h:2778
///
bool Delivery
///
///
///
///
/// [Internal]
///
///
[FieldOffset(58)]
public Bool8 Delivery;
}
///
///
/// User data payload for drag and drop operations
///
///
/// C++:
/// imgui.h:202
///
struct ImGuiPayload
///
///
///
///
/// Forward declarations: ImGui layer
///
///
public unsafe partial struct ImGuiPayloadPtr(ImGuiPayload* ptr) : INullable
{
private ImGuiPayload* _ptr = ptr;
public ImGuiPayload* Ptr => _ptr;
public bool IsNull() => _ptr is null;
public static implicit operator ImGuiPayloadPtr(ImGuiPayload* ptr) => new(ptr);
public static implicit operator ImGuiPayload*(ImGuiPayloadPtr wrapper) => wrapper.Ptr;
///
///
/// Data (copied and owned by dear imgui)
///
///
/// C++:
/// imgui.h:2769
///
void* Data
///
///
///
///
/// Members
///
///
public ref nint Data => ref Unsafe.AsRef(&_ptr->Data);
///
///
/// Data size
///
///
/// C++:
/// imgui.h:2770
///
int DataSize
///
///
///
///
/// Members
///
///
public ref int DataSize => ref Unsafe.AsRef(&_ptr->DataSize);
///
///
/// Source item id
///
///
/// C++:
/// imgui.h:2773
///
ImGuiID SourceId
///
///
///
///
/// [Internal]
///
///
public ref ImGuiID SourceId => ref Unsafe.AsRef(&_ptr->SourceId);
///
///
/// Source parent id (if available)
///
///
/// C++:
/// imgui.h:2774
///
ImGuiID SourceParentId
///
///
///
///
/// [Internal]
///
///
public ref ImGuiID SourceParentId => ref Unsafe.AsRef(&_ptr->SourceParentId);
///
///
/// Data timestamp
///
///
/// C++:
/// imgui.h:2775
///
int DataFrameCount
///
///
///
///
/// [Internal]
///
///
public ref int DataFrameCount => ref Unsafe.AsRef(&_ptr->DataFrameCount);
///
/// Data type tag (short user-supplied string, 32 characters max)
///
public Span DataType => MemoryMarshal.CreateSpan(ref _ptr->DataType[0], 33);
///
///
/// Set when AcceptDragDropPayload() was called and mouse has been hovering the target item (nb: handle
/// overlapping drag targets)
///
///
/// C++:
/// imgui.h:2777
///
bool Preview
///
///
///
///
/// [Internal]
///
///
public ref bool Preview => ref Unsafe.AsRef(&_ptr->Preview);
///
///
/// Set when AcceptDragDropPayload() was called and mouse button is released over the target item.
///
///
/// C++:
/// imgui.h:2778
///
bool Delivery
///
///
///
///
/// [Internal]
///
///
public ref bool Delivery => ref Unsafe.AsRef(&_ptr->Delivery);
}
}