Another attempt to fix key press issue