works for unselected but not selected