====== onMultiuserChanged() ====== wrtc.onMultiuserChanged() is an event function called when a connection has multiple users at other end and a list of those users has been received. You can use this event to display the list. ===== Occurs ===== List of users at other end of connection received. The IXNX voice bridge sends such a list when you connect to it, and every time the list contents change (people added/removed from list or start/end talking). ===== Arguments ===== wrtc.onMultiuserChanged(obj, list) * obj - call object raising the event * list - JSON structure containing: {type:"multi_user_info", users:[{name:..., name_dn:..., talking:...}]} * name - string containing user's address * name_dn - string containing user's display name * talking - string: * "yes" - user is currently talking * "no" - user is currently silent * audio - audio fallback: * "yes" - user audio is transmitted by voice bridge (voice fallback) * "no" - user audio not transmitted by voice bridge (normal operation) * webclient - is user a wrtc or SIP client: * "yes" - user is a wrtc client capable of multiple media streams * "no" - user is a SIP client not capable of multiple media streams, audio always transmitted through voice bridge ===== Return value ===== Ignored. ===== Example ===== {type:"multi_user_info", users:[{name:"john@company.com", name_dn:"John", talking:"yes"}, {name:"eve@company.com", name_dn:"Eve", talking:"no"}]} wrtc.onMultiuserChanged = function(obj, list) { for (var i = 0; i < list.users.length; i++) { -- display list.users[i].name, list.users[i].name_dn and list.users[i].talking -- } ===== Advanced ===== As [[ixnx:wrtc:js:api:call:adv.multiuser|call.adv.multiuser]] is set //after// wrtc.onMultiuserChanged() you can use obj.adv.multiuser to access the previous, old list of multiusers in your code (if you eg want to find what has changed). ===== See Also ===== [[ixnx:wrtc:js:api:call:adv.multiuser|call.adv.multiuser]]