From fc27469b97cf5baa44e639ac4d07400b4f598b23 Mon Sep 17 00:00:00 2001 From: Christian Helmuth Date: Mon, 29 Apr 2024 15:31:20 +0200 Subject: [PATCH] sculpt: remap KEY_SYSRQ to KEY_PRINT Both keys are physically the same on available keyboards (with varying labeling). Unfortunately, PS/2 scancode sets and USB HID spec seem to differ slightly in their interpretation. Therefore, we keep the driver-level reporting as is but report both as KEY_PRINT in Sculpt, which allows to use the key(s) for screenshoter rules most prominently. Also, unify sculpt/event_filter/pc with sculpt_manager. --- repos/gems/sculpt/event_filter/pc | 4 ++-- repos/gems/src/app/sculpt_manager/main.cc | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/repos/gems/sculpt/event_filter/pc b/repos/gems/sculpt/event_filter/pc index 52e433e32c..480f842ba4 100644 --- a/repos/gems/sculpt/event_filter/pc +++ b/repos/gems/sculpt/event_filter/pc @@ -2,10 +2,10 @@ - - + + diff --git a/repos/gems/src/app/sculpt_manager/main.cc b/repos/gems/src/app/sculpt_manager/main.cc index 54282426c4..9d513df43d 100644 --- a/repos/gems/src/app/sculpt_manager/main.cc +++ b/repos/gems/src/app/sculpt_manager/main.cc @@ -2388,6 +2388,7 @@ void Sculpt::Main::_generate_event_filter_config(Xml_generator &xml) gen_key("KEY_CAPSLOCK", "KEY_CAPSLOCK"); gen_key("KEY_F12", "KEY_DASHBOARD"); gen_key("KEY_LEFTMETA", "KEY_SCREEN"); + gen_key("KEY_SYSRQ", "KEY_PRINT"); gen_include("numlock.remap"); xml.node("merge", [&] {