Triggers an event on selection changes