adding events to spinner