dispose and clear things out when they are not needed to free up memory (#5805)

This commit is contained in:
Anthony Dresser
2019-05-31 17:24:01 -07:00
committed by Karl Burtram
parent ba58b0f429
commit 23e4a30cd1
4 changed files with 19 additions and 34 deletions

View File

@@ -24,7 +24,6 @@ import { IThemeService } from 'vs/platform/theme/common/themeService';
class MessagesView extends Disposable implements IPanelView {
private messagePanel: MessagePanel;
private container = document.createElement('div');
private _state: MessagePanelState;
constructor(private instantiationService: IInstantiationService) {
super();
@@ -59,19 +58,13 @@ class MessagesView extends Disposable implements IPanelView {
}
public set state(val: MessagePanelState) {
this._state = val;
this.messagePanel.state = val;
}
public get state(): MessagePanelState {
return this._state;
}
}
class ResultsView extends Disposable implements IPanelView {
private gridPanel: GridPanel;
private container = document.createElement('div');
private _state: GridPanelState;
constructor(private instantiationService: IInstantiationService) {
super();
@@ -106,13 +99,8 @@ class ResultsView extends Disposable implements IPanelView {
}
public set state(val: GridPanelState) {
this._state = val;
this.gridPanel.state = val;
}
public get state(): GridPanelState {
return this._state;
}
}
class ResultsTab implements IPanelTab {