-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make media mode the default in touchbar
- Loading branch information
1 parent
d91dd5b
commit b1f5c1f
Showing
2 changed files
with
9 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,5 @@ | ||
From 006a51516285ebaa8333d19fb76efbc81e5cdb3e Mon Sep 17 00:00:00 2001 | ||
From: Aditya Garg <[email protected]> | ||
Date: Fri, 9 Aug 2024 19:40:53 +0530 | ||
Subject: [PATCH] HID: hid-appletb-kbd: add support for fn toggle between media | ||
and function mode | ||
|
||
HID: hid-appletb-kbd: add support for fn toggle between media and function mode | ||
This patch adds support for the switching between the Media and Function | ||
keys on the touchbar by pressing the Fn key on Apple Internal Keyboard. | ||
|
||
|
@@ -13,7 +9,7 @@ Signed-off-by: Aditya Garg <[email protected]> | |
1 file changed, 128 insertions(+) | ||
|
||
diff --git a/drivers/hid/hid-appletb-kbd.c b/drivers/hid/hid-appletb-kbd.c | ||
index e07d57573..ec8051dcf 100644 | ||
index ecac68fc7..442c4d884 100644 | ||
--- a/drivers/hid/hid-appletb-kbd.c | ||
+++ b/drivers/hid/hid-appletb-kbd.c | ||
@@ -26,6 +26,8 @@ | ||
|
@@ -24,10 +20,10 @@ index e07d57573..ec8051dcf 100644 | |
+ | ||
#define HID_USAGE_MODE 0x00ff0004 | ||
|
||
static int appletb_tb_def_mode = APPLETB_KBD_MODE_FN; | ||
static int appletb_tb_def_mode = APPLETB_KBD_MODE_SPCL; | ||
@@ -35,11 +37,18 @@ MODULE_PARM_DESC(mode, "Default touchbar mode:\n" | ||
" [1] - function-keys only\n" | ||
" 2 - special keys only"); | ||
" 1 - function-keys\n" | ||
" [2] - special keys"); | ||
|
||
+static bool appletb_tb_fn_toggle = true; | ||
+module_param_named(fntoggle, appletb_tb_fn_toggle, bool, 0644); | ||
|