@100mslive/hms-video-store 0.2.58 → 0.2.59

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -976,6 +976,7 @@ var HMSNotificationTypes;
976
976
  HMSNotificationTypes["ROLE_CHANGE_REQUEST"] = "ROLE_CHANGE_REQUEST";
977
977
  HMSNotificationTypes["ROLE_UPDATED"] = "ROLE_UPDATED";
978
978
  HMSNotificationTypes["CHANGE_TRACK_STATE_REQUEST"] = "CHANGE_TRACK_STATE_REQUEST";
979
+ HMSNotificationTypes["CHANGE_MULTI_TRACK_STATE_REQUEST"] = "CHANGE_MULTI_TRACK_STATE_REQUEST";
979
980
  HMSNotificationTypes["ROOM_ENDED"] = "ROOM_ENDED";
980
981
  HMSNotificationTypes["REMOVED_FROM_ROOM"] = "REMOVED_FROM_ROOM";
981
982
  HMSNotificationTypes["DEVICE_CHANGE_UPDATE"] = "DEVICE_CHANGE_UPDATE";
@@ -3801,6 +3802,44 @@ var HMSSDKActions = /*#__PURE__*/function () {
3801
3802
  return setRemoteTrackEnabled;
3802
3803
  }();
3803
3804
 
3805
+ _proto.setRemoteTracksEnabled = /*#__PURE__*/function () {
3806
+ var _setRemoteTracksEnabled = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee29(params) {
3807
+ var sdkRequest, rolesMap;
3808
+ return runtime_1.wrap(function _callee29$(_context29) {
3809
+ while (1) {
3810
+ switch (_context29.prev = _context29.next) {
3811
+ case 0:
3812
+ sdkRequest = {
3813
+ enabled: params.enabled,
3814
+ type: params.type,
3815
+ source: params.source
3816
+ };
3817
+
3818
+ if (params.roles) {
3819
+ rolesMap = this.store.getState(selectRolesMap);
3820
+ sdkRequest.roles = params.roles.map(function (role) {
3821
+ return rolesMap[role];
3822
+ });
3823
+ }
3824
+
3825
+ _context29.next = 4;
3826
+ return this.sdk.changeMultiTrackState(sdkRequest);
3827
+
3828
+ case 4:
3829
+ case "end":
3830
+ return _context29.stop();
3831
+ }
3832
+ }
3833
+ }, _callee29, this);
3834
+ }));
3835
+
3836
+ function setRemoteTracksEnabled(_x42) {
3837
+ return _setRemoteTracksEnabled.apply(this, arguments);
3838
+ }
3839
+
3840
+ return setRemoteTracksEnabled;
3841
+ }();
3842
+
3804
3843
  _proto.setLogLevel = function setLogLevel(level) {
3805
3844
  HMSLogger.level = level;
3806
3845
  this.sdk.setLogLevel(level);
@@ -3832,6 +3871,7 @@ var HMSSDKActions = /*#__PURE__*/function () {
3832
3871
  onRoleUpdate: this.onRoleUpdate.bind(this),
3833
3872
  onDeviceChange: this.onDeviceChange.bind(this),
3834
3873
  onChangeTrackStateRequest: this.onChangeTrackStateRequest.bind(this),
3874
+ onChangeMultiTrackStateRequest: this.onChangeMultiTrackStateRequest.bind(this),
3835
3875
  onRemovedFromRoom: this.onRemovedFromRoom.bind(this)
3836
3876
  });
3837
3877
  this.sdk.addAudioListener({
@@ -3891,12 +3931,12 @@ var HMSSDKActions = /*#__PURE__*/function () {
3891
3931
  };
3892
3932
 
3893
3933
  _proto.sdkPreviewWithListeners = /*#__PURE__*/function () {
3894
- var _sdkPreviewWithListeners = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee29(config) {
3895
- return runtime_1.wrap(function _callee29$(_context29) {
3934
+ var _sdkPreviewWithListeners = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee30(config) {
3935
+ return runtime_1.wrap(function _callee30$(_context30) {
3896
3936
  while (1) {
3897
- switch (_context29.prev = _context29.next) {
3937
+ switch (_context30.prev = _context30.next) {
3898
3938
  case 0:
3899
- _context29.next = 2;
3939
+ _context30.next = 2;
3900
3940
  return this.sdk.preview(config, {
3901
3941
  onPreview: this.onPreview.bind(this),
3902
3942
  onError: this.onError.bind(this),
@@ -3910,13 +3950,13 @@ var HMSSDKActions = /*#__PURE__*/function () {
3910
3950
 
3911
3951
  case 3:
3912
3952
  case "end":
3913
- return _context29.stop();
3953
+ return _context30.stop();
3914
3954
  }
3915
3955
  }
3916
- }, _callee29, this);
3956
+ }, _callee30, this);
3917
3957
  }));
3918
3958
 
3919
- function sdkPreviewWithListeners(_x42) {
3959
+ function sdkPreviewWithListeners(_x43) {
3920
3960
  return _sdkPreviewWithListeners.apply(this, arguments);
3921
3961
  }
3922
3962
 
@@ -3924,29 +3964,29 @@ var HMSSDKActions = /*#__PURE__*/function () {
3924
3964
  }();
3925
3965
 
3926
3966
  _proto.startScreenShare = /*#__PURE__*/function () {
3927
- var _startScreenShare = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee30(audioOnly) {
3967
+ var _startScreenShare = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee31(audioOnly) {
3928
3968
  var _this8 = this;
3929
3969
 
3930
3970
  var isScreenShared;
3931
- return runtime_1.wrap(function _callee30$(_context30) {
3971
+ return runtime_1.wrap(function _callee31$(_context31) {
3932
3972
  while (1) {
3933
- switch (_context30.prev = _context30.next) {
3973
+ switch (_context31.prev = _context31.next) {
3934
3974
  case 0:
3935
3975
  isScreenShared = this.store.getState(selectIsLocalScreenShared);
3936
3976
 
3937
3977
  if (isScreenShared) {
3938
- _context30.next = 7;
3978
+ _context31.next = 7;
3939
3979
  break;
3940
3980
  }
3941
3981
 
3942
- _context30.next = 4;
3982
+ _context31.next = 4;
3943
3983
  return this.sdk.startScreenShare(function () {
3944
3984
  return _this8.syncRoomState('screenshareStopped');
3945
3985
  }, audioOnly);
3946
3986
 
3947
3987
  case 4:
3948
3988
  this.syncRoomState('startScreenShare');
3949
- _context30.next = 8;
3989
+ _context31.next = 8;
3950
3990
  break;
3951
3991
 
3952
3992
  case 7:
@@ -3954,13 +3994,13 @@ var HMSSDKActions = /*#__PURE__*/function () {
3954
3994
 
3955
3995
  case 8:
3956
3996
  case "end":
3957
- return _context30.stop();
3997
+ return _context31.stop();
3958
3998
  }
3959
3999
  }
3960
- }, _callee30, this);
4000
+ }, _callee31, this);
3961
4001
  }));
3962
4002
 
3963
- function startScreenShare(_x43) {
4003
+ function startScreenShare(_x44) {
3964
4004
  return _startScreenShare.apply(this, arguments);
3965
4005
  }
3966
4006
 
@@ -3968,25 +4008,25 @@ var HMSSDKActions = /*#__PURE__*/function () {
3968
4008
  }();
3969
4009
 
3970
4010
  _proto.stopScreenShare = /*#__PURE__*/function () {
3971
- var _stopScreenShare = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee31() {
4011
+ var _stopScreenShare = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee32() {
3972
4012
  var isScreenShared;
3973
- return runtime_1.wrap(function _callee31$(_context31) {
4013
+ return runtime_1.wrap(function _callee32$(_context32) {
3974
4014
  while (1) {
3975
- switch (_context31.prev = _context31.next) {
4015
+ switch (_context32.prev = _context32.next) {
3976
4016
  case 0:
3977
4017
  isScreenShared = this.store.getState(selectIsLocalScreenShared);
3978
4018
 
3979
4019
  if (!isScreenShared) {
3980
- _context31.next = 7;
4020
+ _context32.next = 7;
3981
4021
  break;
3982
4022
  }
3983
4023
 
3984
- _context31.next = 4;
4024
+ _context32.next = 4;
3985
4025
  return this.sdk.stopScreenShare();
3986
4026
 
3987
4027
  case 4:
3988
4028
  this.syncRoomState('stopScreenShare');
3989
- _context31.next = 8;
4029
+ _context32.next = 8;
3990
4030
  break;
3991
4031
 
3992
4032
  case 7:
@@ -3994,10 +4034,10 @@ var HMSSDKActions = /*#__PURE__*/function () {
3994
4034
 
3995
4035
  case 8:
3996
4036
  case "end":
3997
- return _context31.stop();
4037
+ return _context32.stop();
3998
4038
  }
3999
4039
  }
4000
- }, _callee31, this);
4040
+ }, _callee32, this);
4001
4041
  }));
4002
4042
 
4003
4043
  function stopScreenShare() {
@@ -4008,25 +4048,25 @@ var HMSSDKActions = /*#__PURE__*/function () {
4008
4048
  }();
4009
4049
 
4010
4050
  _proto.attachVideoInternal = /*#__PURE__*/function () {
4011
- var _attachVideoInternal = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee32(trackID, videoElement) {
4051
+ var _attachVideoInternal = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee33(trackID, videoElement) {
4012
4052
  var sdkTrack;
4013
- return runtime_1.wrap(function _callee32$(_context32) {
4053
+ return runtime_1.wrap(function _callee33$(_context33) {
4014
4054
  while (1) {
4015
- switch (_context32.prev = _context32.next) {
4055
+ switch (_context33.prev = _context33.next) {
4016
4056
  case 0:
4017
4057
  sdkTrack = this.hmsSDKTracks[trackID];
4018
4058
 
4019
4059
  if (!(sdkTrack && sdkTrack.type === 'video')) {
4020
- _context32.next = 7;
4060
+ _context33.next = 7;
4021
4061
  break;
4022
4062
  }
4023
4063
 
4024
- _context32.next = 4;
4064
+ _context33.next = 4;
4025
4065
  return sdkTrack.addSink(videoElement);
4026
4066
 
4027
4067
  case 4:
4028
4068
  this.updateVideoLayer(trackID, 'attachVideo');
4029
- _context32.next = 8;
4069
+ _context33.next = 8;
4030
4070
  break;
4031
4071
 
4032
4072
  case 7:
@@ -4034,13 +4074,13 @@ var HMSSDKActions = /*#__PURE__*/function () {
4034
4074
 
4035
4075
  case 8:
4036
4076
  case "end":
4037
- return _context32.stop();
4077
+ return _context33.stop();
4038
4078
  }
4039
4079
  }
4040
- }, _callee32, this);
4080
+ }, _callee33, this);
4041
4081
  }));
4042
4082
 
4043
- function attachVideoInternal(_x44, _x45) {
4083
+ function attachVideoInternal(_x45, _x46) {
4044
4084
  return _attachVideoInternal.apply(this, arguments);
4045
4085
  }
4046
4086
 
@@ -4261,6 +4301,38 @@ var HMSSDKActions = /*#__PURE__*/function () {
4261
4301
  });
4262
4302
  };
4263
4303
 
4304
+ _proto.onChangeMultiTrackStateRequest = function onChangeMultiTrackStateRequest(request) {
4305
+ var requestedBy = this.store.getState(selectPeerByID(request.requestedBy.peerId));
4306
+
4307
+ if (!requestedBy) {
4308
+ return this.logPossibleInconsistency("Not found peer who requested track state change, " + request.requestedBy);
4309
+ }
4310
+
4311
+ if (!request.enabled) {
4312
+ this.syncRoomState('changeMultiTrackStateRequest');
4313
+ }
4314
+
4315
+ var tracks = [];
4316
+ var tracksMap = this.store.getState(selectTracksMap);
4317
+
4318
+ for (var _iterator4 = _createForOfIteratorHelperLoose(request.tracks), _step4; !(_step4 = _iterator4()).done;) {
4319
+ var track = _step4.value;
4320
+ var storeTrackID = this.getStoreLocalTrackIDfromSDKTrack(track);
4321
+
4322
+ if (storeTrackID && tracksMap[storeTrackID]) {
4323
+ tracks.push(tracksMap[storeTrackID]);
4324
+ }
4325
+ }
4326
+
4327
+ this.hmsNotifications.sendChangeMultiTrackStateRequest({
4328
+ requestedBy: requestedBy,
4329
+ tracks: tracks,
4330
+ enabled: request.enabled,
4331
+ type: request.type,
4332
+ source: request.source
4333
+ });
4334
+ };
4335
+
4264
4336
  _proto.onReconnected = function onReconnected() {
4265
4337
  this.syncRoomState('reconnectedSync');
4266
4338
  this.hmsNotifications.sendReconnected();
@@ -4346,24 +4418,24 @@ var HMSSDKActions = /*#__PURE__*/function () {
4346
4418
  };
4347
4419
 
4348
4420
  _proto.setEnabledSDKTrack = /*#__PURE__*/function () {
4349
- var _setEnabledSDKTrack = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee33(trackID, enabled) {
4421
+ var _setEnabledSDKTrack = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee34(trackID, enabled) {
4350
4422
  var track;
4351
- return runtime_1.wrap(function _callee33$(_context33) {
4423
+ return runtime_1.wrap(function _callee34$(_context34) {
4352
4424
  while (1) {
4353
- switch (_context33.prev = _context33.next) {
4425
+ switch (_context34.prev = _context34.next) {
4354
4426
  case 0:
4355
4427
  track = this.hmsSDKTracks[trackID];
4356
4428
 
4357
4429
  if (!track) {
4358
- _context33.next = 6;
4430
+ _context34.next = 6;
4359
4431
  break;
4360
4432
  }
4361
4433
 
4362
- _context33.next = 4;
4434
+ _context34.next = 4;
4363
4435
  return track.setEnabled(enabled);
4364
4436
 
4365
4437
  case 4:
4366
- _context33.next = 7;
4438
+ _context34.next = 7;
4367
4439
  break;
4368
4440
 
4369
4441
  case 6:
@@ -4371,13 +4443,13 @@ var HMSSDKActions = /*#__PURE__*/function () {
4371
4443
 
4372
4444
  case 7:
4373
4445
  case "end":
4374
- return _context33.stop();
4446
+ return _context34.stop();
4375
4447
  }
4376
4448
  }
4377
- }, _callee33, this);
4449
+ }, _callee34, this);
4378
4450
  }));
4379
4451
 
4380
- function setEnabledSDKTrack(_x46, _x47) {
4452
+ function setEnabledSDKTrack(_x47, _x48) {
4381
4453
  return _setEnabledSDKTrack.apply(this, arguments);
4382
4454
  }
4383
4455
 
@@ -4385,24 +4457,24 @@ var HMSSDKActions = /*#__PURE__*/function () {
4385
4457
  }();
4386
4458
 
4387
4459
  _proto.setSDKLocalVideoTrackSettings = /*#__PURE__*/function () {
4388
- var _setSDKLocalVideoTrackSettings = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee34(trackID, settings) {
4460
+ var _setSDKLocalVideoTrackSettings = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee35(trackID, settings) {
4389
4461
  var track;
4390
- return runtime_1.wrap(function _callee34$(_context34) {
4462
+ return runtime_1.wrap(function _callee35$(_context35) {
4391
4463
  while (1) {
4392
- switch (_context34.prev = _context34.next) {
4464
+ switch (_context35.prev = _context35.next) {
4393
4465
  case 0:
4394
4466
  track = this.hmsSDKTracks[trackID];
4395
4467
 
4396
4468
  if (!track) {
4397
- _context34.next = 6;
4469
+ _context35.next = 6;
4398
4470
  break;
4399
4471
  }
4400
4472
 
4401
- _context34.next = 4;
4473
+ _context35.next = 4;
4402
4474
  return track.setSettings(settings);
4403
4475
 
4404
4476
  case 4:
4405
- _context34.next = 7;
4477
+ _context35.next = 7;
4406
4478
  break;
4407
4479
 
4408
4480
  case 6:
@@ -4410,13 +4482,13 @@ var HMSSDKActions = /*#__PURE__*/function () {
4410
4482
 
4411
4483
  case 7:
4412
4484
  case "end":
4413
- return _context34.stop();
4485
+ return _context35.stop();
4414
4486
  }
4415
4487
  }
4416
- }, _callee34, this);
4488
+ }, _callee35, this);
4417
4489
  }));
4418
4490
 
4419
- function setSDKLocalVideoTrackSettings(_x48, _x49) {
4491
+ function setSDKLocalVideoTrackSettings(_x49, _x50) {
4420
4492
  return _setSDKLocalVideoTrackSettings.apply(this, arguments);
4421
4493
  }
4422
4494
 
@@ -4424,24 +4496,24 @@ var HMSSDKActions = /*#__PURE__*/function () {
4424
4496
  }();
4425
4497
 
4426
4498
  _proto.setSDKLocalAudioTrackSettings = /*#__PURE__*/function () {
4427
- var _setSDKLocalAudioTrackSettings = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee35(trackID, settings) {
4499
+ var _setSDKLocalAudioTrackSettings = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee36(trackID, settings) {
4428
4500
  var track;
4429
- return runtime_1.wrap(function _callee35$(_context35) {
4501
+ return runtime_1.wrap(function _callee36$(_context36) {
4430
4502
  while (1) {
4431
- switch (_context35.prev = _context35.next) {
4503
+ switch (_context36.prev = _context36.next) {
4432
4504
  case 0:
4433
4505
  track = this.hmsSDKTracks[trackID];
4434
4506
 
4435
4507
  if (!track) {
4436
- _context35.next = 6;
4508
+ _context36.next = 6;
4437
4509
  break;
4438
4510
  }
4439
4511
 
4440
- _context35.next = 4;
4512
+ _context36.next = 4;
4441
4513
  return track.setSettings(settings);
4442
4514
 
4443
4515
  case 4:
4444
- _context35.next = 7;
4516
+ _context36.next = 7;
4445
4517
  break;
4446
4518
 
4447
4519
  case 6:
@@ -4449,13 +4521,13 @@ var HMSSDKActions = /*#__PURE__*/function () {
4449
4521
 
4450
4522
  case 7:
4451
4523
  case "end":
4452
- return _context35.stop();
4524
+ return _context36.stop();
4453
4525
  }
4454
4526
  }
4455
- }, _callee35, this);
4527
+ }, _callee36, this);
4456
4528
  }));
4457
4529
 
4458
- function setSDKLocalAudioTrackSettings(_x50, _x51) {
4530
+ function setSDKLocalAudioTrackSettings(_x51, _x52) {
4459
4531
  return _setSDKLocalAudioTrackSettings.apply(this, arguments);
4460
4532
  }
4461
4533
 
@@ -4518,59 +4590,59 @@ var HMSSDKActions = /*#__PURE__*/function () {
4518
4590
  };
4519
4591
 
4520
4592
  _proto.addRemoveVideoPlugin = /*#__PURE__*/function () {
4521
- var _addRemoveVideoPlugin = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee36(plugin, action, pluginFrameRate) {
4593
+ var _addRemoveVideoPlugin = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee37(plugin, action, pluginFrameRate) {
4522
4594
  var trackID, sdkTrack;
4523
- return runtime_1.wrap(function _callee36$(_context36) {
4595
+ return runtime_1.wrap(function _callee37$(_context37) {
4524
4596
  while (1) {
4525
- switch (_context36.prev = _context36.next) {
4597
+ switch (_context37.prev = _context37.next) {
4526
4598
  case 0:
4527
4599
  if (plugin) {
4528
- _context36.next = 3;
4600
+ _context37.next = 3;
4529
4601
  break;
4530
4602
  }
4531
4603
 
4532
4604
  HMSLogger.w('Invalid plugin received in store');
4533
- return _context36.abrupt("return");
4605
+ return _context37.abrupt("return");
4534
4606
 
4535
4607
  case 3:
4536
4608
  trackID = this.store.getState(selectLocalVideoTrackID);
4537
4609
 
4538
4610
  if (!trackID) {
4539
- _context36.next = 19;
4611
+ _context37.next = 19;
4540
4612
  break;
4541
4613
  }
4542
4614
 
4543
4615
  sdkTrack = this.hmsSDKTracks[trackID];
4544
4616
 
4545
4617
  if (!sdkTrack) {
4546
- _context36.next = 18;
4618
+ _context37.next = 18;
4547
4619
  break;
4548
4620
  }
4549
4621
 
4550
4622
  if (!(action === 'add')) {
4551
- _context36.next = 12;
4623
+ _context37.next = 12;
4552
4624
  break;
4553
4625
  }
4554
4626
 
4555
- _context36.next = 10;
4627
+ _context37.next = 10;
4556
4628
  return sdkTrack.addPlugin(plugin, pluginFrameRate);
4557
4629
 
4558
4630
  case 10:
4559
- _context36.next = 15;
4631
+ _context37.next = 15;
4560
4632
  break;
4561
4633
 
4562
4634
  case 12:
4563
4635
  if (!(action === 'remove')) {
4564
- _context36.next = 15;
4636
+ _context37.next = 15;
4565
4637
  break;
4566
4638
  }
4567
4639
 
4568
- _context36.next = 15;
4640
+ _context37.next = 15;
4569
4641
  return sdkTrack.removePlugin(plugin);
4570
4642
 
4571
4643
  case 15:
4572
4644
  this.syncRoomState(action + "VideoPlugin");
4573
- _context36.next = 19;
4645
+ _context37.next = 19;
4574
4646
  break;
4575
4647
 
4576
4648
  case 18:
@@ -4578,13 +4650,13 @@ var HMSSDKActions = /*#__PURE__*/function () {
4578
4650
 
4579
4651
  case 19:
4580
4652
  case "end":
4581
- return _context36.stop();
4653
+ return _context37.stop();
4582
4654
  }
4583
4655
  }
4584
- }, _callee36, this);
4656
+ }, _callee37, this);
4585
4657
  }));
4586
4658
 
4587
- function addRemoveVideoPlugin(_x52, _x53, _x54) {
4659
+ function addRemoveVideoPlugin(_x53, _x54, _x55) {
4588
4660
  return _addRemoveVideoPlugin.apply(this, arguments);
4589
4661
  }
4590
4662
 
@@ -4592,59 +4664,59 @@ var HMSSDKActions = /*#__PURE__*/function () {
4592
4664
  }();
4593
4665
 
4594
4666
  _proto.addRemoveAudioPlugin = /*#__PURE__*/function () {
4595
- var _addRemoveAudioPlugin = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee37(plugin, action) {
4667
+ var _addRemoveAudioPlugin = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee38(plugin, action) {
4596
4668
  var trackID, sdkTrack;
4597
- return runtime_1.wrap(function _callee37$(_context37) {
4669
+ return runtime_1.wrap(function _callee38$(_context38) {
4598
4670
  while (1) {
4599
- switch (_context37.prev = _context37.next) {
4671
+ switch (_context38.prev = _context38.next) {
4600
4672
  case 0:
4601
4673
  if (plugin) {
4602
- _context37.next = 3;
4674
+ _context38.next = 3;
4603
4675
  break;
4604
4676
  }
4605
4677
 
4606
4678
  HMSLogger.w('Invalid plugin received in store');
4607
- return _context37.abrupt("return");
4679
+ return _context38.abrupt("return");
4608
4680
 
4609
4681
  case 3:
4610
4682
  trackID = this.store.getState(selectLocalAudioTrackID);
4611
4683
 
4612
4684
  if (!trackID) {
4613
- _context37.next = 19;
4685
+ _context38.next = 19;
4614
4686
  break;
4615
4687
  }
4616
4688
 
4617
4689
  sdkTrack = this.hmsSDKTracks[trackID];
4618
4690
 
4619
4691
  if (!sdkTrack) {
4620
- _context37.next = 18;
4692
+ _context38.next = 18;
4621
4693
  break;
4622
4694
  }
4623
4695
 
4624
4696
  if (!(action === 'add')) {
4625
- _context37.next = 12;
4697
+ _context38.next = 12;
4626
4698
  break;
4627
4699
  }
4628
4700
 
4629
- _context37.next = 10;
4701
+ _context38.next = 10;
4630
4702
  return sdkTrack.addPlugin(plugin);
4631
4703
 
4632
4704
  case 10:
4633
- _context37.next = 15;
4705
+ _context38.next = 15;
4634
4706
  break;
4635
4707
 
4636
4708
  case 12:
4637
4709
  if (!(action === 'remove')) {
4638
- _context37.next = 15;
4710
+ _context38.next = 15;
4639
4711
  break;
4640
4712
  }
4641
4713
 
4642
- _context37.next = 15;
4714
+ _context38.next = 15;
4643
4715
  return sdkTrack.removePlugin(plugin);
4644
4716
 
4645
4717
  case 15:
4646
4718
  this.syncRoomState(action + "AudioPlugin");
4647
- _context37.next = 19;
4719
+ _context38.next = 19;
4648
4720
  break;
4649
4721
 
4650
4722
  case 18:
@@ -4652,13 +4724,13 @@ var HMSSDKActions = /*#__PURE__*/function () {
4652
4724
 
4653
4725
  case 19:
4654
4726
  case "end":
4655
- return _context37.stop();
4727
+ return _context38.stop();
4656
4728
  }
4657
4729
  }
4658
- }, _callee37, this);
4730
+ }, _callee38, this);
4659
4731
  }));
4660
4732
 
4661
- function addRemoveAudioPlugin(_x55, _x56) {
4733
+ function addRemoveAudioPlugin(_x56, _x57) {
4662
4734
  return _addRemoveAudioPlugin.apply(this, arguments);
4663
4735
  }
4664
4736
 
@@ -4847,6 +4919,11 @@ var HMSNotifications = /*#__PURE__*/function () {
4847
4919
  this.emitEvent(notification);
4848
4920
  };
4849
4921
 
4922
+ _proto.sendChangeMultiTrackStateRequest = function sendChangeMultiTrackStateRequest(request) {
4923
+ var notification = this.createNotification(HMSNotificationTypes.CHANGE_MULTI_TRACK_STATE_REQUEST, request, HMSNotificationSeverity.INFO);
4924
+ this.emitEvent(notification);
4925
+ };
4926
+
4850
4927
  _proto.emitEvent = function emitEvent(notification) {
4851
4928
  this.eventEmitter.emit(HMS_NOTIFICATION_EVENT, notification);
4852
4929
  };