Fix the animation bug in heapSortAnim.