Updated handling of video/audio devices. Save devices to cookie.

This commit is contained in:
Håvar Aambø Fosstveit
2019-04-05 13:32:45 +02:00
parent 5c9ee3a495
commit 0b9e1ca7b9
5 changed files with 175 additions and 115 deletions
-16
View File
@@ -8,9 +8,7 @@ const initialState =
canSendWebcam : false,
canShareScreen : false,
needExtension : false,
canChangeAudioDevice : false,
audioDevices : null,
canChangeWebcam : false,
webcamDevices : null,
webcamInProgress : false,
audioInProgress : false,
@@ -81,13 +79,6 @@ const me = (state = initialState, action) =>
return { ...state, canShareScreen, needExtension };
}
case 'SET_CAN_CHANGE_AUDIO_DEVICE':
{
const canChangeAudioDevice = action.payload;
return { ...state, canChangeAudioDevice };
}
case 'SET_AUDIO_DEVICES':
{
const { devices } = action.payload;
@@ -95,13 +86,6 @@ const me = (state = initialState, action) =>
return { ...state, audioDevices: devices };
}
case 'SET_CAN_CHANGE_WEBCAM':
{
const canChangeWebcam = action.payload;
return { ...state, canChangeWebcam };
}
case 'SET_WEBCAM_DEVICES':
{
const { devices } = action.payload;