Fix SortedList.values iteration and general dec lifecycle fixes

Fixes #4652
This commit is contained in:
Daniel Imms
2023-08-13 10:42:45 -07:00
parent 5890029f71
commit 70f6fa2bc9
6 changed files with 26 additions and 25 deletions
@@ -103,6 +103,10 @@ export class BufferDecorationRenderer extends Disposable {
decoration.element = element;
this._decorationElements.set(decoration, element);
this._container.appendChild(element);
decoration.onDispose(() => {
this._decorationElements.delete(decoration);
element!.remove();
});
}
element.style.top = `${line * this._renderService.dimensions.css.cell.height}px`;
element.style.display = this._altBufferIsActive ? 'none' : 'block';