Browse Source

Updates transport type.

Updates transport type to show multiple values as we do for addresses and ports.
master
damencho 8 years ago
parent
commit
e5cefcce70
2 changed files with 18 additions and 4 deletions
  1. 1
    0
      lang/main.json
  2. 17
    4
      modules/UI/videolayout/ConnectionIndicator.js

+ 1
- 0
lang/main.json View File

189
         "remoteaddress": "Remote address:",
189
         "remoteaddress": "Remote address:",
190
         "remoteaddress_plural": "Remote addresses:",
190
         "remoteaddress_plural": "Remote addresses:",
191
         "transport": "Transport:",
191
         "transport": "Transport:",
192
+        "transport_plural": "Transports:",
192
         "bandwidth": "Estimated bandwidth:",
193
         "bandwidth": "Estimated bandwidth:",
193
         "na": "Come back here for connection information once the conference starts"
194
         "na": "Come back here for connection information once the conference starts"
194
     },
195
     },

+ 17
- 4
modules/UI/videolayout/ConnectionIndicator.js View File

150
                 "data-i18n='connectionindicator.address'></span></td>" +
150
                 "data-i18n='connectionindicator.address'></span></td>" +
151
                 "<td> N/A</td></tr>";
151
                 "<td> N/A</td></tr>";
152
         } else {
152
         } else {
153
-            var data = {remoteIP: [], localIP:[], remotePort:[], localPort:[]};
153
+            var data = {
154
+                remoteIP: [],
155
+                localIP:[],
156
+                remotePort:[],
157
+                localPort:[],
158
+                transportType:[]};
154
             for(i = 0; i < this.transport.length; i++) {
159
             for(i = 0; i < this.transport.length; i++) {
155
                 var ip =  ConnectionIndicator.getIP(this.transport[i].ip);
160
                 var ip =  ConnectionIndicator.getIP(this.transport[i].ip);
156
                 var port = ConnectionIndicator.getPort(this.transport[i].ip);
161
                 var port = ConnectionIndicator.getPort(this.transport[i].ip);
173
                 if(data.localPort.indexOf(localPort) == -1) {
178
                 if(data.localPort.indexOf(localPort) == -1) {
174
                     data.localPort.push(localPort);
179
                     data.localPort.push(localPort);
175
                 }
180
                 }
181
+
182
+                if(data.transportType.indexOf(this.transport[i].type) == -1) {
183
+                    data.transportType.push(this.transport[i].type);
184
+                }
176
             }
185
             }
177
 
186
 
178
             var local_address_key = "connectionindicator.localaddress";
187
             var local_address_key = "connectionindicator.localaddress";
215
             transport += "</td></tr>";
224
             transport += "</td></tr>";
216
             transport += localTransport + "</td></tr>";
225
             transport += localTransport + "</td></tr>";
217
             transport +="<tr>" +
226
             transport +="<tr>" +
218
-                "<td><span data-i18n='connectionindicator.transport'>" +
219
-                    "</span></td>" +
220
-                "<td>" + this.transport[0].type + "</td></tr>";
227
+                "<td><span data-i18n='connectionindicator.transport' "
228
+                    + " data-i18n-options='" +
229
+                    JSON.stringify({count: data.transportType.length})
230
+                + "'></span></td>" +
231
+                "<td>"
232
+                    + ConnectionIndicator.getStringFromArray(data.transportType)
233
+                + "</td></tr>";
221
 
234
 
222
         }
235
         }
223
 
236
 

Loading…
Cancel
Save