加上设置窗口到最前的辅助方法
This commit is contained in:
1 parent
35eb871040
commit
7151fec7b8
2 files changed
+46
No files matched your search
@@ -43,6 +43,13 @@ namespace HandyControl.Tools.Interop
|
||||
[DllImport(InteropValues.ExternDll.User32, SetLastError = true, CharSet = CharSet.Auto)]
|
||||
internal static extern uint GetWindowThreadProcessId(IntPtr hWnd, out uint lpdwProcessId);
|
||||
|
||||
[DllImport(InteropValues.ExternDll.User32, SetLastError = true, CharSet = CharSet.Auto)]
|
||||
internal static extern bool AttachThreadInput(in uint currentForegroundWindowThreadId,
|
||||
in uint thisWindowThreadId, bool isAttach);
|
||||
|
||||
[DllImport(InteropValues.ExternDll.User32, SetLastError = true, CharSet = CharSet.Auto)]
|
||||
internal static extern IntPtr GetForegroundWindow();
|
||||
|
||||
[DllImport(InteropValues.ExternDll.Kernel32, SetLastError = true, CharSet = CharSet.Auto)]
|
||||
internal static extern IntPtr OpenProcess(InteropValues.ProcessAccess dwDesiredAccess,
|
||||
[MarshalAs(UnmanagedType.Bool)] bool bInheritHandle, uint dwProcessId);
|
||||
|
||||
Reference in new issue
Block a user