Changeset View
Changeset View
Standalone View
Standalone View
src/resources/js/meet/app.js
Show First 20 Lines • Show All 814 Lines • ▼ Show 20 Lines | function connectionUpdate(data) { | ||||
if ('role' in data && !isPublisher && rolePublisher) { | if ('role' in data && !isPublisher && rolePublisher) { | ||||
publisher.createVideoElement(sessionData.element, 'PREPEND') | publisher.createVideoElement(sessionData.element, 'PREPEND') | ||||
session.publish(publisher).then(() => { | session.publish(publisher).then(() => { | ||||
data.audioActive = publisher.stream.audioActive | data.audioActive = publisher.stream.audioActive | ||||
data.videoActive = publisher.stream.videoActive | data.videoActive = publisher.stream.videoActive | ||||
update() | update() | ||||
}) | }) | ||||
// TODO: Here the user is asked for media permissions again | // Open the media setup dialog | ||||
// should we rather start the stream without asking the user? | // Note: If user didn't give permission to media before joining the room | ||||
// Or maybe we want to display the media setup/preview form? | // he will not be able to use them now. Changing permissions requires | ||||
// Need to find a way to do this. | // a page refresh. | ||||
vanmeeuwen: You mean, if the user previously denied the permission to media, right? | |||||
Done Inline ActionsIf user denied access to the media he will not be asked again. This requires a page refresh. machniak: If user denied access to the media he will not be asked again. This requires a page refresh.
If… | |||||
// Note: In Firefox I'm always being asked again for media permissions. | |||||
// It does not happen in Chrome. In Chrome the cam/mic will be just re-used. | |||||
// I.e. streaming starts automatically. | |||||
// It might make sense to not start streaming automatically in any cirmustances, | |||||
// display the dialog and wait until user closes it, but this would be | |||||
// a bigger refactoring. | |||||
if (sessionData.onMediaSetup) { | |||||
sessionData.onMediaSetup() | |||||
} | |||||
} else { | } else { | ||||
// Inform the vue component, so it can update some UI controls | // Inform the vue component, so it can update some UI controls | ||||
update() | update() | ||||
} | } | ||||
} else if (conn) { | } else if (conn) { | ||||
// merge the changed data into internal session metadata object | // merge the changed data into internal session metadata object | ||||
Object.keys(data).forEach(key => { conn[key] = data[key] }) | Object.keys(data).forEach(key => { conn[key] = data[key] }) | ||||
▲ Show 20 Lines • Show All 568 Lines • Show Last 20 Lines |
You mean, if the user previously denied the permission to media, right?