private static IntPtr SetHook(LowLevelMouseProcess proc) { using (Process curProcess = Process.GetCurrentProcess()) using (ProcessModule curModule = curProcess.MainModule) { return(SetWindowsHookEx(WH_MOUSE_LL, proc, GetModuleHandle(curModule.ModuleName), 0)); } }
private static IntPtr SetHook(LowLevelMouseProcess proc) { using (Process curProcess = Process.GetCurrentProcess()) using (ProcessModule curModule = curProcess.MainModule) { return SetWindowsHookEx(WH_MOUSE_LL, proc, GetModuleHandle(curModule.ModuleName), 0); } }
private static extern IntPtr SetWindowsHookEx(int idHook, LowLevelMouseProcess lpfn, IntPtr hMod, uint dwThreadId);