Save timeline state when changing mark type