From 732927b0e225e598bcfaa8ea67b685c2776b1c43 Mon Sep 17 00:00:00 2001 From: Samuel Sampson Date: Thu, 29 Jul 2021 20:20:02 +0000 Subject: [PATCH] Add back IDisposable implementation in TimeBasedDebouncer for the ease of interoperability with RenderDebouncer --- src/browser/TimeBasedDebouncer.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/browser/TimeBasedDebouncer.ts b/src/browser/TimeBasedDebouncer.ts index 64226085..843787d5 100644 --- a/src/browser/TimeBasedDebouncer.ts +++ b/src/browser/TimeBasedDebouncer.ts @@ -5,10 +5,12 @@ const RENDER_DEBOUNCE_THRESHOLD_MS = 1000; // 1 Second +import { IDisposable } from 'common/Types'; + /** * Debounces calls to update screen readers to update at most once per second. */ -export class TimeBasedDebouncer { +export class TimeBasedDebouncer implements IDisposable { private _rowStart: number | undefined; private _rowEnd: number | undefined; private _rowCount: number | undefined; @@ -23,6 +25,8 @@ export class TimeBasedDebouncer { ) { } + public dispose(): void {} + public refresh(rowStart: number | undefined, rowEnd: number | undefined, rowCount: number): void { this._rowCount = rowCount; // Get the min/max row start/end for the arg values