feat(rn,overflow-menu) remove duplicated buttons from overflow menu
The audio route selector is how in the header. The mute options are in the participants pane, with the rest of the moderation controls.
This commit is contained in:
parent
8236764501
commit
9c5b5e5b75
|
@ -1,40 +0,0 @@
|
|||
// @flow
|
||||
|
||||
import { openDialog } from '../../../base/dialog';
|
||||
import { translate } from '../../../base/i18n';
|
||||
import { IconAudioRoute } from '../../../base/icons';
|
||||
import { connect } from '../../../base/redux';
|
||||
import { AbstractButton, type AbstractButtonProps } from '../../../base/toolbox/components';
|
||||
|
||||
import AudioRoutePickerDialog from './AudioRoutePickerDialog';
|
||||
|
||||
|
||||
type Props = AbstractButtonProps & {
|
||||
|
||||
/**
|
||||
* The redux {@code dispatch} function used to open/show the
|
||||
* {@code AudioRoutePickerDialog}.
|
||||
*/
|
||||
dispatch: Function
|
||||
};
|
||||
|
||||
/**
|
||||
* A toolbar button which triggers an audio route picker when pressed.
|
||||
*/
|
||||
class AudioRouteButton extends AbstractButton<Props, *> {
|
||||
accessibilityLabel = 'toolbar.accessibilityLabel.audioRoute';
|
||||
icon = IconAudioRoute;
|
||||
label = 'toolbar.audioRoute';
|
||||
|
||||
/**
|
||||
* Handles clicking / pressing the button, and opens the appropriate dialog.
|
||||
*
|
||||
* @private
|
||||
* @returns {void}
|
||||
*/
|
||||
_handleClick() {
|
||||
this.props.dispatch(openDialog(AudioRoutePickerDialog));
|
||||
}
|
||||
}
|
||||
|
||||
export default translate(connect()(AudioRouteButton));
|
|
@ -1 +0,0 @@
|
|||
export { default as AudioRouteButton } from './AudioRouteButton';
|
|
@ -8,7 +8,6 @@ import { BottomSheet, hideDialog, isDialogOpen } from '../../../base/dialog';
|
|||
import { connect } from '../../../base/redux';
|
||||
import { StyleType } from '../../../base/styles';
|
||||
import { SharedDocumentButton } from '../../../etherpad';
|
||||
import { AudioRouteButton } from '../../../mobile/audio-mode';
|
||||
import { ParticipantsPaneButton } from '../../../participants-pane/components/native';
|
||||
import { ReactionMenu } from '../../../reactions/components';
|
||||
import { isReactionsEnabled } from '../../../reactions/functions.any';
|
||||
|
@ -22,8 +21,6 @@ import { TileViewButton } from '../../../video-layout';
|
|||
import styles from '../../../video-menu/components/native/styles';
|
||||
import { getMovableButtons } from '../../functions.native';
|
||||
import HelpButton from '../HelpButton';
|
||||
import MuteEveryoneButton from '../MuteEveryoneButton';
|
||||
import MuteEveryonesVideoButton from '../MuteEveryonesVideoButton';
|
||||
|
||||
import AudioOnlyButton from './AudioOnlyButton';
|
||||
import RaiseHandButton from './RaiseHandButton';
|
||||
|
@ -140,16 +137,13 @@ class OverflowMenu extends PureComponent<Props, State> {
|
|||
renderFooter = { _reactionsEnabled && !toolbarButtons.has('raisehand')
|
||||
? this._renderReactionMenu
|
||||
: null }>
|
||||
<AudioRouteButton { ...topButtonProps } />
|
||||
<ParticipantsPaneButton { ...buttonProps } />
|
||||
<ParticipantsPaneButton { ...topButtonProps } />
|
||||
<AudioOnlyButton { ...buttonProps } />
|
||||
{!_reactionsEnabled && !toolbarButtons.has('raisehand') && <RaiseHandButton { ...buttonProps } />}
|
||||
<Divider style = { styles.divider } />
|
||||
<SecurityDialogButton { ...buttonProps } />
|
||||
<RecordButton { ...buttonProps } />
|
||||
<LiveStreamButton { ...buttonProps } />
|
||||
<MuteEveryoneButton { ...buttonProps } />
|
||||
<MuteEveryonesVideoButton { ...buttonProps } />
|
||||
<Divider style = { styles.divider } />
|
||||
<SharedVideoButton { ...buttonProps } />
|
||||
<ScreenSharingButton { ...buttonProps } />
|
||||
|
|
Loading…
Reference in New Issue