Subscription permission API (#68)

* signal

* request

* implement

* rename event

* ref

* adjustments based on review

* override subscribed

* move events emit

* fix subscription state

* minor change

* update example for permissions demo

* format & subscriptionState as computed property

* prepare macos build

* unsubscribed event when subscription not allowed
This commit is contained in:
Hiroshi Horie
2022-01-10 23:48:44 +07:00
committed by GitHub
parent 9a37129504
commit aef1fd8804
12 changed files with 259 additions and 24 deletions
+15
View File
@@ -244,3 +244,18 @@ class SpeakingChangedEvent with ParticipantEvent {
required this.speaking,
});
}
/// One of subscribed tracks have changed its permissions for the current
/// participant. If permission was revoked, then the track will no longer
/// be subscribed. If permission was granted, a TrackSubscribed event will
/// be emitted.
class TrackSubscriptionPermissionChangedEvent with RoomEvent, ParticipantEvent {
final Participant participant;
final RemoteTrackPublication trackPublication;
final TrackSubscriptionState state;
const TrackSubscriptionPermissionChangedEvent({
required this.participant,
required this.trackPublication,
required this.state,
});
}