[mapguide-commits] r8002 - trunk/Tools/Maestro/Maestro.MapViewer
svn_mapguide at osgeo.org
svn_mapguide at osgeo.org
Sun Mar 30 07:01:53 PDT 2014
Author: jng
Date: 2014-03-30 07:01:52 -0700 (Sun, 30 Mar 2014)
New Revision: 8002
Modified:
trunk/Tools/Maestro/Maestro.MapViewer/Legend.cs
Log:
Add guard to prevent updating a disposed legend
Modified: trunk/Tools/Maestro/Maestro.MapViewer/Legend.cs
===================================================================
--- trunk/Tools/Maestro/Maestro.MapViewer/Legend.cs 2014-03-30 13:12:38 UTC (rev 8001)
+++ trunk/Tools/Maestro/Maestro.MapViewer/Legend.cs 2014-03-30 14:01:52 UTC (rev 8002)
@@ -201,9 +201,14 @@
private void bgLegendUpdate_RunWorkerCompleted(object sender, RunWorkerCompletedEventArgs e)
{
+ //Whatever's housing this component has already bailed so let's bail too
+ if (trvLegend.IsDisposed)
+ return;
+
this.IsBusy = bgLegendUpdate.IsBusy;
var nodes = e.Result as TreeNode[];
trvLegend.BeginUpdate();
+
ClearNodes(trvLegend.Nodes);
if (nodes != null)
{
More information about the mapguide-commits
mailing list