Browse Source

Fixed crash when closing Add Reference dialog while search is still running.

4.1
Daniel Grunwald 14 years ago
parent
commit
a8a16ef26f
  1. 4
      src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/GacReferencePanel.cs

4
src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/GacReferencePanel.cs

@ -154,6 +154,10 @@ namespace ICSharpCode.SharpDevelop.Gui @@ -154,6 +154,10 @@ namespace ICSharpCode.SharpDevelop.Gui
void searchTask_RunWorkerCompleted(object sender, RunWorkerCompletedEventArgs e)
{
if (this.IsDisposed) {
// avoid crash when dialog is closed before search is completed
return;
}
searchButton.Text = "Search"; this.toolTip.SetToolTip(searchButton, searchButton.Text);
filterTextBox.ReadOnly = false;
if (resultList != null && resultList.Count > 0) {

Loading…
Cancel
Save