using System;
using System.Runtime.InteropServices;
using System.Text;
namespace Vanara.PInvoke
{
public static partial class Shell32
{
/// Enables access to DataTransferManager methods in a Windows Store app that manages multiple windows.
// https://docs.microsoft.com/en-us/windows/win32/api/shobjidl_core/nn-shobjidl_core-idatatransfermanagerinterop
[PInvokeData("shobjidl_core.h", MSDNShortId = "NN:shobjidl_core.IDataTransferManagerInterop")]
[ComImport, Guid("3A3DCD6C-3EAB-43DC-BCDE-45671CE800C8"), InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
public interface IDataTransferManagerInterop
{
/// Gets the DataTransferManager instance for the specified window.
/// The window whose DataTransferManager instance is to be retrieved.
/// The requested interface ID of the DataTransferManager instance.
/// Receives the DataTransferManager instance.
/// If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.
///
/// This method is equivalent to the DataTransferManager.GetForCurrentView method, except that you specify a window from a
/// multi-window Windows Store app.
///
// https://docs.microsoft.com/en-us/windows/win32/api/shobjidl_core/nf-shobjidl_core-idatatransfermanagerinterop-getforwindow
// HRESULT GetForWindow( HWND appWindow, REFIID riid, void **dataTransferManager );
[PreserveSig]
HRESULT GetForWindow(HWND appWindow, in Guid riid, [MarshalAs(UnmanagedType.Interface, IidParameterIndex = 1)] out object dataTransferManager);
/// Displays the UI for sharing content for the specified window.
/// The window to show the share UI for.
/// If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.
///
/// This method is equivalent to the DataTransferManager.ShowShareUI method, except that you specify a window from a
/// multi-window Windows Store app.
///
// https://docs.microsoft.com/en-us/windows/win32/api/shobjidl_core/nf-shobjidl_core-idatatransfermanagerinterop-showshareuiforwindow
// HRESULT ShowShareUIForWindow( HWND appWindow );
[PreserveSig]
HRESULT ShowShareUIForWindow(HWND appWindow);
}
}
}