Fix selection change on deletion bug.