Fix #203434. Avoid layout from sticky scroll event if the editor is set to invisible. (#203485)

This commit is contained in:
Peng Lyu
2024-01-25 22:05:50 +01:00
committed by GitHub
parent 4f143e0e28
commit ed6c2eca2d
@@ -1079,7 +1079,7 @@ export class NotebookEditorWidget extends Disposable implements INotebookEditorD
return;
}
if (this._dimension) {
if (this._dimension && this._isVisible) {
if (sizeDelta > 0) { // delta > 0 ==> sticky is growing, cell list shrinking
this.layout(this._dimension);
this.setScrollTop(this.scrollTop + sizeDelta);