Пример #1
0
 public static bool SetWindowRect(IntPtr hWnd, RECT rect, IntPtr priorWindow)
 {
     return(NativeMethods.SetWindowPos(hWnd, priorWindow, rect.Left, rect.Top, rect.Right - rect.Left, rect.Bottom - rect.Top, NativeMethods.SWP_Flags.SWP_ASYNCWINDOWPOS | NativeMethods.SWP_Flags.SWP_NOACTIVE));
 }
Пример #2
0
 public static uint GetWindowThread(IntPtr hWnd)
 {
     // new UIPermission(UIPermissionWindow.AllWindows).Demand();
     return(NativeMethods.GetWindowThreadProcessId(hWnd, IntPtr.Zero));
 }
Пример #3
0
 public static IntPtr GetNextWindow(IntPtr hOriginalWindow)
 {
     return(NativeMethods.GetWindow(hOriginalWindow, NativeMethods.GW_Command.GW_HWNDNEXT));
 }
Пример #4
0
 public static bool WinEventUnhook(IntPtr hWinEventHook) =>
 NativeMethods.UnhookWinEvent(hWinEventHook);