Fixed a bug when collapsing through clear highlighting.