|
// ------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
// ------------------------------------------------------------------------------
#pragma warning disable CS1591,CS1573,CS0465,CS0649,CS8019,CS1570,CS1584,CS1658,CS0436,CS8981
using global::System;
using global::System.Diagnostics;
using global::System.Diagnostics.CodeAnalysis;
using global::System.Runtime.CompilerServices;
using global::System.Runtime.InteropServices;
using global::System.Runtime.Versioning;
using winmdroot = global::Windows.Win32;
namespace Windows.Win32
{
namespace Foundation
{
[DebuggerDisplay("{Value}")]
[global::System.CodeDom.Compiler.GeneratedCode("Microsoft.Windows.CsWin32", "0.3.151+58e949951d.RR")]
internal unsafe readonly partial struct HWND
: IEquatable<HWND>
{
internal readonly void* Value;
internal HWND(void* value) => this.Value = value;
internal HWND(IntPtr value):this((void*)value)
{
}
internal static HWND Null => default;
internal bool IsNull => Value == default;
public static implicit operator void*(HWND value) => value.Value;
public static explicit operator HWND(void* value) => new HWND(value);
public static bool operator ==(HWND left, HWND right) => left.Value == right.Value;
public static bool operator !=(HWND left, HWND right) => !(left == right);
public bool Equals(HWND other) => this.Value == other.Value;
public override bool Equals(object obj) => obj is HWND other && this.Equals(other);
public override int GetHashCode() => unchecked((int)this.Value);
public override string ToString() => $"0x{(nuint)this.Value:x}";
public static implicit operator IntPtr(HWND value) => new IntPtr(value.Value);
public static explicit operator HWND(IntPtr value) => new HWND((void*)value.ToPointer());
public static explicit operator HWND(UIntPtr value) => new HWND((void*)value.ToPointer());
public static implicit operator HANDLE(HWND value) => new HANDLE(value.Value);
internal static readonly winmdroot.Foundation.HWND HWND_BROADCAST = (winmdroot.Foundation.HWND)(IntPtr)(65535);
internal static readonly winmdroot.Foundation.HWND HWND_MESSAGE = (winmdroot.Foundation.HWND)(IntPtr)(-3);
internal static readonly winmdroot.Foundation.HWND HWND_DESKTOP = (winmdroot.Foundation.HWND)(IntPtr)(0);
/// <summary>Places the window at the top of the Z order.</summary>
/// <remarks>
/// <para><see href="https://learn.microsoft.com/windows/win32/api/winuser/nf-winuser-deferwindowpos">Learn more about this API from docs.microsoft.com</see>.</para>
/// </remarks>
internal static readonly winmdroot.Foundation.HWND HWND_TOP = (winmdroot.Foundation.HWND)(IntPtr)(0);
/// <summary>Places the window at the bottom of the Z order. If the <i>hWnd</i> parameter identifies a topmost window, the window loses its topmost status and is placed at the bottom of all other windows.</summary>
/// <remarks>
/// <para><see href="https://learn.microsoft.com/windows/win32/api/winuser/nf-winuser-deferwindowpos">Learn more about this API from docs.microsoft.com</see>.</para>
/// </remarks>
internal static readonly winmdroot.Foundation.HWND HWND_BOTTOM = (winmdroot.Foundation.HWND)(IntPtr)(1);
/// <summary>Places the window above all non-topmost windows. The window maintains its topmost position even when it is deactivated.</summary>
/// <remarks>
/// <para><see href="https://learn.microsoft.com/windows/win32/api/winuser/nf-winuser-deferwindowpos">Learn more about this API from docs.microsoft.com</see>.</para>
/// </remarks>
internal static readonly winmdroot.Foundation.HWND HWND_TOPMOST = (winmdroot.Foundation.HWND)(IntPtr)(-1);
/// <summary>Places the window above all non-topmost windows (that is, behind all topmost windows). This flag has no effect if the window is already a non-topmost window.</summary>
/// <remarks>
/// <para><see href="https://learn.microsoft.com/windows/win32/api/winuser/nf-winuser-deferwindowpos">Learn more about this API from docs.microsoft.com</see>.</para>
/// </remarks>
internal static readonly winmdroot.Foundation.HWND HWND_NOTOPMOST = (winmdroot.Foundation.HWND)(IntPtr)(-2);
}
}
}
|