From a194e86d7aef13a6286a448b19c16f522d45149f Mon Sep 17 00:00:00 2001 From: Andreas <andreas.hatziiliou@savoirfairelinux.com> Date: Thu, 19 Sep 2024 15:36:24 -0400 Subject: [PATCH] screenshare: fix bug on certain wayland systems Fixed logic error which was causing screen sharing to stop working on certain Wayland environments. GitLab: #1676 Change-Id: Idf3beb97a53d2eb88e082cee710be56c90c6df05 --- src/libclient/api/call.h | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/libclient/api/call.h b/src/libclient/api/call.h index d386e72a7..cc63b08c9 100644 --- a/src/libclient/api/call.h +++ b/src/libclient/api/call.h @@ -168,8 +168,12 @@ struct Info if (media[MediaAttributeKey::MEDIA_TYPE] == Details::MEDIA_TYPE_VIDEO) { if (media[MediaAttributeKey::SOURCE].startsWith(VideoProtocolPrefix::DISPLAY) || media[MediaAttributeKey::SOURCE].startsWith(VideoProtocolPrefix::FILE)) { - callInfo["is_sharing"] = true; - callInfo["preview_id"] = media[MediaAttributeKey::SOURCE]; + if (media[MediaAttributeKey::MUTED] == TRUE_STR) { + callInfo["is_sharing"] = false; + } else { + callInfo["is_sharing"] = true; + callInfo["preview_id"] = media[MediaAttributeKey::SOURCE]; + } } if (media[MediaAttributeKey::ENABLED] == TRUE_STR && media[MediaAttributeKey::MUTED] == FALSE_STR && previewId.isEmpty()) { -- GitLab