renamed "text-selected" event handler