implementing save of rotation state