Files
eveo/Eve-O-Preview/Hotkeys/HotkeyNativeMethods.cs
2016-05-09 19:48:55 +03:00

24 lines
676 B
C#

using System;
using System.Runtime.InteropServices;
using System.Windows.Forms;
namespace EveOPreview
{
static class HotkeyNativeMethods
{
[DllImport("user32.dll", SetLastError = true)]
public static extern int RegisterHotKey(IntPtr hWnd, int id, uint fsModifiers, Keys vk);
[DllImport("user32.dll", SetLastError = true)]
public static extern int UnregisterHotKey(IntPtr hWnd, int id);
public const uint WM_HOTKEY = 0x312;
public const uint MOD_ALT = 0x1;
public const uint MOD_CONTROL = 0x2;
public const uint MOD_SHIFT = 0x4;
public const uint MOD_WIN = 0x8;
public const uint ERROR_HOTKEY_ALREADY_REGISTERED = 1409;
}
}