From 71d0ae9681e505ca824df9788a601e5442e37f79 Mon Sep 17 00:00:00 2001 From: Paul Martin Date: Thu, 31 Oct 2019 17:51:52 +0000 Subject: [PATCH 1/2] Fixed LayoutRoot implementation of IXmlSerializable.ReadXml to read the end element. Implementations of IXmlSerializable.ReadXml are required to read the entire element from beginning to end, including all of its contents. Prior to this change it would not read the end element from the reader. This would cause issues if the LayoutRoot was being serialized as part of a parent object's xml serialization as the XmlReader would be left on an unexpected element. --- .../Src/Xceed.Wpf.AvalonDock/Layout/LayoutRoot.cs | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.AvalonDock/Layout/LayoutRoot.cs b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.AvalonDock/Layout/LayoutRoot.cs index 8e10365e4..fcd13d683 100644 --- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.AvalonDock/Layout/LayoutRoot.cs +++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.AvalonDock/Layout/LayoutRoot.cs @@ -1,11 +1,11 @@ /************************************************************************************* - + Toolkit for WPF Copyright (C) 2007-2018 Xceed Software Inc. This program is provided to you under the terms of the Microsoft Public - License (Ms-PL) as published at http://wpftoolkit.codeplex.com/license + License (Ms-PL) as published at http://wpftoolkit.codeplex.com/license For more features, controls, and fast professional support, pick up the Plus Edition at https://xceed.com/xceed-toolkit-plus-for-wpf/ @@ -672,6 +672,9 @@ public void ReadXml( XmlReader reader ) { this.Hidden.Add( ( LayoutAnchorable )hiddenObject ); } + + //Read the closing end element of LayoutRoot + reader.ReadEndElement(); } public void WriteXml( XmlWriter writer ) From 78674d35b4628ed2ce3fa584fdcc8d0a2452d52a Mon Sep 17 00:00:00 2001 From: Paul Martin Date: Thu, 31 Oct 2019 17:57:55 +0000 Subject: [PATCH 2/2] Revert whitespace changes in file header. --- .../Src/Xceed.Wpf.AvalonDock/Layout/LayoutRoot.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.AvalonDock/Layout/LayoutRoot.cs b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.AvalonDock/Layout/LayoutRoot.cs index fcd13d683..d311a2647 100644 --- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.AvalonDock/Layout/LayoutRoot.cs +++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.AvalonDock/Layout/LayoutRoot.cs @@ -1,11 +1,11 @@ /************************************************************************************* - + Toolkit for WPF Copyright (C) 2007-2018 Xceed Software Inc. This program is provided to you under the terms of the Microsoft Public - License (Ms-PL) as published at http://wpftoolkit.codeplex.com/license + License (Ms-PL) as published at http://wpftoolkit.codeplex.com/license For more features, controls, and fast professional support, pick up the Plus Edition at https://xceed.com/xceed-toolkit-plus-for-wpf/