Shortcut.HotkeyBinder.RegisterHotkey C# (CSharp) Method

RegisterHotkey() private method

private RegisterHotkey ( System.Windows.Forms.Hotkey hotkeyCombo ) : void
hotkeyCombo System.Windows.Forms.Hotkey
return void
        private void RegisterHotkey(Hotkey hotkeyCombo)
        {
            bool successful =
                NativeMethods.RegisterHotKey(
                    hotkeyWindow.Handle,
                    hotkeyCombo.GetHashCode(),
                    (uint)hotkeyCombo.Modifier,
                    (uint)hotkeyCombo.Key);

            if (!successful)
                throw new Win32Exception(Marshal.GetLastWin32Error());
        }