自检完成后再启动会议

This commit is contained in:
cxc
2022-09-19 14:53:32 +08:00
parent 5197517ad2
commit 7f1a17c8e8
4 changed files with 15 additions and 8 deletions

View File

@ -72,7 +72,6 @@ const isVideoAvailable = ref(undefined);
const isAudioAvailable = ref(undefined);
const videoStream = ref(null);
const audioStream = ref(null);
// TODO:可能有摄像头占用问题。
onMounted(() => {
nextTick(async () => {
@ -100,14 +99,22 @@ onMounted(() => {
}
});
});
const emit = defineEmits(["close"]);
const close = () => {
try {
videoStream.value.getTracks().forEach((track) => track.stop());
} catch (error) {
console.log(error);
}
try {
audioStream.value.getTracks().forEach((track) => track.stop());
} catch (error) {
console.log(error);
}
showCheckMediaVideo.value = false;
emit("close");
};
</script>
<style lang="scss" scoped>

View File

@ -127,7 +127,7 @@
</template>
</el-dialog>
<mediaCheck />
<mediaCheck @close="startMeeting" />
<questions
mode="1"
@ -855,7 +855,7 @@ onMounted(() => {
handleFullscreenChange
);
setTextLabel();
startMeeting();
// startMeeting();
});
// 当修改窗口尺寸时
window.addEventListener("resize", (e) => {