diff options
-rw-r--r-- | main/src/core/MonoDevelop.Ide/ChangeLog | 10 | ||||
-rw-r--r-- | main/src/core/MonoDevelop.Ide/MonoDevelop.Components.Docking/DockGroup.cs | 6 |
2 files changed, 15 insertions, 1 deletions
diff --git a/main/src/core/MonoDevelop.Ide/ChangeLog b/main/src/core/MonoDevelop.Ide/ChangeLog index 899867a27a..35abe93066 100644 --- a/main/src/core/MonoDevelop.Ide/ChangeLog +++ b/main/src/core/MonoDevelop.Ide/ChangeLog @@ -1,3 +1,13 @@ +2010-05-11 Lluis Sanchez Gual <lluis@novell.com> + + * MonoDevelop.Components.Docking/DockGroup.cs: In + RestoreAllocation, make a copy of the items list because + RestoreAllocation can fire events such as VisibleChanged, + and subscribers may do changes in the list. Should fix bug + #600869 - Exception while switching layout from 'Solution' + to 'Default' using the tool bar. + + 2010-05-10 Lluis Sanchez Gual <lluis@novell.com> * MonoDevelop.Ide/IdeStartup.cs: Add command line argument to diff --git a/main/src/core/MonoDevelop.Ide/MonoDevelop.Components.Docking/DockGroup.cs b/main/src/core/MonoDevelop.Ide/MonoDevelop.Components.Docking/DockGroup.cs index abc72d3b47..2dfc4ef7ca 100644 --- a/main/src/core/MonoDevelop.Ide/MonoDevelop.Components.Docking/DockGroup.cs +++ b/main/src/core/MonoDevelop.Ide/MonoDevelop.Components.Docking/DockGroup.cs @@ -314,7 +314,11 @@ namespace MonoDevelop.Components.Docking { base.RestoreAllocation (); allocStatus = Size >= 0 ? AllocStatus.RestorePending : AllocStatus.NotSet; - foreach (DockObject ob in dockObjects) + + // Make a copy because RestoreAllocation can fire events such as VisibleChanged, + // and subscribers may do changes in the list. + List<DockObject> copy = new List<DockObject> (dockObjects); + foreach (DockObject ob in copy) ob.RestoreAllocation (); } |