Sfoglia il codice sorgente

fix(filmstrip-only): prevent stats display

master
Leonard Kim 7 anni fa
parent
commit
fafffb519b

+ 10
- 4
react/features/base/popover/components/Popover.web.js Vedi File

@@ -66,6 +66,11 @@ class Popover extends Component {
66 66
          */
67 67
         content: PropTypes.object,
68 68
 
69
+        /**
70
+         * Whether displaying of the popover should be prevented.
71
+         */
72
+        disablePopover: PropTypes.bool,
73
+
69 74
         /**
70 75
          * An id attribute to apply to the root of the {@code Popover}
71 76
          * component.
@@ -148,12 +153,13 @@ class Popover extends Component {
148 153
      * @returns {void}
149 154
      */
150 155
     _onShowDialog() {
151
-        this.setState({ showDialog: true });
156
+        if (!this.props.disablePopover) {
157
+            this.setState({ showDialog: true });
152 158
 
153
-        if (this.props.onPopoverOpen) {
154
-            this.props.onPopoverOpen();
159
+            if (this.props.onPopoverOpen) {
160
+                this.props.onPopoverOpen();
161
+            }
155 162
         }
156
-
157 163
     }
158 164
 
159 165
     /**

+ 1
- 0
react/features/connection-indicator/components/ConnectionIndicator.js Vedi File

@@ -222,6 +222,7 @@ class ConnectionIndicator extends Component {
222 222
             <Popover
223 223
                 className = { rootClassNames }
224 224
                 content = { this._renderStatisticsTable() }
225
+                disablePopover = { !this.props.enableStatsDisplay }
225 226
                 position = { this.props.statsPopoverPosition }>
226 227
                 <div className = 'popover-trigger'>
227 228
                     <div

Loading…
Annulla
Salva