2021-04-12 07:37:39 +00:00
|
|
|
// @flow
|
|
|
|
|
2021-04-28 14:06:41 +00:00
|
|
|
import { isWindows } from '../base/environment';
|
2021-04-12 07:37:39 +00:00
|
|
|
import { browser } from '../base/lib-jitsi-meet';
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
* State of audio sharing.
|
|
|
|
*
|
|
|
|
* @param {Object} state - The state of the application.
|
|
|
|
* @returns {boolean}
|
|
|
|
*/
|
|
|
|
export function isScreenAudioShared(state: Object) {
|
|
|
|
return state['features/screen-share'].isSharingAudio;
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
2021-04-28 14:06:41 +00:00
|
|
|
* Returns the visibility of the audio only screen share button. Currently only chrome browser and electron on
|
|
|
|
* windows supports this functionality.
|
2021-04-12 07:37:39 +00:00
|
|
|
*
|
|
|
|
* @returns {boolean}
|
|
|
|
*/
|
|
|
|
export function isScreenAudioSupported() {
|
2021-04-28 14:06:41 +00:00
|
|
|
return browser.isChrome() || (browser.isElectron() && isWindows());
|
2021-04-12 07:37:39 +00:00
|
|
|
}
|