Skip to content

Commit

Permalink
add lock/unlock
Browse files Browse the repository at this point in the history
  • Loading branch information
jpsantosbh committed Jun 28, 2024
1 parent 252cb30 commit adefd23
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 0 deletions.
10 changes: 10 additions & 0 deletions public/full.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,8 @@ const inCallElements = [
unmuteSelfBtn,
muteVideoSelfBtn,
unmuteVideoSelfBtn,
lockCallBtn,
unlockCallBtn,
deafSelfBtn,
undeafSelfBtn,
controlSliders,
Expand Down Expand Up @@ -800,6 +802,14 @@ window.unmuteVideoSelf = () => {
roomObj.videoUnmute()
}

window.lockCall = () => {
roomObj.lock()
}

window.unlockCall = () => {
roomObj.unlock()
}

window.deafSelf = () => {
roomObj.deaf()
}
Expand Down
10 changes: 10 additions & 0 deletions views/index.ejs
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,16 @@
</button>
</div>

<div class="btn-group w-100" role="group">
<button id="lockCallBtn" class="btn btn-warning px-3 mt-2" onClick="lockCall()" disabled="true">
lock room
</button>
<button id="unlockCallBtn" class="btn btn-warning px-3 mt-2" onClick="unlockCall()"
disabled="true">
unlock room
</button>
</div>

<div class="btn-group w-100" role="group">
<button id="deafSelfBtn" class="btn btn-warning px-3 mt-2" onClick="deafSelf()" disabled="true">
Deaf Self
Expand Down

0 comments on commit adefd23

Please sign in to comment.