fix: Video calls

This commit is contained in:
Christian Pauly
2021-01-16 16:39:07 +01:00
parent a5e95539e3
commit 672eca6302
4 changed files with 25 additions and 29 deletions

View File

@ -320,14 +320,6 @@ class MatrixState extends State<Matrix> {
LoadingDialog.defaultBackLabel = L10n.of(context).close;
LoadingDialog.defaultOnError = (Object e) => e.toLocalizedString(context);
onJitsiCallSub ??= client.onEvent.stream
.where((e) =>
e.type == EventUpdateType.timeline &&
e.eventType == 'm.room.message' &&
e.content['content']['msgtype'] == Matrix.callNamespace &&
e.content['sender'] != client.userID)
.listen(onJitsiCall);
onRoomKeyRequestSub ??=
client.onRoomKeyRequest.stream.listen((RoomKeyRequest request) async {
final room = request.room;
@ -437,7 +429,7 @@ class MatrixState extends State<Matrix> {
void dispose() {
onRoomKeyRequestSub?.cancel();
onKeyVerificationRequestSub?.cancel();
onJitsiCallSub?.cancel();
onLoginStateChanged?.cancel();
onNotification?.cancel();
onFocusSub?.cancel();
onBlurSub?.cancel();