Documentation ¶
Index ¶
- Constants
- Variables
- func Utf16PtrTostring(ptr *uint16) string
- type BOOL
- type DWORD
- type HARDWAREINPUT
- type HBRUSH
- type HCURSOR
- type HDROP
- type HHOOK
- type HICON
- type HINSTANCE
- type HWND
- type INPUT
- type KBDLLHOOKSTRUCT
- type KEYBDINPUT
- type LONG
- type LPARAM
- type LPCWSTR
- type LRESULT
- type MOUSEINPUT
- type MSG
- type POINT
- type SHORT
- type SMALL_RECT
- type UINT
- type ULONG
- type ULONG_PTR
- type USHORT
- type WNDCLASSEXW
- type WNDPROC
- type WORD
- type WPARAM
Constants ¶
View Source
const ( FALSE = 0 TRUE = 1 )
View Source
const ( CF_UNICODETEXT = 13 CF_HDROP = 15 )
clipboard format
View Source
const ( SC_MINIMIZE = 0xF020 SC_RESTORE = 0xF120 SC_PREVWINDOW = 0xF050 )
sys command
View Source
const ( WM_NULL = 0x0000 WM_DESTROY = 0x0002 WM_CLIPBOARDUPDATE = 0x0000031D // HWND_MESSAGE = ^uint32(2) WM_QUIT = 0x00000012 WM_KEYDOWN = 0x0100 WM_KEYUP = 0x0101 WM_SYSKEYDOWN = 0x0104 WM_SYSKEYUP = 0x0105 WM_SYSCOMMAND = 0x0112 WM_IME_KEYDOWN = 0x0290 WM_IME_KEYUP = 0x0291 )
WM_XXXX window message
View Source
const ( KEYEVENTF_EXTENDEDKEY = 0x0001 KEYEVENTF_KEYUP = 0x0002 KEYEVENTF_UNICODE = 0x0004 KEYEVENTF_SCANCODE = 0x0008 )
KEYEVENTF
View Source
const ( INPUT_MOUSE = 0 INPUT_KEYBOARD = 1 INPUT_HARDWARE = 2 )
INPUT
View Source
const ( CTRL_C_EVENT = 0 CTRL_BREAK_EVENT = 1 CTRL_CLOSE_EVENT = 2 CTRL_LOGOFF_EVENT = 5 CTRL_SHUTDOWN_EVENT = 6 )
View Source
const CW_USERDEFAULT = 0x80000000
create window
View Source
const (
GHND = 0x0042
)
GlobalAlloc
View Source
const INVALID_HANDLE_VALUE uintptr = ^uintptr(0)
View Source
const (
STD_OUTPUT_HANDLE = 0xFFFFFFF5
)
STD handle
View Source
const (
WH_KEYBOARD_LL = 13
)
windows hook
Variables ¶
View Source
var ( GetLastError = findProc(kernel32Dll, "GetLastError") RegisterClassExW = findProc(user32Dll, "RegisterClassExW") DefWindowProcW = findProc(user32Dll, "DefWindowProcW") CreateWindowExW = findProc(user32Dll, "CreateWindowExW") DestroyWindow = findProc(user32Dll, "DestroyWindow") GetForegroundWindow = findProc(user32Dll, "GetForegroundWindow") SetForegroundWindow = findProc(user32Dll, "SetForegroundWindow") SetFocus = findProc(user32Dll, "SetFocus") SetActiveWindow = findProc(user32Dll, "SetActiveWindow") AddClipboardFormatListener = findProc(user32Dll, "AddClipboardFormatListener") RemoveClipboardFormatListener = findProc(user32Dll, "RemoveClipboardFormatListener") GetClipboardSequenceNumber = findProc(user32Dll, "GetClipboardSequenceNumber") IsClipboardFormatAvailable = findProc(user32Dll, "IsClipboardFormatAvailable") OpenClipboard = findProc(user32Dll, "OpenClipboard") CloseClipboard = findProc(user32Dll, "CloseClipboard") GetClipboardData = findProc(user32Dll, "GetClipboardData") SetClipboardData = findProc(user32Dll, "SetClipboardData") EmptyClipboard = findProc(user32Dll, "EmptyClipboard") DragQueryFileW = findProc(shell32Dll, "DragQueryFileW") SetWindowsHookExW = findProc(user32Dll, "SetWindowsHookExW") UnhookWindowsHookEx = findProc(user32Dll, "UnhookWindowsHookEx") CallNextHookEx = findProc(user32Dll, "CallNextHookEx") GetCurrentThreadId = findProc(kernel32Dll, "GetCurrentThreadId") GlobalAlloc = findProc(kernel32Dll, "GlobalAlloc") GlobalFree = findProc(kernel32Dll, "GlobalFree") GlobalLock = findProc(kernel32Dll, "GlobalLock") GlobalUnlock = findProc(kernel32Dll, "GlobalUnlock") GetModuleHandleW = findProc(kernel32Dll, "GetModuleHandleW") GetConsoleWindow = findProc(kernel32Dll, "GetConsoleWindow") GetStdHandle = findProc(kernel32Dll, "GetStdHandle") SetConsoleWindowInfo = findProc(kernel32Dll, "SetConsoleWindowInfo") SetConsoleCtrlHandler = findProc(kernel32Dll, "SetConsoleCtrlHandler") GetMessageW = findProc(user32Dll, "GetMessageW") TranslateMessage = findProc(user32Dll, "TranslateMessage") DispatchMessageW = findProc(user32Dll, "DispatchMessageW") SendMessageW = findProc(user32Dll, "SendMessageW") PostQuitMessage = findProc(user32Dll, "PostQuitMessage") SendInput = findProc(user32Dll, "SendInput") CopyMemory = findProc(kernel32Dll, "RtlCopyMemory") )
functions
Functions ¶
Types ¶
type HARDWAREINPUT ¶
type KBDLLHOOKSTRUCT ¶
type KEYBDINPUT ¶
type MOUSEINPUT ¶
type WNDCLASSEXW ¶
Click to show internal directories.
Click to hide internal directories.