update howler to work correctly
This commit is contained in:
parent
dd21eb49da
commit
35091cd1ce
1 changed files with 8 additions and 7 deletions
|
@ -37,6 +37,7 @@ const Realtime = {
|
||||||
disconnected: false,
|
disconnected: false,
|
||||||
chatOpen: false,
|
chatOpen: false,
|
||||||
status: true, // stores whether realtime is True/On or False/Off,
|
status: true, // stores whether realtime is True/On or False/Off,
|
||||||
|
soundId: null,
|
||||||
broadcastingStatus: false,
|
broadcastingStatus: false,
|
||||||
inConversation: false,
|
inConversation: false,
|
||||||
localVideo: null,
|
localVideo: null,
|
||||||
|
@ -328,8 +329,8 @@ const Realtime = {
|
||||||
invitedToCall: function (inviter) {
|
invitedToCall: function (inviter) {
|
||||||
var self = Realtime
|
var self = Realtime
|
||||||
|
|
||||||
self.room.chat.sound.stop('sessioninvite')
|
self.room.chat.sound.stop(self.soundId)
|
||||||
self.room.chat.sound.play('sessioninvite')
|
self.soundId = self.room.chat.sound.play('sessioninvite')
|
||||||
|
|
||||||
var username = self.mappersOnMap[inviter].name
|
var username = self.mappersOnMap[inviter].name
|
||||||
var notifyText = '<img src="' + Metamaps.Erb['junto_spinner_darkgrey.gif'] + '" style="display: inline-block; margin-top: -12px; vertical-align: top;" />'
|
var notifyText = '<img src="' + Metamaps.Erb['junto_spinner_darkgrey.gif'] + '" style="display: inline-block; margin-top: -12px; vertical-align: top;" />'
|
||||||
|
@ -341,8 +342,8 @@ const Realtime = {
|
||||||
invitedToJoin: function (inviter) {
|
invitedToJoin: function (inviter) {
|
||||||
var self = Realtime
|
var self = Realtime
|
||||||
|
|
||||||
self.room.chat.sound.stop('sessioninvite')
|
self.room.chat.sound.stop(self.soundId)
|
||||||
self.room.chat.sound.play('sessioninvite')
|
self.soundId = self.room.chat.sound.play('sessioninvite')
|
||||||
|
|
||||||
var username = self.mappersOnMap[inviter].name
|
var username = self.mappersOnMap[inviter].name
|
||||||
var notifyText = username + ' is inviting you to the conversation. Join?'
|
var notifyText = username + ' is inviting you to the conversation. Join?'
|
||||||
|
@ -352,7 +353,7 @@ const Realtime = {
|
||||||
},
|
},
|
||||||
acceptCall: function (userid) {
|
acceptCall: function (userid) {
|
||||||
var self = Realtime
|
var self = Realtime
|
||||||
self.room.chat.sound.stop('sessioninvite')
|
self.room.chat.sound.stop(self.soundId)
|
||||||
self.socket.emit('callAccepted', {
|
self.socket.emit('callAccepted', {
|
||||||
mapid: Active.Map.id,
|
mapid: Active.Map.id,
|
||||||
invited: Active.Mapper.id,
|
invited: Active.Mapper.id,
|
||||||
|
@ -364,7 +365,7 @@ const Realtime = {
|
||||||
},
|
},
|
||||||
denyCall: function (userid) {
|
denyCall: function (userid) {
|
||||||
var self = Realtime
|
var self = Realtime
|
||||||
self.room.chat.sound.stop('sessioninvite')
|
self.room.chat.sound.stop(self.soundId)
|
||||||
self.socket.emit('callDenied', {
|
self.socket.emit('callDenied', {
|
||||||
mapid: Active.Map.id,
|
mapid: Active.Map.id,
|
||||||
invited: Active.Mapper.id,
|
invited: Active.Mapper.id,
|
||||||
|
@ -374,7 +375,7 @@ const Realtime = {
|
||||||
},
|
},
|
||||||
denyInvite: function (userid) {
|
denyInvite: function (userid) {
|
||||||
var self = Realtime
|
var self = Realtime
|
||||||
self.room.chat.sound.stop('sessioninvite')
|
self.room.chat.sound.stop(self.soundId)
|
||||||
self.socket.emit('inviteDenied', {
|
self.socket.emit('inviteDenied', {
|
||||||
mapid: Active.Map.id,
|
mapid: Active.Map.id,
|
||||||
invited: Active.Mapper.id,
|
invited: Active.Mapper.id,
|
||||||
|
|
Loading…
Add table
Reference in a new issue