Cabster/Extensions/WindowsApiExtensions.cs
/// <summary>
///     Obtem o Z-Order de uma janela.
/// </summary>
/// <param name="hWnd">Handle da janela.</param>
/// <returns>Z-Order</returns>
Obtem o Z-Order de uma janela.
Obtem o Z - Order de uma janela .
public static int GetWindowZOrder(this IntPtr hWnd)
        {
            var zOrder = -1;
            while ((hWnd = WindowsApi.GetWindow(hWnd, WindowsApi.GetWindowType.GW_HWNDNEXT))
                   != IntPtr.Zero) zOrder++;
            return zOrder;
        }
public static int GetWindowZOrder ( this IntPtr hWnd ) { var zOrder = - 1 ; while ( ( hWnd = WindowsApi . GetWindow ( hWnd , WindowsApi . GetWindowType . GW_HWNDNEXT ) ) != IntPtr . Zero ) zOrder ++ ; return zOrder ; }
Obtem o Z-Order de uma janela.
Obtem o Z - Order de uma janela .
None
IntPtr
this
hWnd
Handle da janela.
Handle da janela .