Save focus/position/selection when saving state