private void BuildEditorInternal(ElementEditorContext context, Func <IElementDriver, EditorResult> action) { var descriptor = context.Element.Descriptor; var drivers = _elementManager.GetDrivers(descriptor); foreach (var driver in drivers) { var editorResult = action(driver); if (editorResult == null) { continue; } foreach (var editor in editorResult.Editors) { editor.ElementDescriptor = descriptor; editor.ElementData = context.Element.Data; editor.Content = context.Content; context.EditorResult.Add(editor); } } }