* TODO(alanorozco): Deprecate native event mechanism. * @private
()
| 143 | * @private |
| 144 | */ |
| 145 | dispatchVisibilityChangeEvent_() { |
| 146 | const event = this.win_.document.createEvent('Event'); |
| 147 | event.data = {hidden: this.hidden}; |
| 148 | event.initEvent(AmpEvents_Enum.VISIBILITY_CHANGE, true, true); |
| 149 | this.win_.dispatchEvent(event); |
| 150 | } |
| 151 | |
| 152 | /** |
| 153 | * Listen to page visibility changes. |
no outgoing calls
no test coverage detected