Moving handling of touch events to terminal.