2025/3/30

Disable Touchpad while Typing

很奇怪,gigabyte 的 AORUS 15X 在 ubuntu 24.04 下,dconf 的 "disable touchpad while typing" 功能竟然沒有用。
所以只好自己(請 gemini) 寫。 用 python 寫的。
停止 typing 到 re-enable touch 的時間有點太長。
但是改短threading.Timer( ) 的時間好像沒用 (resolution 好像不夠)。
叫 gemnini 用 c 寫,他說很複雜,用 kernel driver 他說最好不要。
所以只好將就用這個。

內容很簡單,就是 keyboard listener, on key press, disable touch and enable a timer.
timer timeout 的時候 re-enable touch

沒有留言:

張貼留言