Selaa lähdekoodia

ref: Remove pinEndpoint. (#1440)

"Pinned" endpoints are deprecated, use "selected" instead.
dev1
bgrozev 4 vuotta sitten
vanhempi
commit
d5be7ad2d7
No account linked to committer's email address
3 muutettua tiedostoa jossa 0 lisäystä ja 54 poistoa
  1. 0
    11
      JitsiConference.js
  2. 0
    16
      modules/RTC/BridgeChannel.js
  3. 0
    27
      modules/RTC/RTC.js

+ 0
- 11
JitsiConference.js Näytä tiedosto

@@ -1338,17 +1338,6 @@ JitsiConference.prototype.selectParticipants = function(participantIds) {
1338 1338
     this.rtc.selectEndpoints(participantIds);
1339 1339
 };
1340 1340
 
1341
-/**
1342
- * Elects the participant with the given id to be the pinned participant in
1343
- * order to always receive video for this participant (even when last n is
1344
- * enabled).
1345
- * @param participantId the identifier of the participant
1346
- * @throws NetworkError or InvalidStateError or Error if the operation fails.
1347
- */
1348
-JitsiConference.prototype.pinParticipant = function(participantId) {
1349
-    this.rtc.pinEndpoint(participantId);
1350
-};
1351
-
1352 1341
 /**
1353 1342
  * Obtains the current value for "lastN". See {@link setLastN} for more info.
1354 1343
  * @returns {number}

+ 0
- 16
modules/RTC/BridgeChannel.js Näytä tiedosto

@@ -207,22 +207,6 @@ export default class BridgeChannel {
207 207
         });
208 208
     }
209 209
 
210
-    /**
211
-     * Sends a "pinned endpoint changed" message via the channel.
212
-     * @param {string} endpointId The id of the pinned endpoint.
213
-     * @throws NetworkError or InvalidStateError from RTCDataChannel#send (@see
214
-     * {@link https://developer.mozilla.org/docs/Web/API/RTCDataChannel/send})
215
-     * or from WebSocket#send or Error with "No opened channel" message.
216
-     */
217
-    sendPinnedEndpointMessage(endpointId) {
218
-        logger.log(`Sending pinned endpoint: ${endpointId}.`);
219
-
220
-        this._send({
221
-            colibriClass: 'PinnedEndpointChangedEvent',
222
-            pinnedEndpoint: endpointId || null
223
-        });
224
-    }
225
-
226 210
     /**
227 211
      * Sends a "selected endpoints changed" message via the channel.
228 212
      *

+ 0
- 27
modules/RTC/RTC.js Näytä tiedosto

@@ -171,14 +171,6 @@ export default class RTC extends Listenable {
171 171
          */
172 172
         this._maxFrameHeight = undefined;
173 173
 
174
-        /**
175
-         * The endpoint ID of currently pinned participant or <tt>null</tt> if
176
-         * no user is pinned.
177
-         * @type {string|null}
178
-         * @private
179
-         */
180
-        this._pinnedEndpoint = null;
181
-
182 174
         /**
183 175
          * The endpoint IDs of currently selected participants.
184 176
          *
@@ -291,8 +283,6 @@ export default class RTC extends Listenable {
291 283
             // we want the notification to trigger even if userJid
292 284
             // is undefined, or null.
293 285
             try {
294
-                this._channel.sendPinnedEndpointMessage(
295
-                    this._pinnedEndpoint);
296 286
                 this._channel.sendSelectedEndpointsMessage(
297 287
                     this._selectedEndpoints);
298 288
 
@@ -304,7 +294,6 @@ export default class RTC extends Listenable {
304 294
                 GlobalOnErrorHandler.callErrorHandler(error);
305 295
                 logger.error(
306 296
                     `Cannot send selected(${this._selectedEndpoint})`
307
-                    + `pinned(${this._pinnedEndpoint})`
308 297
                     + `frameHeight(${this._maxFrameHeight}) endpoint message`,
309 298
                     error);
310 299
             }
@@ -434,22 +423,6 @@ export default class RTC extends Listenable {
434 423
         }
435 424
     }
436 425
 
437
-    /**
438
-     * Elects the participant with the given id to be the pinned participant in
439
-     * order to always receive video for this participant (even when last n is
440
-     * enabled).
441
-     * @param {stirng} id The user id.
442
-     * @throws NetworkError or InvalidStateError or Error if the operation
443
-     * fails.
444
-     */
445
-    pinEndpoint(id) {
446
-        // Cache the value if channel is missing, till we open it.
447
-        this._pinnedEndpoint = id;
448
-        if (this._channel && this._channel.isOpen()) {
449
-            this._channel.sendPinnedEndpointMessage(id);
450
-        }
451
-    }
452
-
453 426
     /**
454 427
      *
455 428
      * @param eventType

Loading…
Peruuta
Tallenna