Adds an onpress event to xtags