提交 c4023045 编写于 作者: R rebornix

dispose view model properly

上级 e9333810
......@@ -273,6 +273,7 @@ export class NotebookEditor extends BaseEditor implements INotebookEditor, Noteb
if (this.notebookViewModel && !this.notebookViewModel.isDirty()) {
this.notebookService.destoryNotebookDocument(this.viewType!, this.notebookViewModel!.notebookDocument);
this.notebookViewModel.dispose();
this.notebookViewModel = undefined;
}
......
......@@ -225,6 +225,7 @@ export class NotebookViewModel extends Disposable {
this._localStore.clear();
this._viewCells.forEach(cell => {
cell.save();
cell.dispose();
});
super.dispose();
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册