private void SetActiveCameraView(CameraView view, Action onViewSetupCompleted = null) { if (ActiveView != null) { if (ActiveView.GetType() != view.GetType()) { ActiveView.Disable(); GC.SuppressFinalize((object)ActiveView); ActiveView = view; ActiveView.Enable(onViewSetupCompleted); OnCameraViewChanged?.Invoke(view); } } else { ActiveView = view; ActiveView.Enable(onViewSetupCompleted); OnCameraViewChanged?.Invoke(view); } }
/// Returns whether the current view is the normal one, i.e., the view from above public bool IsNormalView() => cameraView.GetType() == typeof(NormalView);