Fixes to touch handling