cleans up touch code
cleans declaration of variables in touch code