Преглед изворни кода

fix(filmstrip-only): prevent stats display

master
Leonard Kim пре 7 година
родитељ
комит
fafffb519b

+ 10
- 4
react/features/base/popover/components/Popover.web.js Прегледај датотеку

66
          */
66
          */
67
         content: PropTypes.object,
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
          * An id attribute to apply to the root of the {@code Popover}
75
          * An id attribute to apply to the root of the {@code Popover}
71
          * component.
76
          * component.
148
      * @returns {void}
153
      * @returns {void}
149
      */
154
      */
150
     _onShowDialog() {
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 Прегледај датотеку

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

Loading…
Откажи
Сачувај