|
// ------------------------------------------------------------------------------
// <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 UI.Accessibility
{
[Guid("B17D6187-0907-464B-A168-0EF17A1572B1")]
[SupportedOSPlatform("windows5.1.2600")]
[global::System.CodeDom.Compiler.GeneratedCode("Microsoft.Windows.CsWin32", "0.3.151+58e949951d.RR")]
internal unsafe partial struct IGridProvider
:IVTable<IGridProvider,IGridProvider.Vtbl>,IComIID {
/// <inheritdoc cref="QueryInterface(global::System.Guid*, void**)"/>
internal unsafe winmdroot.Foundation.HRESULT QueryInterface(in global::System.Guid riid, out void* ppvObject)
{
fixed (void** ppvObjectLocal = &ppvObject)
{
fixed (global::System.Guid* riidLocal = &riid)
{
winmdroot.Foundation.HRESULT __result = this.QueryInterface(riidLocal, ppvObjectLocal);
return __result;
}
}
}
public unsafe winmdroot.Foundation.HRESULT QueryInterface(global::System.Guid* riid, void** ppvObject)
{
return ((delegate *unmanaged [Stdcall]<IGridProvider*,global::System.Guid* ,void** ,winmdroot.Foundation.HRESULT>)lpVtbl[0])((IGridProvider*)Unsafe.AsPointer(ref this), riid, ppvObject);
}
public uint AddRef()
{
return ((delegate *unmanaged [Stdcall]<IGridProvider*,uint>)lpVtbl[1])((IGridProvider*)Unsafe.AsPointer(ref this));
}
public uint Release()
{
return ((delegate *unmanaged [Stdcall]<IGridProvider*,uint>)lpVtbl[2])((IGridProvider*)Unsafe.AsPointer(ref this));
}
[UnmanagedCallersOnly(CallConvs = new []{
typeof(CallConvStdcall)}
)]
private static winmdroot.Foundation.HRESULT GetItem(IGridProvider* pThis, int row, int column, winmdroot.UI.Accessibility.IRawElementProviderSimple** pRetVal)
{
try
{
winmdroot.Foundation.HRESULT __hr = ComHelpers.UnwrapCCW(pThis, out Interface __object);
if (__hr.Failed)
{
return __hr;
}
return __object.GetItem(row, column, pRetVal);
}
catch (Exception ex)
{
return (winmdroot.Foundation.HRESULT)ex.HResult;
}
}
/// <summary>Retrieves the Microsoft UI Automation provider for the specified cell.</summary>
/// <param name="row">
/// <para>Type: <b>int</b> The ordinal number of the row of interest.</para>
/// <para><see href="https://learn.microsoft.com/windows/win32/api/uiautomationcore/nf-uiautomationcore-igridprovider-getitem#parameters">Read more on docs.microsoft.com</see>.</para>
/// </param>
/// <param name="column">
/// <para>Type: <b>int</b> The ordinal number of the column of interest.</para>
/// <para><see href="https://learn.microsoft.com/windows/win32/api/uiautomationcore/nf-uiautomationcore-igridprovider-getitem#parameters">Read more on docs.microsoft.com</see>.</para>
/// </param>
/// <returns>
/// <para>Type: <b><a href="https://docs.microsoft.com/windows/desktop/WinProg/windows-data-types">HRESULT</a></b> If this method succeeds, it returns <b>S_OK</b>. Otherwise, it returns an <b>HRESULT</b> error code.</para>
/// </returns>
/// <remarks>
/// <para>Grid coordinates are zero-based with the upper left (or upper right cell depending on locale) having coordinates (0,0).</para>
/// <para>If a cell is empty a UI Automation provider must still be returned in order to support the <a href="https://docs.microsoft.com/windows/desktop/api/uiautomationcore/nf-uiautomationcore-igriditemprovider-get_containinggrid">ContainingGrid</a> property for that cell. This is possible when the layout of child elements in the grid is similar to a ragged array.</para>
/// <para>Hidden rows and columns, depending on the provider implementation, may be loaded in the UI Automation tree and will therefore be reflected in the <a href="https://docs.microsoft.com/windows/desktop/api/uiautomationcore/nf-uiautomationcore-igridprovider-get_rowcount">IGridProvider::RowCount</a> and <a href="https://docs.microsoft.com/windows/desktop/api/uiautomationcore/nf-uiautomationcore-igridprovider-get_columncount">IGridProvider::ColumnCount</a> properties. If the hidden rows and columns have not yet been loaded they should not be counted.</para>
/// <para><see href="https://learn.microsoft.com/windows/win32/api/uiautomationcore/nf-uiautomationcore-igridprovider-getitem#">Read more on docs.microsoft.com</see>.</para>
/// </remarks>
public unsafe winmdroot.UI.Accessibility.IRawElementProviderSimple* GetItem(int row, int column)
{
winmdroot.UI.Accessibility.IRawElementProviderSimple* __retVal = default(winmdroot.UI.Accessibility.IRawElementProviderSimple*);
((delegate *unmanaged [Stdcall]<IGridProvider*,int ,int ,winmdroot.UI.Accessibility.IRawElementProviderSimple** ,winmdroot.Foundation.HRESULT>)lpVtbl[3])((IGridProvider*)Unsafe.AsPointer(ref this), row, column, &__retVal).ThrowOnFailure();
return __retVal;
}
/// <inheritdoc cref="get_RowCount(int*)"/>
internal unsafe winmdroot.Foundation.HRESULT get_RowCount(out int pRetVal)
{
fixed (int* pRetValLocal = &pRetVal)
{
winmdroot.Foundation.HRESULT __result = this.get_RowCount(pRetValLocal);
return __result;
}
}
[UnmanagedCallersOnly(CallConvs = new []{
typeof(CallConvStdcall)}
)]
private static winmdroot.Foundation.HRESULT get_RowCount(IGridProvider* pThis, int* pRetVal)
{
try
{
winmdroot.Foundation.HRESULT __hr = ComHelpers.UnwrapCCW(pThis, out Interface __object);
if (__hr.Failed)
{
return __hr;
}
return __object.get_RowCount(pRetVal);
}
catch (Exception ex)
{
return (winmdroot.Foundation.HRESULT)ex.HResult;
}
}
/// <summary>Specifies the total number of rows in the grid.</summary>
/// <remarks>
/// <para>Hidden rows and columns, depending on the provider implementation, may be loaded in the logical tree and will therefore be reflected in the <b>IGridProvider::RowCount</b> and <a href="https://docs.microsoft.com/windows/desktop/api/uiautomationcore/nf-uiautomationcore-igridprovider-get_columncount">IGridProvider::ColumnCount</a> properties. If the hidden rows and columns have not yet been loaded they will not be counted.</para>
/// <para><see href="https://learn.microsoft.com/windows/win32/api/uiautomationcore/nf-uiautomationcore-igridprovider-get_rowcount#">Read more on docs.microsoft.com</see>.</para>
/// </remarks>
public unsafe winmdroot.Foundation.HRESULT get_RowCount(int* pRetVal)
{
return ((delegate *unmanaged [Stdcall]<IGridProvider*,int* ,winmdroot.Foundation.HRESULT>)lpVtbl[4])((IGridProvider*)Unsafe.AsPointer(ref this), pRetVal);
}
/// <inheritdoc cref="get_ColumnCount(int*)"/>
internal unsafe winmdroot.Foundation.HRESULT get_ColumnCount(out int pRetVal)
{
fixed (int* pRetValLocal = &pRetVal)
{
winmdroot.Foundation.HRESULT __result = this.get_ColumnCount(pRetValLocal);
return __result;
}
}
[UnmanagedCallersOnly(CallConvs = new []{
typeof(CallConvStdcall)}
)]
private static winmdroot.Foundation.HRESULT get_ColumnCount(IGridProvider* pThis, int* pRetVal)
{
try
{
winmdroot.Foundation.HRESULT __hr = ComHelpers.UnwrapCCW(pThis, out Interface __object);
if (__hr.Failed)
{
return __hr;
}
return __object.get_ColumnCount(pRetVal);
}
catch (Exception ex)
{
return (winmdroot.Foundation.HRESULT)ex.HResult;
}
}
/// <summary>Specifies the total number of columns in the grid.</summary>
/// <remarks>
/// <para>Hidden rows and columns, depending on the provider implementation, may be loaded in the logical tree and will therefore be reflected in the <a href="https://docs.microsoft.com/windows/desktop/api/uiautomationcore/nf-uiautomationcore-igridprovider-get_rowcount">IGridProvider::RowCount</a> and <b>IGridProvider::ColumnCount</b> properties. If the hidden rows and columns have not yet been loaded they will not be counted.</para>
/// <para><see href="https://learn.microsoft.com/windows/win32/api/uiautomationcore/nf-uiautomationcore-igridprovider-get_columncount#">Read more on docs.microsoft.com</see>.</para>
/// </remarks>
public unsafe winmdroot.Foundation.HRESULT get_ColumnCount(int* pRetVal)
{
return ((delegate *unmanaged [Stdcall]<IGridProvider*,int* ,winmdroot.Foundation.HRESULT>)lpVtbl[5])((IGridProvider*)Unsafe.AsPointer(ref this), pRetVal);
}
internal unsafe global::Windows.Win32.Foundation.HRESULT QueryInterface<T>(out T* ppv)
where T : unmanaged
{
var hr = this.QueryInterface(typeof(T).GUID, out void* pv);
if (hr.Succeeded)
{
ppv = (T*)pv;
}
else
{
ppv = null;
}
return hr;
}
internal struct Vtbl
{
internal delegate *unmanaged [Stdcall]<IGridProvider*,global::System.Guid* ,void** ,winmdroot.Foundation.HRESULT> QueryInterface_1;
internal delegate *unmanaged [Stdcall]<IGridProvider*,uint> AddRef_2;
internal delegate *unmanaged [Stdcall]<IGridProvider*,uint> Release_3;
internal delegate *unmanaged [Stdcall]<IGridProvider*,int ,int ,winmdroot.UI.Accessibility.IRawElementProviderSimple** ,winmdroot.Foundation.HRESULT> GetItem_4;
internal delegate *unmanaged [Stdcall]<IGridProvider*,int* ,winmdroot.Foundation.HRESULT> get_RowCount_5;
internal delegate *unmanaged [Stdcall]<IGridProvider*,int* ,winmdroot.Foundation.HRESULT> get_ColumnCount_6;
}
public static void PopulateVTable(Vtbl* vtable)
{
vtable->GetItem_4 = &GetItem;
vtable->get_RowCount_5 = &get_RowCount;
vtable->get_ColumnCount_6 = &get_ColumnCount;
}
private void** lpVtbl;
/// <summary>The IID guid for this interface.</summary>
/// <value>{b17d6187-0907-464b-a168-0ef17a1572b1}</value>
internal static readonly Guid IID_Guid = new Guid(0xB17D6187, 0x0907, 0x464B, 0xA1, 0x68, 0x0E, 0xF1, 0x7A, 0x15, 0x72, 0xB1);
static ref readonly Guid IComIID.Guid {
[MethodImpl(MethodImplOptions.AggressiveInlining)]
get
{
ReadOnlySpan<byte> data = new byte[] {
0x87,0x61,0x7D,0xB1,0x07,0x09,0x4B,0x46,0xA1,0x68,0x0E,0xF1,0x7A,0x15,0x72,0xB1 };
return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
}
}
[Guid("B17D6187-0907-464B-A168-0EF17A1572B1"),InterfaceType(ComInterfaceType.InterfaceIsIUnknown),ComImport()]
[SupportedOSPlatform("windows5.1.2600")]
internal interface Interface
{
[PreserveSig()]
unsafe winmdroot.Foundation.HRESULT GetItem(int row, int column, winmdroot.UI.Accessibility.IRawElementProviderSimple** pRetVal);
[PreserveSig()]
unsafe winmdroot.Foundation.HRESULT get_RowCount(int* pRetVal);
[PreserveSig()]
unsafe winmdroot.Foundation.HRESULT get_ColumnCount(int* pRetVal);
}
}
}
}
|