()
| 10033 | |
| 10034 | //some browsers (like iOS) occasionally drop the requestAnimationFrame event when the user switches to a different tab and then comes back again, so we use a 2-second setTimeout() to sense if/when that condition occurs and then wake() the ticker. |
| 10035 | var _checkTimeout = function() { |
| 10036 | if (_tickerActive && _getTime() - _lastUpdate > 2000) { |
| 10037 | _ticker.wake(); |
| 10038 | } |
| 10039 | setTimeout(_checkTimeout, 2000); |
| 10040 | }; |
| 10041 | _checkTimeout(); |
| 10042 | |
| 10043 |