|
@@ -4,6 +4,7 @@ import React from 'react';
|
4
|
4
|
import { findNodeHandle, NativeModules, Platform } from 'react-native';
|
5
|
5
|
import { ScreenCapturePickerView } from 'react-native-webrtc';
|
6
|
6
|
|
|
7
|
+import { getFeatureFlag, IOS_SCREENSHARING_ENABLED } from '../../../base/flags';
|
7
|
8
|
import { translate } from '../../../base/i18n';
|
8
|
9
|
import { IconShareDesktop } from '../../../base/icons';
|
9
|
10
|
import { connect } from '../../../base/redux';
|
|
@@ -121,11 +122,13 @@ class ScreenSharingIosButton extends AbstractButton<Props, *> {
|
121
|
122
|
* }}
|
122
|
123
|
*/
|
123
|
124
|
function _mapStateToProps(state): Object {
|
|
125
|
+ const enabled = getFeatureFlag(state, IOS_SCREENSHARING_ENABLED, false);
|
|
126
|
+
|
124
|
127
|
return {
|
125
|
128
|
_screensharing: isLocalVideoTrackDesktop(state),
|
126
|
129
|
|
127
|
130
|
// TODO: this should work on iOS 12 too, but our trick to show the picker doesn't work.
|
128
|
|
- visible: Platform.OS === 'ios' && Platform.Version.split('.')[0] >= 14
|
|
131
|
+ visible: enabled && Platform.OS === 'ios' && Platform.Version.split('.')[0] >= 14
|
129
|
132
|
};
|
130
|
133
|
}
|
131
|
134
|
|