Skip to content

Commit

Permalink
- Propage the Actions, even when the elements are null
Browse files Browse the repository at this point in the history
  • Loading branch information
Smurf-IV committed Jun 16, 2024
1 parent 0aa87a1 commit e69518e
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 8 deletions.
1 change: 1 addition & 0 deletions Documents/Changelog/Changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
=======

## 2024-11-xx - Build 2411 - November 2024
* Resolved [#1381](https://github.com/Krypton-Suite/Standard-Toolkit/issues/1502), Docking Persistence broken since build `##.23.10.303`
* Implemented [#1507](https://github.com/Krypton-Suite/Standard-Toolkit/issues/1507), **[Breaking Change]** `KryptonThemeComboBox`, `KryptonThemeListBox` & `KryptonRibbonGroupThemeComboBox`:
- All controls had their code base updated to one standard.
- The assignment of themes via an index has been removed from all.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -149,10 +149,9 @@ public virtual IDockingElement? Parent
/// </param>
public virtual void PropogateAction(DockingPropogateAction action, string[]? uniqueNames)
{
var countToUse = Math.Min(Count, uniqueNames?.Length ?? 0); // Do not modify! because: https://github.com/Krypton-Suite/Standard-Toolkit/issues/1381
// Propagate the action request to all the child elements
// Propagate the action request to all the child elements (Even the null ones !!)
// (use reverse order so if element removes itself we still have a valid loop)
for (var i = countToUse - 1; i >= 0; i--)
for (var i = Count - 1; i >= 0; i--)
{
{
this[i]!.PropogateAction(action, uniqueNames);
Expand Down Expand Up @@ -542,11 +541,8 @@ public virtual void LoadElementFromXml(XmlReader xmlReader, KryptonPageCollectio
// Find a child docking element with the matching name
IDockingElement? child = this[xmlReader.GetAttribute(@"N")!];

if (child != null)
{
// Let derived class perform child element specific processing
LoadChildDockingElement(xmlReader, pages, child);
}
// Let derived class perform child element specific processing
LoadChildDockingElement(xmlReader, pages, child);
}
}

Expand Down

0 comments on commit e69518e

Please sign in to comment.