Don't try to detect a touchscreen.

Touch devices and mouselike pointing devices can be connected and
disconnected at any time, so the only good thing to do is accept both
kinds of events.