pauseVideoRecording method

void pauseVideoRecording()

Implementation

void pauseVideoRecording() async {
  if (!initialized) {
    _uiHandler.showSnackBar('Couldn\'t find the camera!');
    return;
  }

  if (value.isRecordingVideo) {
    try {
      await controller.pauseVideoRecording();

      value = value.copyWith(isRecordingPaused: true);
    } on CameraException catch (e) {
      _uiHandler.showExceptionSnackbar(e);
      rethrow;
    }
  } else {
    _uiHandler.showSnackBar('Recording not found!');
    return;
  }
}