Пример #1
0
VOID InitSystemHotKeys(VOID)
{
#if DEVL        // only on "development" checked and free builds
    {
    extern KEYBOARD_ATTRIBUTES KeyboardInfo;
    UINT VkDebug;

    VkDebug = FastGetProfileDwordW(PMAP_AEDEBUG, L"UserDebuggerHotkey", 0);

    if (VkDebug == 0) {
        if (ENHANCED_KEYBOARD(KeyboardInfo.KeyboardIdentifier)) {
            VkDebug = VK_F12;
        } else {
            VkDebug = VK_SUBTRACT;
        }
    } else {
        UserAssert((0xFFFFFF00 & VkDebug) == 0);
    }

    _RegisterHotKey(PWND_INPUTOWNER, IDHOT_DEBUG, 0, VkDebug);
    _RegisterHotKey(PWND_INPUTOWNER, IDHOT_DEBUGSERVER, MOD_SHIFT, VkDebug);
    }
#endif
    /*
     * Tapping a Windows key does something to the shell
     */
    _RegisterHotKey(PWND_INPUTOWNER, IDHOT_WINDOWS, MOD_WIN, VK_NONE);
}
Пример #2
0
VOID FASTCALL
StartDebugHotKeys(VOID)
{
    UINT vk = VK_F12;
    UserUnregisterHotKey(PWND_BOTTOM, IDHK_F12);
    UserUnregisterHotKey(PWND_BOTTOM, IDHK_SHIFTF12);
    if (!ENHANCED_KEYBOARD(gKeyboardInfo.KeyboardIdentifier))
    {
        vk = VK_SUBTRACT;
    }
    UserRegisterHotKey(PWND_BOTTOM, IDHK_SHIFTF12, MOD_SHIFT, vk);
    UserRegisterHotKey(PWND_BOTTOM, IDHK_F12, 0, vk);
    TRACE("Start up the debugger hotkeys!! If you see this you eneabled debugprints. Congrats!\n");
}