From 19ac844e90c01d9756a1b67c455d0da0bd3bfc35 Mon Sep 17 00:00:00 2001 From: Spoike Date: Fri, 7 Jun 2019 22:19:49 +0000 Subject: [PATCH] Only activate the low-level keyboard hook if one of the relevant cvars is enabled. git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@5471 fc73d0e0-1445-4013-8a0c-d673dee63da5 --- engine/client/sys_win.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/engine/client/sys_win.c b/engine/client/sys_win.c index 03ae19d50..ef470791c 100644 --- a/engine/client/sys_win.c +++ b/engine/client/sys_win.c @@ -1076,6 +1076,9 @@ LRESULT CALLBACK LowLevelKeyboardProc (INT nCode, WPARAM wParam, LPARAM lParam) void SetHookState(qboolean state) { + if (!sys_disableTaskSwitch.ival && !sys_disableWinKeys.ival) + state = false; + if (!state == !llkeyboardhook) //not so types are comparable return;