如何在WPF中设置鼠标位置
实际上,有一种方法在 我想在自定义控件中为光标定义一个可移动区域。 使用此本机函数会使光标闪烁如何在WPF中设置鼠标位置,wpf,mouse,position,Wpf,Mouse,Position,实际上,有一种方法在 我想在自定义控件中为光标定义一个可移动区域。 使用此本机函数会使光标闪烁 是否有其他方法可以设置鼠标位置而不引起闪烁?也许您可以从非托管模式中获益 [System.Runtime.InteropServices.DllImportAttribute("user32.dll", EntryPoint = "SetCursorPos")] [return: System.Runtime.InteropServices.MarshalAsAttribute(System.R
是否有其他方法可以设置鼠标位置而不引起闪烁?也许您可以从非托管模式中获益
[System.Runtime.InteropServices.DllImportAttribute("user32.dll", EntryPoint = "SetCursorPos")]
[return: System.Runtime.InteropServices.MarshalAsAttribute(System.Runtime.InteropServices.UnmanagedType.Bool)]
public static extern bool SetCursorPos(int X, int Y);