예제 #1
0
 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);
     }
 }
예제 #2
0
 /// Returns whether the current view is the normal one, i.e., the view from above
 public bool IsNormalView() => cameraView.GetType() == typeof(NormalView);