fix h-scrollbar cutoff issue (#21396)

This commit is contained in:
Alan Ren
2022-12-12 09:39:33 -08:00
committed by GitHub
parent 5a6db7def1
commit 6cfa0910b6

View File

@@ -342,6 +342,7 @@ export class QueryEditor extends EditorPane {
}
this.taskbar.setContent(content);
this.layout(this.dimension);
}
public override async setInput(newInput: QueryEditorInput, options: IEditorOptions, context: IEditorOpenContext, token: CancellationToken): Promise<void> {
@@ -507,10 +508,12 @@ export class QueryEditor extends EditorPane {
* To be called when the container of this editor changes size.
*/
public layout(dimension: DOM.Dimension): void {
this.dimension = dimension;
const queryEditorHeight = dimension.height - DOM.getTotalHeight(this.taskbar.getContainer());
this.splitviewContainer.style.height = queryEditorHeight + 'px';
this.splitview.layout(queryEditorHeight);
if (dimension?.height && dimension?.width && this.splitview) {
this.dimension = dimension;
const queryEditorHeight = dimension.height - DOM.getTotalHeight(this.taskbar.getContainer());
this.splitviewContainer.style.height = queryEditorHeight + 'px';
this.splitview.layout(queryEditorHeight);
}
}
/**