Use disposal registration

This commit is contained in:
Svante Boberg
2022-07-27 14:24:42 +02:00
parent c895f67fd8
commit 078b83fcaf
4 changed files with 13 additions and 25 deletions
@@ -55,10 +55,8 @@ export class CursorRenderLayer extends BaseRenderLayer {
}
public override dispose(): void {
if (this._cursorBlinkStateManager) {
this._cursorBlinkStateManager.dispose();
this._cursorBlinkStateManager = undefined;
}
this._cursorBlinkStateManager?.dispose();
this._cursorBlinkStateManager = undefined;
super.dispose();
}