import org.argeo.eclipse.ui.utils.CommandUtils;
import org.argeo.jcr.JcrUtils;
import org.argeo.slc.SlcException;
-import org.argeo.slc.client.ui.dist.DistConstants;
import org.argeo.slc.client.ui.dist.DistImages;
import org.argeo.slc.client.ui.dist.DistPlugin;
import org.argeo.slc.client.ui.dist.commands.DeleteArtifacts;
// Business Objects
private Node modularDistribution;
+ // private Node modularDistributionBase;
// This page widgets
private NodeViewerComparator comparator;
private Text filterTxt;
private final static String FILTER_HELP_MSG = "Enter filter criterion separated by a space";
- private Node moduleParent;
-
public ModuleListPage(FormEditor formEditor, String title,
Node modularDistribution) {
super(formEditor, PAGE_ID, title);
// Create a dynamic operand for each property on which we want to
// filter
DynamicOperand catDO = factory.propertyValue(
- source.getSelectorName(), SlcNames.SLC_MODULE_CATEGORY);
+ source.getSelectorName(), SlcNames.SLC_CATEGORY);
DynamicOperand nameDO = factory.propertyValue(
- source.getSelectorName(), SlcNames.SLC_MODULE_NAME);
+ source.getSelectorName(), SlcNames.SLC_NAME);
DynamicOperand versionDO = factory.propertyValue(
- source.getSelectorName(), SlcNames.SLC_MODULE_VERSION);
+ source.getSelectorName(), SlcNames.SLC_VERSION);
String path = modularDistribution.getPath() + "/"
+ SlcNames.SLC_MODULES;
// Name
TableViewerColumn col = new TableViewerColumn(viewer, SWT.NONE);
- col.getColumn().setWidth(300);
- col.getColumn().setText("Name");
+ col.getColumn().setWidth(220);
+ col.getColumn().setText("Category");
col.setLabelProvider(new ColumnLabelProvider() {
@Override
public String getText(Object element) {
- return JcrUtils.get((Node) element,
- DistConstants.SLC_BUNDLE_NAME);
+ return JcrUtils.get((Node) element, SlcNames.SLC_CATEGORY);
}
});
col.getColumn().addSelectionListener(getSelectionAdapter(0));
- propertiesList.add(DistConstants.SLC_BUNDLE_NAME);
+ propertiesList.add(SlcNames.SLC_CATEGORY);
propertyTypesList.add(PropertyType.STRING);
// Symbolic name
- col = new TableViewerColumn(viewer, SWT.V_SCROLL);
- col.getColumn().setWidth(300);
- col.getColumn().setText("Symbolic Name");
+ col = new TableViewerColumn(viewer, SWT.NONE);
+ col.getColumn().setWidth(220);
+ col.getColumn().setText("Name");
col.setLabelProvider(new ColumnLabelProvider() {
@Override
public String getText(Object element) {
- return JcrUtils.get((Node) element, SLC_SYMBOLIC_NAME);
+ return JcrUtils.get((Node) element, SLC_NAME);
}
});
col.getColumn().addSelectionListener(getSelectionAdapter(1));
- propertiesList.add(SLC_SYMBOLIC_NAME);
+ propertiesList.add(SLC_NAME);
propertyTypesList.add(PropertyType.STRING);
// Version
col = new TableViewerColumn(viewer, SWT.NONE);
- col.getColumn().setWidth(130);
+ col.getColumn().setWidth(160);
col.getColumn().setText("Version");
col.setLabelProvider(new ColumnLabelProvider() {
@Override
public String getText(Object element) {
- return JcrUtils.get((Node) element, SLC_BUNDLE_VERSION);
+ return JcrUtils.get((Node) element, SLC_VERSION);
}
});
col.getColumn().addSelectionListener(getSelectionAdapter(2));
- propertiesList.add(SLC_BUNDLE_VERSION);
+ propertiesList.add(SLC_VERSION);
propertyTypesList.add(PropertyType.STRING);
final Table table = viewer.getTable();