Unable to disable xinput

I'm trying to disable my touch screen with xinput.

The output of running is 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)]

My device seems to be id=11, so I run:

xinput disable 11

After running this it gets disabled until I use the touch screen then 5 seconds later gets re-enabled automatically?? How can I permanently disable touch screen.


I've run through a couple of ways to disable my touchscreen - the one that seems cleanest for me, in Ubuntu 17.10 is to edit the file "/usr/share/X11/xorg.conf.d/40-libinput.conf" and modify the section referring to touchscreens:

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

Scroll to the section about touchscreens, and add the line 'Option "Ignore" "on"' - the section contents will look like

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

see man xorg.conf, this option indicates to xorg that "the device should be ignored entirely, and not added to the server."