add listeners to make grid the largest (#2447)

This commit is contained in:
Anthony Dresser
2018-09-06 17:00:54 -07:00
committed by GitHub
parent c01da0f263
commit 197e1c651f

View File

@@ -18,6 +18,7 @@ import * as UUID from 'vs/base/common/uuid';
import { PanelViewlet } from 'vs/workbench/browser/parts/views/panelViewlet';
import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation';
import * as DOM from 'vs/base/browser/dom';
import { once } from 'vs/base/common/event';
class ResultsView implements IPanelView {
private panelViewlet: PanelViewlet;
@@ -38,6 +39,13 @@ class ResultsView implements IPanelView {
{ panel: this.messagePanel, size: this.messagePanel.minimumSize, index: 1 }
]);
});
let gridResizeList = this.gridPanel.onDidChange(e => {
this.panelViewlet.resizePanel(this.gridPanel, this.gridPanel.maximumSize);
});
// once the user changes the sash we should stop trying to resize the grid
once(this.panelViewlet.onDidSashChange)(e => {
gridResizeList.dispose();
});
}
render(container: HTMLElement): void {