Attaching proper events for touch/desktop