Added support for moving video to new window. Fixed various bugs.

This commit is contained in:
Håvar Aambø Fosstveit
2018-11-14 13:23:22 +01:00
parent 0d334d532b
commit e695909911
13 changed files with 188 additions and 12 deletions
+12
View File
@@ -6,6 +6,7 @@ const initialState =
showSettings : false,
advancedMode : false,
fullScreenConsumer : null, // ConsumerID
windowConsumer : null, // ConsumerID
toolbarsVisible : true,
mode : 'democratic',
selectedPeerName : null,
@@ -62,6 +63,17 @@ const room = (state = initialState, action) =>
return { ...state, fullScreenConsumer: currentConsumer ? null : consumerId };
}
case 'TOGGLE_WINDOW_CONSUMER':
{
const { consumerId } = action.payload;
const currentConsumer = state.windowConsumer;
if (currentConsumer === consumerId)
return { ...state, windowConsumer: null };
else
return { ...state, windowConsumer: consumerId };
}
case 'SET_TOOLBARS_VISIBLE':
{
const { toolbarsVisible } = action.payload;