There are several questions about disabling touchpads on laptops on this site, but none of them seem to quite answer my question.
I want to disable my touchpad (I've done that bit) and keep it disabled after a suspend/resume (I am failing here).
I am running Ubuntu 12.04 on a cheap Chinese laptop.
I have an executable file /home/yannick/bin/notouch which looks like this:
xinput set-prop `xinput list | grep "ImPS/2 Generic" | awk '{print $7}' | sed "s/id=//"` "Device Enabled" 0
The script runs xinput once to get the id number of (what turns out to be) my touchpad, and then runs xinput again to disable the touchpad. I have it in my .bashrc and in other places.
At present, when I suspend and then resume my laptop, the touchpad comes alive again and I really want to stop this happening. So I also have a file
/etc/pm/sleep.d/97disable_touchpad (owned by root, +x) which looks like this:
#!/bin/bash
case "$1" in
thaw|resume)
/home/yannick/bin/notouch 2>/tmp/notoucherrors
;;
*)
;;
esac
exit $?
And darn it, it doesn't work! Indeed the script does seem to run after a resume, and the content of /tmp/notoucherrors is:
Unable to connect to X server
Unable to connect to X server
Dammit I want my touchpad to stay disabled when I hibernate and resume. How do I make this happen?
Here are two other things I tried and that I couldn't get to work:
1) $synclient TouchpadOff=1
This returns
Couldn't find synaptics properties. No synaptics driver loaded?
2) System Settings -> Mouse and Touchpad. I only have options for mouse there (I would even go so far as to say that ubuntu thinks that my touchpad is a mouse for some reason). In particular there is no option to turn the touchpad off -- all I have is mouse options (general, pointer speed, drag and drop, double-click timeout).