Skip to content

Commit

Permalink
Fixed LayoutRoot implementation of IXmlSerializable.ReadXml to read t…
Browse files Browse the repository at this point in the history
…he 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.
  • Loading branch information
Paul Martin committed Oct 31, 2019
1 parent 68ccaa6 commit 71d0ae9
Showing 1 changed file with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -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/
Expand Down Expand Up @@ -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 )
Expand Down

0 comments on commit 71d0ae9

Please sign in to comment.