protected override void OnClosed(EventArgs e) { base.OnClosed(e); Dispose(); codeCompletionListView.Dispose(); codeCompletionListView = null; declarationViewWindow.Dispose(); declarationViewWindow = null; }
protected override void Dispose(bool disposing) { if (disposing) { document.DocumentAboutToBeChanged -= DocumentAboutToBeChanged; document.DocumentChanged -= DocumentDocumentChanged; if (codeCompletionListView != null) { codeCompletionListView.Dispose(); codeCompletionListView = null; } if (declarationViewWindow != null) { declarationViewWindow.Dispose(); declarationViewWindow = null; } } base.Dispose(disposing); }