Acknowledge DeviceMute widget actions (#12790)

* acknowledge DeviceMute widget actions (to prevent sending the  default error response to the widget)

* rephrase comment

* test for widget action ack
This commit is contained in:
Timo 2024-07-25 11:29:01 +02:00 committed by GitHub
parent 6e9fc55cb4
commit 72e7df0f13
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 34 additions and 5 deletions

View file

@ -892,6 +892,10 @@ export class ElementCall extends Call {
this.messaging!.on(`action:${ElementWidgetActions.TileLayout}`, this.onTileLayout);
this.messaging!.on(`action:${ElementWidgetActions.SpotlightLayout}`, this.onSpotlightLayout);
this.messaging!.on(`action:${ElementWidgetActions.HangupCall}`, this.onHangup);
this.messaging!.on(`action:${ElementWidgetActions.DeviceMute}`, async (ev) => {
ev.preventDefault();
await this.messaging!.transport.reply(ev.detail, {}); // ack
});
if (!this.widget.data?.skipLobby) {
// If we do not skip the lobby we need to wait until the widget has