Definition at line 11 of file Win32.cs.
◆ GetActiveWindowTitle()
| static string BioImager.Win32.GetActiveWindowTitle |
( |
| ) |
|
|
static |
It gets the title of the active window
- Returns
- The title of the active window.
Definition at line 90 of file Win32.cs.
91 {
92 const int nChars = 256;
93 StringBuilder Buff = new StringBuilder(nChars);
95
97 {
98 return Buff.ToString();
99 }
100 return null;
101 }
static IntPtr GetForegroundWindow()
static int GetWindowText(IntPtr hWnd, StringBuilder text, int count)
◆ GetAsyncKeyState()
| static short BioImager.Win32.GetAsyncKeyState |
( |
System.Windows.Forms.Keys | vKey | ) |
|
◆ GetForegroundWindow()
| static IntPtr BioImager.Win32.GetForegroundWindow |
( |
| ) |
|
◆ GetKeyState()
| static bool BioImager.Win32.GetKeyState |
( |
System.Windows.Forms.Keys | vKey | ) |
|
|
static |
It returns true if the key is pressed, and false if it isn't
- Parameters
-
| vKey | The key you want to check. |
- Returns
- The return value is a short integer with the high order bit set if the key is down and the low order bit set if the key was pressed after the previous call to GetAsyncKeyState.
Definition at line 24 of file Win32.cs.
25 {
27 if (si == 0)
28 return false;
29 else
30 return true;
31 }
static short GetAsyncKeyState(System.Windows.Forms.Keys vKey)
◆ GetWindowRect()
| static bool BioImager.Win32.GetWindowRect |
( |
IntPtr | hwnd, |
|
|
ref Rect | rectangle ) |
◆ GetWindowText()
| static int BioImager.Win32.GetWindowText |
( |
IntPtr | hWnd, |
|
|
StringBuilder | text, |
|
|
int | count ) |
◆ mouse_event()
| static void BioImager.Win32.mouse_event |
( |
int | dwFlags, |
|
|
int | dx, |
|
|
int | dy, |
|
|
int | dwData, |
|
|
int | dwExtraInfo ) |
◆ MouseWheelDown()
| static void BioImager.Win32.MouseWheelDown |
( |
| ) |
|
|
static |
MouseWheelDown() simulates a mouse wheel down event.
Definition at line 73 of file Win32.cs.
74 {
76 }
const int MOUSEEVENTF_WHEEL
static void mouse_event(int dwFlags, int dx, int dy, int dwData, int dwExtraInfo)
◆ MouseWheelUp()
| static void BioImager.Win32.MouseWheelUp |
( |
| ) |
|
|
static |
"MouseWheelUp()" is a function that simulates a mouse wheel up event.
Definition at line 68 of file Win32.cs.
◆ SetFocus()
| static void BioImager.Win32.SetFocus |
( |
string | process | ) |
|
|
static |
It gets the process by name, then sets the foreground window to the process's main window handle
- Parameters
-
| process | The name of the process you want to focus on. |
Definition at line 81 of file Win32.cs.
82 {
83 Process pr = Process.GetProcessesByName(process)[0];
85 }
static bool SetForegroundWindow(IntPtr hWnd)
◆ SetForegroundWindow()
| static bool BioImager.Win32.SetForegroundWindow |
( |
IntPtr | hWnd | ) |
|
◆ MOUSEEVENTF_ABSOLUTE
| const int BioImager.Win32.MOUSEEVENTF_ABSOLUTE = 0x8000 |
|
static |
◆ MOUSEEVENTF_HWHEEL
| const int BioImager.Win32.MOUSEEVENTF_HWHEEL =0x01000 |
|
static |
◆ MOUSEEVENTF_LEFTDOWN
| const int BioImager.Win32.MOUSEEVENTF_LEFTDOWN = 0x0002 |
|
static |
◆ MOUSEEVENTF_LEFTUP
| const int BioImager.Win32.MOUSEEVENTF_LEFTUP = 0x0004 |
|
static |
◆ MOUSEEVENTF_MIDDLEDOWN
| const int BioImager.Win32.MOUSEEVENTF_MIDDLEDOWN = 0x0020 |
|
static |
◆ MOUSEEVENTF_MIDDLEUP
| const int BioImager.Win32.MOUSEEVENTF_MIDDLEUP =0x0040 |
|
static |
◆ MOUSEEVENTF_MOVE
| const int BioImager.Win32.MOUSEEVENTF_MOVE =0x0001 |
|
static |
◆ MOUSEEVENTF_RIGHTDOWN
| const int BioImager.Win32.MOUSEEVENTF_RIGHTDOWN =0x0008 |
|
static |
◆ MOUSEEVENTF_RIGHTUP
| const int BioImager.Win32.MOUSEEVENTF_RIGHTUP =0x0010 |
|
static |
◆ MOUSEEVENTF_WHEEL
| const int BioImager.Win32.MOUSEEVENTF_WHEEL = 0x0800 |
|
static |
◆ MOUSEEVENTF_XDOWN
| const int BioImager.Win32.MOUSEEVENTF_XDOWN =0x0080 |
|
static |
◆ MOUSEEVENTF_XUP
| const int BioImager.Win32.MOUSEEVENTF_XUP =0x0100 |
|
static |
◆ WM_KEYDOWN
| const int BioImager.Win32.WM_KEYDOWN = 0x100 |
|
static |
◆ WM_KEYUP
| const int BioImager.Win32.WM_KEYUP = 0x101 |
|
static |
The documentation for this class was generated from the following file: