如何禁用触摸屏

如何禁用触摸屏

我有一台东芝笔记本电脑,它的触摸屏已经破裂且损坏。如何在 Ubuntu 14.04.2 中禁用触摸屏?

答案1

您需要运行xinput命令来确定触摸屏的 ID,然后xinput disable x在每次启动时运行,其中 x 是 ID 号。来源:https://askubuntu.com/a/581334/295286

答案2

我也看到过,运行(xinput –list)从生成的列表中识别触摸屏

然后运行以下行来禁用:xinput –disable “触摸屏名称”

运行此行将启用它:xinput –enable “触摸屏名称”

答案3

这个脚本对我有用。我的 Hp Envy 360 触摸屏在事故后破裂了,但主屏幕工作正常(到目前为止)

\#!/bin/bash

OIFS=$IFS


\# note that the pen didnt show up until I mapped the standard one or clicked the screen. - [ this comment only relevant for digitiser pens.]
\# so need to do that first


list=$(xinput | grep $search | grep pointer)
echo "list $list"

\# extract the ids from the list, id's are needed and can change at the next login/boot
\# my Hp envy touchscreen is ELAN0732:00 which is the first column  of # "xinput" .
 Change it to yours here

device_id=$(echo "$list" | sed -n 's/.*ELAN0732:00.*id=\ 
([0-9]*\).*/\1/p')


for i in $device_id
do
echo "id is $i"
xinput disable $i 
done

保存脚本,使其可执行,超级键,输入start,选择启动应用程序,选择添加,给它命名,命令是 -

bash "/yourpath/yourscriptname.sh"

相关内容