diff --git a/labs/meteor-client/client/globals.coffee b/labs/meteor-client/client/globals.coffee index ca86b81187..7960cd41a9 100755 --- a/labs/meteor-client/client/globals.coffee +++ b/labs/meteor-client/client/globals.coffee @@ -146,25 +146,27 @@ Meteor.methods setInSession "display_usersList", !getInSession "display_usersList" @toggleVoiceCall = (event) -> - if getInSession "isSharingAudio" - callback = -> - setInSession "isSharingAudio", false # update to no longer sharing - console.log "left voice conference" - # sometimes we can hangup before the message that the user stopped talking is received so lets set it manually, otherwise they might leave the audio call but still be registered as talking - Meteor.call("userStopAudio", getInSession("meetingId"),getInSession("userId")) - webrtc_hangup callback # sign out of call - else - # create voice call params - username = "#{getInSession("userId")}-bbbID-#{getUsersName()}" - voiceBridge = "70827" - server = null - callback = (message) -> - console.log JSON.stringify message - setInSession "isSharingAudio", true - Meteor.call("userShareAudio", getInSession("meetingId"),getInSession("userId")) - console.log "joined audio call" - console.log Meteor.Users.findOne(userId:getInSession("userId")) - webrtc_call(username, voiceBridge, server, callback) # make the call + if getInSession "isSharingAudio" + hangupCallback = -> + console.log "left voice conference" + # sometimes we can hangup before the message that the user stopped talking is received so lets set it manually, otherwise they might leave the audio call but still be registered as talking + Meteor.call("userStopAudio", getInSession("meetingId"),getInSession("userId")) + setInSession "isSharingAudio", false # update to no longer sharing + webrtc_hangup hangupCallback # sign out of call + else + # create voice call params + username = "#{getInSession("userId")}-bbbID-#{getUsersName()}" + # voiceBridge = "70827" + voiceBridge = "70828" + server = null + joinCallback = (message) -> + console.log JSON.stringify message + Meteor.call("userShareAudio", getInSession("meetingId"),getInSession("userId")) + console.log "joined audio call" + console.log Meteor.Users.findOne(userId:getInSession("userId")) + setInSession "isSharingAudio", true + webrtc_call(username, voiceBridge, server, joinCallback) # make the call + return false @toggleWhiteBoard = -> setInSession "display_whiteboard", !getInSession "display_whiteboard" @@ -172,10 +174,6 @@ Meteor.methods @userKick = (meeting, user) -> Meteor.call("userKick", meeting, user) -Handlebars.registerHelper "isUserSharingAudio", (u) -> - if u? then u.voiceUser?.joined - else return false - Handlebars.registerHelper "getCurrentSlide", -> currentPresentation = Meteor.Presentations.findOne({"presentation.current": true}) presentationId = currentPresentation?.presentation?.id diff --git a/labs/meteor-client/client/main.coffee b/labs/meteor-client/client/main.coffee index e8a8538844..d02498ec1c 100755 --- a/labs/meteor-client/client/main.coffee +++ b/labs/meteor-client/client/main.coffee @@ -76,32 +76,3 @@ Meteor.startup -> ] @whiteboardPaperModel = new WhiteboardPaperModel('whiteboard-paper') - -Template.header.events - "click .usersListIcon": (event) -> - toggleUsersList() - "click .chatBarIcon": (event) -> - toggleChatbar() - "click .videoFeedIcon": (event) -> - toggleCam @ - "click .audioFeedIcon": (event) -> - toggleVoiceCall @ - "click .muteIcon": (event) -> - toggleMic @ - "click .signOutIcon": (event) -> - userLogout getInSession("meetingId"), getInSession("userId"), true - "click .hideNavbarIcon": (event) -> - toggleNavbar() - "click .settingsIcon": (event) -> - alert "settings" - "click .raiseHand": (event) -> - Meteor.call('userRaiseHand', @id) - "click .whiteboardIcon": (event) -> - toggleWhiteBoard() - -Template.makeButton.rendered = -> - $('button[rel=tooltip]').tooltip() - -# Gets called last in main template, just an easy place to print stuff out -Handlebars.registerHelper "doFinalStuff", -> - console.log "-----Doing Final Stuff-----" diff --git a/labs/meteor-client/client/main.html b/labs/meteor-client/client/main.html index b80fbc4a37..7db9449873 100755 --- a/labs/meteor-client/client/main.html +++ b/labs/meteor-client/client/main.html @@ -80,25 +80,25 @@ diff --git a/labs/meteor-client/client/stylesheets/chat.less b/labs/meteor-client/client/stylesheets/chat.less index b3c8fe1db0..5ef1df8202 100755 --- a/labs/meteor-client/client/stylesheets/chat.less +++ b/labs/meteor-client/client/stylesheets/chat.less @@ -57,7 +57,10 @@ width: 80%; margin-top:6px; } -.optionsChatTab{} +.optionsBar{ + padding-top:15px; + padding-left: 15px; +} .panel-footer{ padding-top:0px; position:relative; @@ -69,7 +72,6 @@ border: solid 1px grey; padding: 5px; width: 90%; - margin-left:15px; } .private-chat-user-entry {} .private-chat-user-list { diff --git a/labs/meteor-client/client/stylesheets/style.css b/labs/meteor-client/client/stylesheets/style.css index 67297d29ea..dc710efeb3 100755 --- a/labs/meteor-client/client/stylesheets/style.css +++ b/labs/meteor-client/client/stylesheets/style.css @@ -1,8 +1,13 @@ .audioFeedIcon{} body { background: #eee; + bottom:0; color: #666666; - position:absolute; top:0; bottom:0; left:0; right:0; height:100%; + height:100%; + left:0; + position:absolute; + right:0; + top:0; } .chatBarIcon{} @@ -78,17 +83,17 @@ body { padding-left:0.5%; } .raiseHand {} -.recordingStatusTrue{ - color:green; +.recordingStatus{ background:none!important; border:none; padding:0!important; + margin-left: 10px; +} +.recordingStatusTrue{ + color:green; } .recordingStatusFalse{ color:maroon; - background:none!important; - border:none; - padding:0!important; } .ScrollableWindow { height: 100%; diff --git a/labs/meteor-client/client/stylesheets/users.less b/labs/meteor-client/client/stylesheets/users.less index ca2c6f7ba5..b334e11e41 100755 --- a/labs/meteor-client/client/stylesheets/users.less +++ b/labs/meteor-client/client/stylesheets/users.less @@ -5,6 +5,7 @@ } #user-contents { padding-bottom: 10px; + height:95%; } .userNameEntry{ height:20px; diff --git a/labs/meteor-client/client/views/chat/chat_bar.coffee b/labs/meteor-client/client/views/chat/chat_bar.coffee index 68094d0e9e..531630605a 100755 --- a/labs/meteor-client/client/views/chat/chat_bar.coffee +++ b/labs/meteor-client/client/views/chat/chat_bar.coffee @@ -101,6 +101,9 @@ Template.optionsBar.events "from_color": "0" Meteor.call "sendChatMessagetoServer", getInSession("meetingId"), messageForServer +Template.optionsBar.rendered = -> + $('div[rel=tooltip]').tooltip() + Template.tabButtons.events 'click .close': (event) -> # user closes private chat setInSession 'inChatWith', 'PUBLIC_CHAT'