Table of Contents

Method ToWin32Controller

Namespace
MaaFramework.Binding
Assembly
MaaFramework.Binding.Native.dll

ToWin32Controller(DesktopWindowInfo, Win32ScreencapMethod, Win32InputMethod, nint?, LinkOption, CheckStatusOption)

Converts a MaaFramework.Binding.DesktopWindowInfo to a MaaFramework.Binding.MaaWin32Controller.

public static MaaWin32Controller ToWin32Controller(this DesktopWindowInfo info, Win32ScreencapMethod screencapMethod, Win32InputMethod inputMethod, nint? hWnd = null, LinkOption link = LinkOption.Start, CheckStatusOption check = CheckStatusOption.ThrowIfNotSucceeded)

Parameters

info DesktopWindowInfo

The DesktopWindowInfo.

screencapMethod Win32ScreencapMethod

The screencap method.

inputMethod Win32InputMethod

The input method.

hWnd nint?

The new handle to a win32 window.

link LinkOption

Executes MaaFramework.Binding.MaaController.LinkStart if MaaFramework.Binding.LinkOption.Start; otherwise, not link.

check CheckStatusOption

Checks LinkStart().Wait() status if MaaFramework.Binding.CheckStatusOption.ThrowIfNotSucceeded; otherwise, not check.

Returns

MaaWin32Controller

A MaaWin32Controller.

Exceptions

ArgumentNullException