Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
R
Rocket.Chat
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Analyze
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
RocketChat
Rocket.Chat
Commits
4b92bc86
Commit
4b92bc86
authored
8 years ago
by
Gyubin Son
Browse files
Options
Downloads
Patches
Plain Diff
Fix the over creation of AudioContexts.
parent
39b20d13
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
packages/rocketchat-webrtc/WebRTCClass.coffee
+6
-3
6 additions, 3 deletions
packages/rocketchat-webrtc/WebRTCClass.coffee
with
6 additions
and
3 deletions
packages/rocketchat-webrtc/WebRTCClass.coffee
+
6
−
3
View file @
4b92bc86
...
...
@@ -228,10 +228,10 @@ class WebRTCClass
if
@
active
isnt
true
or
@
monitor
is
true
or
@
remoteMonitoring
is
true
then
return
remoteConnections
=
[]
for
id
,
peerConnection
s
of
@
peerConnections
for
id
,
peerConnection
of
@
peerConnections
remoteConnections
.
push
id
:
id
media
:
peerConnection
s
.
remoteMedia
media
:
peerConnection
.
remoteMedia
@
transport
.
sendStatus
media
:
@
media
...
...
@@ -340,6 +340,8 @@ class WebRTCClass
stream
.
addTrack
(
peer
.
stream
.
getAudioTracks
()[
0
])
stream
.
volume
=
volume
this
.
audioContext
=
audioContext
onSuccess
(
stream
)
navigator
.
getUserMedia
media
,
onSuccessLocal
,
onError
...
...
@@ -461,7 +463,8 @@ class WebRTCClass
stopAllPeerConnections
:
->
for
id
,
peerConnection
of
@
peerConnections
@
stopPeerConnection
id
@
stopPeerConnection
id
window
.
audioContext
.
close
()
setAudioEnabled
:
(
enabled
=
true
)
->
if
@
localStream
?
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment