rn: fix showing Dropbox controls when recording

- remove unneeded dialog (it's taken care of by StartRecordingDialogContent)
- pass correct props so integrations (Dropbox) show up
This commit is contained in:
Saúl Ibarra Corretgé 2019-01-29 12:35:22 +01:00 committed by Saúl Ibarra Corretgé
parent 3cec4989fd
commit 612028ce3c
1 changed files with 3 additions and 10 deletions

View File

@ -4,7 +4,7 @@ import React from 'react';
import { connect } from 'react-redux';
import { translate } from '../../../../base/i18n';
import { ConfirmDialog, CustomSubmitDialog } from '../../../../base/dialog';
import { CustomSubmitDialog } from '../../../../base/dialog';
import AbstractStartRecordingDialog, {
mapStateToProps
@ -27,19 +27,12 @@ class StartRecordingDialog extends AbstractStartRecordingDialog {
const { isTokenValid, isValidating, spaceLeft, userName } = this.state;
const { _isDropboxEnabled } = this.props;
if (!_isDropboxEnabled) {
return (
<ConfirmDialog
contentKey = 'recording.startRecordingBody'
onSubmit = { this._onSubmit } />
);
}
return (
<CustomSubmitDialog
okDisabled = { !isTokenValid }
okDisabled = { _isDropboxEnabled && !isTokenValid }
onSubmit = { this._onSubmit } >
<StartRecordingDialogContent
integrationsEnabled = { _isDropboxEnabled }
isTokenValid = { isTokenValid }
isValidating = { isValidating }
spaceLeft = { spaceLeft }