Device selection now always shows the device that it managed to open. (#4384)
* Device selection now always shows the device that managed to open. * Simplifies implementation, skips using state.
This commit is contained in:
parent
bb3a10b0fc
commit
9c1b802997
|
@ -372,7 +372,8 @@ class DeviceSelection extends AbstractDialogTab<Props, State> {
|
||||||
label: 'settings.selectCamera',
|
label: 'settings.selectCamera',
|
||||||
onSelect: selectedVideoInputId =>
|
onSelect: selectedVideoInputId =>
|
||||||
super._onChange({ selectedVideoInputId }),
|
super._onChange({ selectedVideoInputId }),
|
||||||
selectedDeviceId: this.props.selectedVideoInputId
|
selectedDeviceId: this.state.previewVideoTrack
|
||||||
|
? this.state.previewVideoTrack.getDeviceId() : null
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
devices: availableDevices.audioInput,
|
devices: availableDevices.audioInput,
|
||||||
|
@ -384,7 +385,8 @@ class DeviceSelection extends AbstractDialogTab<Props, State> {
|
||||||
label: 'settings.selectMic',
|
label: 'settings.selectMic',
|
||||||
onSelect: selectedAudioInputId =>
|
onSelect: selectedAudioInputId =>
|
||||||
super._onChange({ selectedAudioInputId }),
|
super._onChange({ selectedAudioInputId }),
|
||||||
selectedDeviceId: this.props.selectedAudioInputId
|
selectedDeviceId: this.state.previewAudioTrack
|
||||||
|
? this.state.previewAudioTrack.getDeviceId() : null
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue