From 51cf426179d43edbc02d11fc4bedd7fd34984323 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=A0imon=20Brandner?= Date: Wed, 21 Jul 2021 16:08:18 +0200 Subject: [PATCH] Update the toast MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Šimon Brandner --- src/components/views/voip/CallView.tsx | 10 +++++----- src/i18n/strings/en_EN.json | 1 + 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/src/components/views/voip/CallView.tsx b/src/components/views/voip/CallView.tsx index 3667173325..a9389d224a 100644 --- a/src/components/views/voip/CallView.tsx +++ b/src/components/views/voip/CallView.tsx @@ -739,18 +739,18 @@ export default class CallView extends React.Component { }); let presenting; - if ( - this.state.primaryFeed?.purpose === SDPStreamMetadataPurpose.Screenshare || - this.props.call.isScreensharing() - ) { + if (this.props.call.getFeeds().some((feed) => feed.purpose === SDPStreamMetadataPurpose.Screenshare)) { const presentingClasses = classNames({ mx_CallView_presenting: true, mx_CallView_presenting_hidden: !this.state.controlsVisible, }); const sharerName = this.state.primaryFeed.getMember().name; - const text = this.props.call.isScreensharing() + let text = this.props.call.isScreensharing() ? _t("You are presenting") : _t('%(sharerName)s is presenting', { sharerName }); + if (!this.state.sidebarShown) { + text += " • " + _t("Your camera is still enabled"); + } presenting = (
diff --git a/src/i18n/strings/en_EN.json b/src/i18n/strings/en_EN.json index f8644450ab..b781cc9978 100644 --- a/src/i18n/strings/en_EN.json +++ b/src/i18n/strings/en_EN.json @@ -897,6 +897,7 @@ "Connecting": "Connecting", "You are presenting": "You are presenting", "%(sharerName)s is presenting": "%(sharerName)s is presenting", + "Your camera is still enabled": "Your camera is still enabled", "Video Call": "Video Call", "Voice Call": "Voice Call", "Fill Screen": "Fill Screen",