(useAnimation = false)
| 23 | } |
| 24 | |
| 25 | requestUpdate(useAnimation = false) { |
| 26 | if (useAnimation) { |
| 27 | window.cancelAnimationFrame(this._updateTimeoutId); |
| 28 | this._updateTimeoutId = |
| 29 | window.requestAnimationFrame(this._updateCallback); |
| 30 | } else { |
| 31 | // Use timeout tasks to asynchronously update the UI without blocking. |
| 32 | clearTimeout(this._updateTimeoutId); |
| 33 | const kDelayMs = 5; |
| 34 | this._updateTimeoutId = setTimeout(this._updateCallback, kDelayMs); |
| 35 | } |
| 36 | } |
| 37 | |
| 38 | forceUpdate() { |
| 39 | this._updateTimeoutId = undefined; |
nothing calls this directly
no test coverage detected