Bug fixes to touch support.