fixed handling of keypress on touch devices