summaryrefslogtreecommitdiffstats
path: root/dozentenmodul/src
diff options
context:
space:
mode:
authorralph isenmann2021-06-24 10:45:19 +0200
committerralph isenmann2021-06-24 10:45:19 +0200
commit1a610bc773863a3c93893e398d50448f75e35a2a (patch)
treeeab31614a4de5e7575ef16915c6cb3eb0ff6028e /dozentenmodul/src
parent[client] Update project structure, related to container model. (diff)
downloadtutor-module-1a610bc773863a3c93893e398d50448f75e35a2a.tar.gz
tutor-module-1a610bc773863a3c93893e398d50448f75e35a2a.tar.xz
tutor-module-1a610bc773863a3c93893e398d50448f75e35a2a.zip
[client] Use the label of ContainerImageType it the GUI
Diffstat (limited to 'dozentenmodul/src')
-rw-r--r--dozentenmodul/src/main/java/org/openslx/dozmod/gui/panel/ContainerPanel.java3
-rw-r--r--dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/ImageMetaDataPageLayout.java3
2 files changed, 4 insertions, 2 deletions
diff --git a/dozentenmodul/src/main/java/org/openslx/dozmod/gui/panel/ContainerPanel.java b/dozentenmodul/src/main/java/org/openslx/dozmod/gui/panel/ContainerPanel.java
index e37494ce..b2201239 100644
--- a/dozentenmodul/src/main/java/org/openslx/dozmod/gui/panel/ContainerPanel.java
+++ b/dozentenmodul/src/main/java/org/openslx/dozmod/gui/panel/ContainerPanel.java
@@ -89,13 +89,14 @@ public class ContainerPanel extends JPanel {
scrollableTextArea.setPreferredSize(Gui.getScaledDimension(0, 200));
grdContainer.add(scrollableTextArea, 2).fill(true, true).expand(true, true);
+ // TODO copy-paste in ImageMetaDataPageLayout for this ContainerImageType component
lblContainerImageType = new QLabel("Container Image Type");
cboContainerImageType = new ComboBox<>(
new ComboBox.ComboBoxRenderer<ContainerMeta.ContainerImageType>() {
@Override public String renderItem(ContainerMeta.ContainerImageType item) {
if (item == null)
return "null";
- return item.name();
+ return item.toString(); // shows the provided label
}
}, ContainerMeta.ContainerImageType.class);
for (ContainerMeta.ContainerImageType type : ContainerMeta.ContainerImageType.values()) {
diff --git a/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/ImageMetaDataPageLayout.java b/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/ImageMetaDataPageLayout.java
index db7284c3..bec7e3dc 100644
--- a/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/ImageMetaDataPageLayout.java
+++ b/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/ImageMetaDataPageLayout.java
@@ -75,13 +75,14 @@ public abstract class ImageMetaDataPageLayout extends WizardPage {
grid.add(chkLicenseRestricted, 2);
grid.nextRow();
+ // TODO copy-paste in ContainerPanel for this ContainerImageType component
lblContainerImageType = new QLabel("Container Image Type");
cboContainerImageType = new ComboBox<>(
new ComboBox.ComboBoxRenderer<ContainerMeta.ContainerImageType>() {
@Override public String renderItem(ContainerMeta.ContainerImageType item) {
if (item == null)
return "null";
- return item.name();
+ return item.toString(); // shows the provided label
}
}, ContainerMeta.ContainerImageType.class);
for (ContainerMeta.ContainerImageType type : ContainerMeta.ContainerImageType.values()) {