无法禁用xinput

我正试图用xinput禁用我的触摸屏。

运行的输出是xinput --list

 Virtual core pointer id=2 [master pointer (3)] ⎜ ↳ Virtual core XTEST pointer id=4 [slave pointer (2)] ⎜ ↳ ELAN0B00:00 04F3:306A Touchpad id=12 [slave pointer (2)] ⎜ ↳ WCOM0033:00 2D1F:001E Pen (0) id=16 [slave pointer (2)] ⎜ ↳ G2Touch Multi-Touch by G2TSP id=11 [slave pointer (2)] ⎣ Virtual core keyboard id=3 [master keyboard (2)] ↳ Virtual core XTEST keyboard id=5 [slave keyboard (3)] ↳ Power Button id=6 [slave keyboard (3)] ↳ Video Bus id=7 [slave keyboard (3)] ↳ Power Button id=8 [slave keyboard (3)] ↳ 720p HD Camera id=9 [slave keyboard (3)] ↳ 720p HD Camera id=10 [slave keyboard (3)] ↳ WCOM0033:00 2D1F:001E id=13 [slave keyboard (3)] ↳ Intel Virtual Button driver id=14 [slave keyboard (3)] ↳ AT Translated Set 2 keyboard id=15 [slave keyboard (3)] 

我的设备似乎是id=11 ,所以我运行:

xinput disable 11

运行后,它被禁用,直到我使用触摸屏,然后5秒后自动重新启用? 如何永久禁用触摸屏。

我已经通过几种方法来禁用我的触摸屏 – 这对我来说似乎最干净,在Ubuntu 17.10中是编辑文件“/usr/share/X11/xorg.conf.d/40-libinput.conf”并修改涉及触摸屏的部分:

 sudo nano /usr/share/X11/xorg.conf.d/40-libinput.conf 

滚动到有关触摸屏的部分,并在“’上添加”选项“忽略”“ – 部分内容将如下所示

 Section "InputClass" Identifier "libinput touchscreen catchall" MatchIsTouchscreen "on" MatchDevicePath "/dev/input/event*" Driver "libinput" Option "Ignore" "on" #Disable loading the touchscreen EndSection 

参见man xorg.conf ,这个选项向xorg表明“应该完全忽略设备,而不是添加到服务器”。