copy indexes for undo because it may be a mutable indexset that's changed
copy indexes for undo because it may be a mutable indexset that's changed

JackieXie168/skim,JackieXie168/skim,JackieXie168/skim,JackieXie168/skim,JackieXie168/skim