Changes toast notification for when screenshare has stopped due to data saving
This commit is contained in:
parent
9ffb7df2cd
commit
b43075f815
@ -26,6 +26,7 @@ import {
|
||||
} from '/imports/ui/services/bbb-webrtc-sfu/stream-state-service';
|
||||
import { ACTIONS } from '/imports/ui/components/layout/enums';
|
||||
import deviceInfo from '/imports/utils/deviceInfo';
|
||||
import Settings from '/imports/ui/services/settings';
|
||||
|
||||
const intlMessages = defineMessages({
|
||||
screenShareLabel: {
|
||||
@ -55,6 +56,10 @@ const intlMessages = defineMessages({
|
||||
id: 'app.media.screenshare.end',
|
||||
description: 'toast to show when a screenshare has ended',
|
||||
},
|
||||
screenshareEndedDueToDataSaving: {
|
||||
id: 'app.media.screenshare.endDueToDataSaving',
|
||||
description: 'toast to show when a screenshare has ended by changing data savings option',
|
||||
},
|
||||
});
|
||||
|
||||
const ALLOW_FULLSCREEN = Meteor.settings.public.app.allowFullscreen;
|
||||
@ -148,7 +153,11 @@ class ScreenshareComponent extends React.Component {
|
||||
window.removeEventListener('screensharePlayFailed', this.handlePlayElementFailed);
|
||||
unsubscribeFromStreamStateChange('screenshare', this.onStreamStateChange);
|
||||
|
||||
notify(intl.formatMessage(intlMessages.screenshareEnded), 'info', 'desktop');
|
||||
if (!Settings.dataSaving.viewScreenshare) {
|
||||
notify(intl.formatMessage(intlMessages.screenshareEndedDueToDataSaving), 'info', 'desktop');
|
||||
} else {
|
||||
notify(intl.formatMessage(intlMessages.screenshareEnded), 'info', 'desktop');
|
||||
}
|
||||
|
||||
if (fullscreenContext) {
|
||||
layoutContextDispatch({
|
||||
|
@ -135,6 +135,7 @@
|
||||
"app.media.autoplayAlertDesc": "Allow Access",
|
||||
"app.media.screenshare.start": "Screenshare has started",
|
||||
"app.media.screenshare.end": "Screenshare has ended",
|
||||
"app.media.screenshare.endDueToDataSaving": "Screenshare stopped due to data savings",
|
||||
"app.media.screenshare.unavailable": "Screenshare Unavailable",
|
||||
"app.media.screenshare.notSupported": "Screensharing is not supported in this browser.",
|
||||
"app.media.screenshare.autoplayBlockedDesc": "We need your permission to show you the presenter's screen.",
|
||||
|
Loading…
Reference in New Issue
Block a user