X-Git-Url: https://gerrit.simantics.org/r/gitweb?a=blobdiff_plain;f=org.simantics.district.network.ui%2Fsrc%2Forg%2Fsimantics%2Fdistrict%2Fnetwork%2Fui%2Ftechtype%2Ftable%2FTechTypeTable.java;h=f15be971df842fab31d5527669dc79e1fe0e29df;hb=refs%2Fheads%2Frelease%2F1.35.3;hp=b18e10c8d63f50c8971ef2fd90150ae783b37e69;hpb=0e3c772d52e44827cf4c30f31d61000a664d9266;p=simantics%2Fdistrict.git diff --git a/org.simantics.district.network.ui/src/org/simantics/district/network/ui/techtype/table/TechTypeTable.java b/org.simantics.district.network.ui/src/org/simantics/district/network/ui/techtype/table/TechTypeTable.java index b18e10c8..f15be971 100644 --- a/org.simantics.district.network.ui/src/org/simantics/district/network/ui/techtype/table/TechTypeTable.java +++ b/org.simantics.district.network.ui/src/org/simantics/district/network/ui/techtype/table/TechTypeTable.java @@ -181,7 +181,7 @@ public class TechTypeTable extends Composite { bodyDataLayer.setConfigLabelAccumulator(new IConfigLabelAccumulator() { @Override public void accumulateConfigLabels(LabelStack configLabels, int columnPosition, int rowPosition) { - if (columnPosition == 0) { + if (bodyDataProvider.isCheckBoxColumn(columnPosition)) { configLabels.addLabel(CHECK_BOX_LABEL); } else if (validationResult != null && keyName != null) { int keyColumn = bodyDataProvider.getVariableIndex(keyName); @@ -270,7 +270,7 @@ public class TechTypeTable extends Composite { new EditableRule() { @Override public boolean isEditable(int columnIndex, int rowIndex) { - return columnIndex == 0; + return bodyDataProvider.isEditable(columnIndex, rowIndex); } }); @@ -334,6 +334,10 @@ public class TechTypeTable extends Composite { super.dispose(); } + public Resource getComponentType() { + return this.componentType; + } + public void setComponentType(Resource componentType) { if (Objects.equals(this.componentType, componentType)) return;