use of com.servoy.j2db.ui.IPortalComponent in project servoy-client by Servoy.
the class ComponentFactory method createPortal.
private static IComponent createPortal(IApplication application, Form form, Portal meta, IDataProviderLookup dataProviderLookup, IScriptExecuter el, boolean printing) {
RuntimePortal scriptable = new RuntimePortal(application.getItemFactory().createChangesRecorder(), application);
IPortalComponent portalComponent = application.getItemFactory().createPortalComponent(scriptable, meta, form, dataProviderLookup, el, printing);
scriptable.setComponent(portalComponent, meta);
IStyleSheet ss = ComponentFactory.getCSSStyleForForm(application, form);
if (ss != null) {
String lookupname = "portal";
if (meta.getStyleClass() != null && !"".equals(meta.getStyleClass())) {
lookupname += '.' + meta.getStyleClass();
}
portalComponent.setRowStyles(ss, ss.getCSSRule(lookupname + " " + ISupportRowStyling.CLASS_ODD), ss.getCSSRule(lookupname + " " + ISupportRowStyling.CLASS_EVEN), ss.getCSSRule(lookupname + " " + ISupportRowStyling.CLASS_SELECTED), ss.getCSSRule(lookupname + " " + ISupportRowStyling.CLASS_HEADER));
}
return portalComponent;
}
Aggregations