Browse Source

Enclosed / Parent Editors are now cloned correctly

frogsoftware 1 year ago
parent
commit
060a820217
1 changed files with 2 additions and 1 deletions
  1. 2 1
      inabox.wpf/DynamicGrid/DynamicEditorGrid.xaml.cs

+ 2 - 1
inabox.wpf/DynamicGrid/DynamicEditorGrid.xaml.cs

@@ -649,12 +649,13 @@ namespace InABox.DynamicGrid
                     var parent = iProp.GetParentWithEditor();
                     if(parent is not null)
                     {
-                        var parentEditor = parent.Editor;
+                        var parentEditor = parent.Editor?.CloneEditor();
 
                         if(parentEditor is not null)
                         {
                             OnGridCustomiseEditor?.Invoke(this, new DynamicGridColumn { ColumnName = parent.Name }, parentEditor);
                         }
+                        
                         if(parentEditor is not null && parentEditor.Editable.EditorVisible())
                         {
                             var page = string.IsNullOrWhiteSpace(parentEditor.Page)