Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Restore notebook layout performance optimization #172466

Merged
merged 1 commit into from Jan 30, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Expand Up @@ -1705,7 +1705,7 @@ export class NotebookEditorWidget extends Disposable implements INotebookEditorD
return this._scrollBeyondLastLine && !this.isEmbedded;
}

layout(dimension: DOM.Dimension, shadowElement?: HTMLElement, _position?: DOM.IDomPosition): void {
layout(dimension: DOM.Dimension, shadowElement?: HTMLElement, position?: DOM.IDomPosition): void {
if (!shadowElement && this._shadowElementViewInfo === null) {
this._dimension = dimension;
return;
Expand All @@ -1717,7 +1717,7 @@ export class NotebookEditorWidget extends Disposable implements INotebookEditorD
}

if (shadowElement) {
this.updateShadowElement(shadowElement, dimension, /*position*/ undefined);
this.updateShadowElement(shadowElement, dimension, position);
}

if (this._shadowElementViewInfo && this._shadowElementViewInfo.width <= 0 && this._shadowElementViewInfo.height <= 0) {
Expand Down Expand Up @@ -1746,7 +1746,7 @@ export class NotebookEditorWidget extends Disposable implements INotebookEditorD
this._overlayContainer.style.position = 'absolute';
this._overlayContainer.style.overflow = 'hidden';

this.layoutContainerOverShadowElement(dimension, /*position*/ undefined);
this.layoutContainerOverShadowElement(dimension, position);

if (this._webviewTransparentCover) {
this._webviewTransparentCover.style.height = `${dimension.height}px`;
Expand Down