// ------------------------------------------------------------------------------ // // This code was generated by a tool. // // Changes to this file may cause incorrect behavior and will be lost if // the code is regenerated. // // ------------------------------------------------------------------------------ using System; using System.Diagnostics; using System.Runtime.CompilerServices; using System.Runtime.InteropServices; using HexaGen.Runtime; using System.Numerics; namespace Dalamud.Bindings.ImGui { /// /// To be documented. /// [StructLayout(LayoutKind.Sequential)] public partial struct ImVec2Ih { /// /// To be documented. /// public short X; /// /// To be documented. /// public short Y; /// /// To be documented. /// public unsafe ImVec2Ih(short x = default, short y = default) { X = x; Y = y; } /// /// To be documented. /// public unsafe void Destroy() { fixed (ImVec2Ih* @this = &this) { ImGui.DestroyNative(@this); } } } /// /// To be documented. /// #if NET5_0_OR_GREATER [DebuggerDisplay("{DebuggerDisplay,nq}")] #endif public unsafe struct ImVec2IhPtr : IEquatable { public ImVec2IhPtr(ImVec2Ih* handle) { Handle = handle; } public ImVec2Ih* Handle; public bool IsNull => Handle == null; public static ImVec2IhPtr Null => new ImVec2IhPtr(null); public ImVec2Ih this[int index] { get => Handle[index]; set => Handle[index] = value; } public static implicit operator ImVec2IhPtr(ImVec2Ih* handle) => new ImVec2IhPtr(handle); public static implicit operator ImVec2Ih*(ImVec2IhPtr handle) => handle.Handle; public static bool operator ==(ImVec2IhPtr left, ImVec2IhPtr right) => left.Handle == right.Handle; public static bool operator !=(ImVec2IhPtr left, ImVec2IhPtr right) => left.Handle != right.Handle; public static bool operator ==(ImVec2IhPtr left, ImVec2Ih* right) => left.Handle == right; public static bool operator !=(ImVec2IhPtr left, ImVec2Ih* right) => left.Handle != right; public bool Equals(ImVec2IhPtr other) => Handle == other.Handle; /// public override bool Equals(object obj) => obj is ImVec2IhPtr handle && Equals(handle); /// public override int GetHashCode() => ((nuint)Handle).GetHashCode(); #if NET5_0_OR_GREATER private string DebuggerDisplay => string.Format("ImVec2IhPtr [0x{0}]", ((nuint)Handle).ToString("X")); #endif /// /// To be documented. /// public ref short X => ref Unsafe.AsRef(&Handle->X); /// /// To be documented. /// public ref short Y => ref Unsafe.AsRef(&Handle->Y); /// /// To be documented. /// public unsafe void Destroy() { ImGui.DestroyNative(Handle); } } }