protected virtual EditorPartCollection GetDefaultEditorPart() { var originalEditors = base.CreateEditorParts(); var editors = new List <EditorPart>(); // copy original editors foreach (EditorPart editorPart in originalEditors) { editors.Add(editorPart); } // add PropertyEditorPart as the only default editor var propertyEditorPart = new PropertyEditorPart(); propertyEditorPart.ID = "PropertyEditorPartOnly"; // Backward compatibility: portlet category titles may contain plain text or a localized value. // Hidden category check algorithm will work with the localized values. propertyEditorPart.HiddenCategories = this.HiddenPropertyCategories == null ? null : this.HiddenPropertyCategories.Select(pc => SenseNetResourceManager.Current.GetString(pc)).ToList(); propertyEditorPart.HiddenProperties = this.HiddenProperties; editors.Add(propertyEditorPart); return(new EditorPartCollection(editors)); }
protected virtual EditorPartCollection GetDefaultEditorPart() { var originalEditors = base.CreateEditorParts(); var editors = new List <EditorPart>(); // copy original editors foreach (EditorPart editorPart in originalEditors) { editors.Add(editorPart); } // add PropertyEditorPart as the only default editor var propertyEditorPart = new PropertyEditorPart(); propertyEditorPart.ID = "PropertyEditorPartOnly"; propertyEditorPart.HiddenCategories = this.HiddenPropertyCategories; propertyEditorPart.HiddenProperties = this.HiddenProperties; editors.Add(propertyEditorPart); return(new EditorPartCollection(editors)); }
protected virtual EditorPartCollection GetDefaultEditorPart() { var originalEditors = base.CreateEditorParts(); var editors = new List<EditorPart>(); // copy original editors foreach (EditorPart editorPart in originalEditors) editors.Add(editorPart); // add PropertyEditorPart as the only default editor var propertyEditorPart = new PropertyEditorPart(); propertyEditorPart.ID = "PropertyEditorPartOnly"; propertyEditorPart.HiddenCategories = this.HiddenPropertyCategories; propertyEditorPart.HiddenProperties = this.HiddenProperties; editors.Add(propertyEditorPart); return new EditorPartCollection(editors); }