Implemented collapsible columns.

This commit is contained in:
Sipke Schoorstra
2015-04-04 17:22:17 +02:00
parent 42d7eeec18
commit 11dc9309f0
44 changed files with 165 additions and 72 deletions

View File

@@ -49,13 +49,13 @@ namespace Orchard.Layouts.Providers {
var elementName = GetDisplayName(shapeDescriptor.Value.BindingSource);
var closureDescriptor = shapeDescriptor;
yield return new ElementDescriptor(elementType, shapeType, T(elementName), T("An element that renders the {0} shape.", shapeType), snippetElement.Category) {
Display = displayContext => Displaying(displayContext, closureDescriptor.Value),
Displaying = displayContext => Displaying(displayContext, closureDescriptor.Value),
ToolboxIcon = "\uf10c"
};
}
}
private void Displaying(ElementDisplayContext context, ShapeDescriptor shapeDescriptor) {
private void Displaying(ElementDisplayingContext context, ShapeDescriptor shapeDescriptor) {
var shapeType = shapeDescriptor.ShapeType;
var shape = _shapeFactory.Value.Create(shapeType);
context.ElementShape.Snippet = shape;