[mirotalk] - fix typo

This commit is contained in:
Miroslav Pejic
2021-01-11 19:27:47 +01:00
parent 2a88f255bf
commit 7e68c20f4f
3 changed files with 15 additions and 15 deletions
+10 -10
View File
@@ -84,11 +84,11 @@ function initPeer() {
signalingSocket.on("connect", function () {
console.log("Connected to signaling server");
setup_local_media(function () {
setupLocalMedia(function () {
/* once the user has given us access to their
* microphone/camcorder, join the channel
* and start peering up */
joinChannel(room_id, peerInfo);
joinToChannel(room_id, peerInfo);
});
});
@@ -109,7 +109,7 @@ function initPeer() {
});
// join to chennel and send some peer info
function joinChannel(channel, peerInfo) {
function joinToChannel(channel, peerInfo) {
console.log("join to channel", channel);
signalingSocket.emit("join", {
channel: channel,
@@ -317,7 +317,7 @@ function initPeer() {
// =====================================================
// Local media stuff
// =====================================================
function setup_local_media(callback, errorback) {
function setupLocalMedia(callback, errorback) {
/* ie, if we've already been initialized do nothing */
if (localMediaStream != null) {
if (callback) callback();
@@ -394,20 +394,20 @@ function setup_local_media(callback, errorback) {
// WebRTC buttons
// =====================================================
function manageButtons() {
copyBtn();
copyRoomBtn();
audioBtn();
videoBtn();
swapCameraBtn();
screenShareBtn();
endCallBtn();
leaveRoomBtn();
buttonsOpacity();
}
// =====================================================
// copy Room URL button click event
// =====================================================
function copyBtn() {
document.getElementById("copyBtn").addEventListener("click", (e) => {
function copyRoomBtn() {
document.getElementById("copyRoomBtn").addEventListener("click", (e) => {
copyRoomURL();
});
}
@@ -475,8 +475,8 @@ function screenShareBtn() {
// =====================================================
// end call button click event
// =====================================================
function endCallBtn() {
document.getElementById("endCallBtn").addEventListener("click", (e) => {
function leaveRoomBtn() {
document.getElementById("leaveRoomBtn").addEventListener("click", (e) => {
leaveRoom();
});
}
+3 -3
View File
@@ -57,7 +57,7 @@
<body onload="initPeer()">
<div id="buttons">
<!-- https://fontawesome.com/icons?d=gallery -->
<button title="share room" id="copyBtn" class="fas fa-users"></button>
<button title="share room" id="copyRoomBtn" class="fas fa-users"></button>
<button title="audio" id="audioBtn" class="fas fa-microphone"></button>
<button title="video" id="videoBtn" class="fas fa-video"></button>
<button
@@ -71,8 +71,8 @@
class="fas fa-desktop"
></button>
<button
title="end call"
id="endCallBtn"
title="leave room"
id="leaveRoomBtn"
class="fas fa-phone-slash"
></button>
</div>
+2 -2
View File
@@ -142,12 +142,12 @@ button:hover {
width: 40px;
}
#copyBtn,
#copyRoomBtn,
#audioBtn,
#videoBtn,
#swapCameraBtn,
#screenShareBtn,
#endCallBtn {
#leaveRoomBtn {
font-size: 2rem;
cursor: pointer;
}