diff options
author | Mürsel Türk | 2020-07-07 12:07:06 +0200 |
---|---|---|
committer | Mürsel Türk | 2020-07-07 12:07:06 +0200 |
commit | ef861c83a9f62c9f88664418489a469693f014ee (patch) | |
tree | d140fc58ca58adef88ccd5e603b55e1fe8deef70 | |
parent | [client] Add resource bundle files for window classes. Update the window clas... (diff) | |
download | tutor-module-ef861c83a9f62c9f88664418489a469693f014ee.tar.gz tutor-module-ef861c83a9f62c9f88664418489a469693f014ee.tar.xz tutor-module-ef861c83a9f62c9f88664418489a469693f014ee.zip |
[client] Add resource bundle files for wizard/page/layout classes. Update the wizard/page/layout classes accordingly.
12 files changed, 236 insertions, 61 deletions
diff --git a/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/ImageCustomPermissionPageLayout.java b/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/ImageCustomPermissionPageLayout.java index e833090b..c4e94f88 100644 --- a/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/ImageCustomPermissionPageLayout.java +++ b/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/ImageCustomPermissionPageLayout.java @@ -10,6 +10,7 @@ import javax.swing.JPanel; import org.openslx.dozmod.gui.configurator.ImagePermissionConfigurator; import org.openslx.dozmod.gui.helper.GridManager; +import org.openslx.dozmod.gui.helper.I18n; import org.openslx.dozmod.gui.wizard.Wizard; import org.openslx.dozmod.gui.wizard.WizardPage; @@ -30,8 +31,8 @@ public class ImageCustomPermissionPageLayout extends WizardPage { * @param wizard */ public ImageCustomPermissionPageLayout(Wizard wizard) { - super(wizard, "Berechtigungen festlegen"); - setDescription("Legen Sie hier die gewünschten Berechtigungen fest."); + super(wizard, I18n.PAGE_LAYOUT.getString("ImageCustomPermission.WizardPage.title")); + setDescription(I18n.PAGE_LAYOUT.getString("ImageCustomPermission.WizardPage.description")); GridManager grid = new GridManager(this, 1, false); // custom permissions @@ -40,25 +41,29 @@ public class ImageCustomPermissionPageLayout extends WizardPage { grid.nextRow(); // -- default permissions -- - JLabel defaultPermLabel = new JLabel("Standardberechtigungen"); + JLabel defaultPermLabel = new JLabel( + I18n.PAGE_LAYOUT.getString("ImageCustomPermission.Label.defaultPerm.text")); defaultPermLabel.setBorder(BorderFactory.createEmptyBorder(10, 5, 0, 0)); defaultPermLabel.setFont(defaultPermLabel.getFont().deriveFont(Font.BOLD)); grid.add(defaultPermLabel); - JLabel defaultDescriptionLabel = new JLabel("<html><body style ='width:100%'> " - + "Legen Sie hier die Berechtigungen für alle anderen (nicht in der Liste " - + "angezeigten) Benutzer fest.</body></html>"); + JLabel defaultDescriptionLabel = new JLabel( + I18n.PAGE_LAYOUT.getString("ImageCustomPermission.Label.defaultDesc.text")); defaultDescriptionLabel.setBorder(BorderFactory.createEmptyBorder(0, 10, 0, 0)); grid.add(defaultDescriptionLabel).fill(true, false).expand(true, false); JPanel permissionsPanel = new JPanel(); permissionsPanel.setLayout(new BoxLayout(permissionsPanel, BoxLayout.LINE_AXIS)); - chkPermissionLink = new JCheckBox("Verlinken"); + chkPermissionLink = new JCheckBox( + I18n.PAGE_LAYOUT.getString("ImageCustomPermission.CheckBox.permissionLink.text")); chkPermissionLink.setSelected(true); - chkPermissionRead = new JCheckBox("Download"); + chkPermissionRead = new JCheckBox( + I18n.PAGE_LAYOUT.getString("ImageCustomPermission.CheckBox.permissionRead.text")); chkPermissionRead.setSelected(true); - chkPermissionEdit = new JCheckBox("Bearbeiten"); - chkPermissionAdmin = new JCheckBox("Admin"); + chkPermissionEdit = new JCheckBox( + I18n.PAGE_LAYOUT.getString("ImageCustomPermission.CheckBox.permissionEdit.text")); + chkPermissionAdmin = new JCheckBox( + I18n.PAGE_LAYOUT.getString("ImageCustomPermission.CheckBox.permissionAdmin.text")); permissionsPanel.add(chkPermissionLink); permissionsPanel.add(chkPermissionRead); permissionsPanel.add(chkPermissionEdit); 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 358fdd0d..707959f3 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 @@ -11,6 +11,7 @@ import org.openslx.dozmod.gui.control.ComboBox; import org.openslx.dozmod.gui.control.ComboBox.ComboBoxRenderer; import org.openslx.dozmod.gui.control.QLabel; import org.openslx.dozmod.gui.helper.GridManager; +import org.openslx.dozmod.gui.helper.I18n; import org.openslx.dozmod.gui.wizard.Wizard; import org.openslx.dozmod.gui.wizard.WizardPage; import org.openslx.thrifthelper.Comparators; @@ -32,12 +33,12 @@ public abstract class ImageMetaDataPageLayout extends WizardPage { * @param wizard */ public ImageMetaDataPageLayout(Wizard wizard) { - super(wizard, "Metadaten"); - setDescription("Geben Sie bitte einen aussagekräftigen Namen für die neue VM ein."); + super(wizard, I18n.PAGE_LAYOUT.getString("ImageMetaData.WizardPage.title")); + setDescription(I18n.PAGE_LAYOUT.getString("ImageMetaData.WizardPage.description")); GridManager grid = new GridManager(this, 2, false); - QLabel osCaption = new QLabel("Betriebssystem"); + QLabel osCaption = new QLabel(I18n.PAGE_LAYOUT.getString("ImageMetaData.Label.OS.text")); cboOperatingSystem = new ComboBox<>(Comparators.operatingSystem, new ComboBoxRenderer<OperatingSystem>() { @Override public String renderItem(OperatingSystem item) { @@ -50,7 +51,7 @@ public abstract class ImageMetaDataPageLayout extends WizardPage { grid.add(osCaption); grid.add(cboOperatingSystem); - sCommandCaption = new QLabel("Startbefehl"); + sCommandCaption = new QLabel(I18n.PAGE_LAYOUT.getString("ImageMetaData.Label.startCommand.text")); startCommand = new JTextArea(1, 50); startCommand.setMinimumSize(Gui.getScaledDimension(0, 35)); startCommand.setLineWrap(true); @@ -62,7 +63,7 @@ public abstract class ImageMetaDataPageLayout extends WizardPage { grid.add(startCommandPane).fill(true, false).expand(true, false); grid.nextRow(); - QLabel descriptionCaption = new QLabel("Beschreibung"); + QLabel descriptionCaption = new QLabel(I18n.PAGE_LAYOUT.getString("ImageMetaData.Label.description.text")); txtDescription = new JTextArea(5, 50); txtDescription.setMinimumSize(Gui.getScaledDimension(0, 70)); txtDescription.setLineWrap(true); @@ -74,13 +75,14 @@ public abstract class ImageMetaDataPageLayout extends WizardPage { grid.add(descPane).fill(true, false).expand(true, false); grid.nextRow(); - chkLicenseRestricted = new JCheckBox("VM enthält lizenzpflichtige Software"); + chkLicenseRestricted = new JCheckBox( + I18n.PAGE_LAYOUT.getString("ImageMetaData.CheckBox.licenseRestricted.text")); chkLicenseRestricted.setSelected(true); grid.add(chkLicenseRestricted, 2); grid.nextRow(); // -- end permissions group -- - chkIsTemplate = new JCheckBox("Vorlage erstellen"); + chkIsTemplate = new JCheckBox(I18n.PAGE_LAYOUT.getString("ImageMetaData.CheckBox.isTemplate.text")); grid.add(chkIsTemplate, 2); grid.nextRow(); diff --git a/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/ImageUploadPageLayout.java b/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/ImageUploadPageLayout.java index 6f0e0afc..ceb1ed58 100644 --- a/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/ImageUploadPageLayout.java +++ b/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/ImageUploadPageLayout.java @@ -11,6 +11,7 @@ import javax.swing.JTextField; import org.openslx.dozmod.gui.control.QLabel; import org.openslx.dozmod.gui.helper.GridManager; +import org.openslx.dozmod.gui.helper.I18n; import org.openslx.dozmod.gui.wizard.Wizard; import org.openslx.dozmod.gui.wizard.WizardPage; @@ -28,29 +29,30 @@ public abstract class ImageUploadPageLayout extends WizardPage { * Page for uploading an imagefile */ public ImageUploadPageLayout(Wizard wizard) { - super(wizard, "Neue VM anlegen"); - setDescription("Bitte wählen Sie eine Virtuelle Maschine zum Hochladen aus."); + super(wizard, I18n.PAGE_LAYOUT.getString("ImageUpload.WizardPage.title")); + setDescription(I18n.PAGE_LAYOUT.getString("ImageUpload.WizardPage.description")); GridManager grid = new GridManager(this, 3, false); // -- Browse for VM -- - QLabel imageFileCaption = new QLabel("Virtuelle Maschine"); + QLabel imageFileCaption = new QLabel(I18n.PAGE_LAYOUT.getString("ImageUpload.Label.imageFile.text")); txtImageFile = new JTextField(); txtImageFile.setEditable(false); - btnBrowseForImage = new JButton("Durchsuchen"); + btnBrowseForImage = new JButton(I18n.PAGE_LAYOUT.getString("ImageUpload.Button.browseForImage.text")); btnBrowseForImage.setMnemonic(KeyEvent.VK_B); grid.add(imageFileCaption); grid.add(txtImageFile).fill(true, false).expand(true, false); grid.add(btnBrowseForImage); grid.nextRow(); - lblImageName = new QLabel("Name"); + lblImageName = new QLabel(I18n.PAGE_LAYOUT.getString("ImageUpload.Label.imageName.text")); txtImageName = new JTextField(); grid.add(lblImageName); grid.add(txtImageName, 2, 1).fill(true, false).expand(true, false); grid.nextRow(); // -- Software license changed - shown only in UploadWizard -- - chkLicenseRestricted = new JCheckBox("enthält lizenzpflichtige Software"); + chkLicenseRestricted = new JCheckBox( + I18n.PAGE_LAYOUT.getString("ImageUpload.CheckBox.licenseRestricted.text")); chkLicenseRestricted.setVisible(false); grid.skip(); grid.add(chkLicenseRestricted, 2, 1).fill(false, false).expand(true, false); @@ -59,18 +61,14 @@ public abstract class ImageUploadPageLayout extends WizardPage { grid.add(Box.createVerticalGlue(), 3).expand(true, true); txtInfoText = new JTextArea(); - txtInfoText.setBorder(BorderFactory.createTitledBorder("Hinweis")); + txtInfoText.setBorder(BorderFactory.createTitledBorder( + I18n.PAGE_LAYOUT.getString("ImageUpload.TextArea.info.title"))); txtInfoText.setLineWrap(true); txtInfoText.setWrapStyleWord(true); txtInfoText.setEditable(false); txtInfoText.setFocusable(false); txtInfoText.setOpaque(false); - txtInfoText.setText("Haben Sie noch keine eigene Virtuelle Maschine erstellt," - + " können Sie sich in der Übersicht eine Virtuelle Maschine als Vorlage herunterladen," - + " diese an Ihre Bedürfnisse anpassen und anschließend über diesen Assistenten hochladen." - + "\n\nWenn Sie die VM einer bestehenden Veranstaltung aktualisieren möchten," - + " öffnen Sie die Detailansicht der bestehenden VM und wählen Sie 'Neue VM-Version hochladen'." - + " Dadurch bleiben bestehende Berechtigungen, sowie Verknüpfungen zu Veranstaltungen erhalten."); + txtInfoText.setText(I18n.PAGE_LAYOUT.getString("ImageUpload.TextArea.info.text")); grid.add(txtInfoText, 3).fill(true, false).expand(true, false); grid.nextRow(); diff --git a/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/ImageUploadSummaryPageLayout.java b/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/ImageUploadSummaryPageLayout.java index c53fd907..1781a1d9 100644 --- a/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/ImageUploadSummaryPageLayout.java +++ b/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/ImageUploadSummaryPageLayout.java @@ -6,6 +6,7 @@ import javax.swing.JLabel; import org.openslx.dozmod.gui.control.BlockProgressBar; import org.openslx.dozmod.gui.helper.GridManager; +import org.openslx.dozmod.gui.helper.I18n; import org.openslx.dozmod.gui.wizard.Wizard; import org.openslx.dozmod.gui.wizard.WizardPage; @@ -17,8 +18,8 @@ public class ImageUploadSummaryPageLayout extends WizardPage { protected final JLabel lblHelpText; public ImageUploadSummaryPageLayout(Wizard wizard) { - super(wizard, "Fertig!"); - setDescription("Assistent abgeschlossen"); + super(wizard, I18n.PAGE_LAYOUT.getString("ImageUploadSummary.WizardPage.title")); + setDescription(I18n.PAGE_LAYOUT.getString("ImageUploadSummary.WizardPage.description")); GridManager grid = new GridManager(this, 1); ctlUploadProgressBar = new BlockProgressBar(null); @@ -36,7 +37,7 @@ public class ImageUploadSummaryPageLayout extends WizardPage { grid.add(Box.createVerticalGlue()).expand(true, true); grid.nextRow(); - chkCreateLecture = new JCheckBox("Veranstaltung zu dieser VM erstellen"); + chkCreateLecture = new JCheckBox(I18n.PAGE_LAYOUT.getString("ImageUploadSummary.CheckBox.createLecture.text")); chkCreateLecture.setVisible(false); grid.add(chkCreateLecture); grid.nextRow(); diff --git a/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/LectureCreationPageLayout.java b/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/LectureCreationPageLayout.java index 5df21c1d..91abcf92 100644 --- a/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/LectureCreationPageLayout.java +++ b/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/LectureCreationPageLayout.java @@ -13,6 +13,7 @@ import org.openslx.dozmod.gui.Gui; import org.openslx.dozmod.gui.control.QDatePickerImpl; import org.openslx.dozmod.gui.control.QLabel; import org.openslx.dozmod.gui.helper.GridManager; +import org.openslx.dozmod.gui.helper.I18n; import org.openslx.dozmod.gui.wizard.Wizard; import org.openslx.dozmod.gui.wizard.WizardPage; @@ -35,12 +36,12 @@ public abstract class LectureCreationPageLayout extends WizardPage { */ public LectureCreationPageLayout(Wizard wizard, String title) { super(wizard, title); - setDescription("Geben Sie bitte einen aussagekräftigen Namen für die neue Veranstaltung ein."); + setDescription(I18n.PAGE_LAYOUT.getString("LectureCreation.WizardPage.description")); GridManager grid = new GridManager(this, 3); // lecture name txtName = new JTextField(); - grid.add(new QLabel("Veranstaltungsname")); + grid.add(new QLabel(I18n.PAGE_LAYOUT.getString("LectureCreation.Label.name.text"))); grid.add(txtName, 2).fill(true, false).expand(true, false); grid.nextRow(); @@ -51,26 +52,26 @@ public abstract class LectureCreationPageLayout extends WizardPage { JScrollPane.HORIZONTAL_SCROLLBAR_NEVER); txtDescription.setMinimumSize(Gui.getScaledDimension(0, 60)); descPane.setMinimumSize(txtDescription.getMinimumSize()); - grid.add(new QLabel("Beschreibung")); + grid.add(new QLabel(I18n.PAGE_LAYOUT.getString("LectureCreation.Label.description.text"))); grid.add(descPane, 2).fill(true, false).expand(true, false); grid.nextRow(); // Start date/time dtpStartDate = new QDatePickerImpl(); spnStartTime = makeTimeSpinner(0, 0); - grid.add(new QLabel("Startdatum")); + grid.add(new QLabel(I18n.PAGE_LAYOUT.getString("LectureCreation.Label.startTime.text"))); grid.add(dtpStartDate).fill(true, false).expand(true, false); grid.add(spnStartTime); grid.nextRow(); dtpEndDate = new QDatePickerImpl(); spnEndTime = makeTimeSpinner(23, 59); - grid.add(new QLabel("Enddatum")); + grid.add(new QLabel(I18n.PAGE_LAYOUT.getString("LectureCreation.Label.endTime.text"))); grid.add(dtpEndDate).fill(true, false).expand(true, false); grid.add(spnEndTime); grid.nextRow(); - grid.add(new QLabel("Dauer der Veranstaltung: ")); + grid.add(new QLabel(I18n.PAGE_LAYOUT.getString("LectureCreation.Label.period.text"))); lblCalcPeriod = new QLabel(); grid.add(lblCalcPeriod, 2); grid.nextRow(); diff --git a/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/LectureCustomPermissionPageLayout.java b/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/LectureCustomPermissionPageLayout.java index 64afc4df..0615fb0b 100644 --- a/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/LectureCustomPermissionPageLayout.java +++ b/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/LectureCustomPermissionPageLayout.java @@ -10,6 +10,7 @@ import javax.swing.JPanel; import org.openslx.dozmod.gui.configurator.LecturePermissionConfigurator; import org.openslx.dozmod.gui.helper.GridManager; +import org.openslx.dozmod.gui.helper.I18n; import org.openslx.dozmod.gui.wizard.Wizard; import org.openslx.dozmod.gui.wizard.WizardPage; @@ -26,8 +27,8 @@ public abstract class LectureCustomPermissionPageLayout extends WizardPage { * Page for setting custom permissions of a lecture */ public LectureCustomPermissionPageLayout(Wizard wizard) { - super(wizard, "Berechtigungen festlegen"); - setDescription("Legen Sie hier die gewünschten Berechtigungen fest."); + super(wizard, I18n.PAGE_LAYOUT.getString("LectureCustomPermission.WizardPage.title")); + setDescription(I18n.PAGE_LAYOUT.getString("LectureCustomPermission.WizardPage.description")); GridManager grid = new GridManager(this, 1, false); lectureCustomPermissionManager = new LecturePermissionConfigurator(); @@ -35,21 +36,23 @@ public abstract class LectureCustomPermissionPageLayout extends WizardPage { grid.nextRow(); // -- default permissions -- - JLabel defaultPermLabel = new JLabel("Standardberechtigungen"); + JLabel defaultPermLabel = new JLabel( + I18n.PAGE_LAYOUT.getString("LectureCustomPermission.Label.defaultPerm.text")); defaultPermLabel.setBorder(BorderFactory.createEmptyBorder(10, 5, 0, 0)); defaultPermLabel.setFont(defaultPermLabel.getFont().deriveFont(Font.BOLD)); grid.add(defaultPermLabel); - JLabel defaultDescriptionLabel = new JLabel("<html><body style ='width:100%'> " - + "Legen Sie hier die Berechtigungen für alle anderen (nicht in der Liste " - + "angezeigten) Benutzer fest.</body></html>"); + JLabel defaultDescriptionLabel = new JLabel( + I18n.PAGE_LAYOUT.getString("LectureCustomPermission.Label.defaultDesc.text")); defaultDescriptionLabel.setBorder(BorderFactory.createEmptyBorder(0, 10, 0, 0)); grid.add(defaultDescriptionLabel).fill(true, false).expand(true, false); JPanel permissionsPanel = new JPanel(); permissionsPanel.setLayout(new BoxLayout(permissionsPanel, BoxLayout.LINE_AXIS)); - chkPermissionEdit = new JCheckBox("Bearbeiten"); - chkPermissionAdmin = new JCheckBox("Admin"); + chkPermissionEdit = new JCheckBox( + I18n.PAGE_LAYOUT.getString("LectureCustomPermission.CheckBox.permissionEdit.text")); + chkPermissionAdmin = new JCheckBox( + I18n.PAGE_LAYOUT.getString("LectureCustomPermission.CheckBox.permissionAdmin.text")); permissionsPanel.add(chkPermissionEdit); permissionsPanel.add(chkPermissionAdmin); diff --git a/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/LectureImageListPageLayout.java b/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/LectureImageListPageLayout.java index 7461df1e..ef7baf36 100644 --- a/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/LectureImageListPageLayout.java +++ b/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/LectureImageListPageLayout.java @@ -3,6 +3,7 @@ package org.openslx.dozmod.gui.wizard.layout; import org.openslx.dozmod.gui.control.ImageListViewer; import org.openslx.dozmod.gui.control.ImageListViewer.FilterType; import org.openslx.dozmod.gui.helper.GridManager; +import org.openslx.dozmod.gui.helper.I18n; import org.openslx.dozmod.gui.wizard.Wizard; import org.openslx.dozmod.gui.wizard.WizardPage; @@ -15,8 +16,8 @@ public abstract class LectureImageListPageLayout extends WizardPage { * Page for setting custom permissions of a lecture */ public LectureImageListPageLayout(Wizard wizard) { - super(wizard, "VM verknüpfen"); - setDescription("Wählen Sie eine VM für diese Veranstaltung aus"); + super(wizard, I18n.PAGE_LAYOUT.getString("LectureImageList.WizardPage.title")); + setDescription(I18n.PAGE_LAYOUT.getString("LectureImageList.WizardPage.description")); GridManager grid = new GridManager(this, 1, false); ctlImageList = new ImageListViewer(FilterType.USABLE); diff --git a/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/LectureLocationSelectionPageLayout.java b/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/LectureLocationSelectionPageLayout.java index 929b55b8..bd86e86c 100644 --- a/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/LectureLocationSelectionPageLayout.java +++ b/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/LectureLocationSelectionPageLayout.java @@ -3,6 +3,7 @@ package org.openslx.dozmod.gui.wizard.layout; import org.apache.log4j.Logger; import org.openslx.dozmod.gui.control.LocationSelector; import org.openslx.dozmod.gui.helper.GridManager; +import org.openslx.dozmod.gui.helper.I18n; import org.openslx.dozmod.gui.wizard.Wizard; import org.openslx.dozmod.gui.wizard.WizardPage; @@ -14,8 +15,8 @@ public class LectureLocationSelectionPageLayout extends WizardPage { protected final LocationSelector ctlLocationSelector; public LectureLocationSelectionPageLayout(Wizard wizard) { - super(wizard, "Raumauswahl"); - setDescription("Bitte wählen Sie die Räume für diese Veranstaltung aus"); + super(wizard, I18n.PAGE_LAYOUT.getString("LectureLocationSelection.WizardPage.title")); + setDescription(I18n.PAGE_LAYOUT.getString("LectureLocationSelection.WizardPage.description")); ctlLocationSelector = new LocationSelector(); GridManager grid = new GridManager(this, 1); grid.add(ctlLocationSelector).fill(true, true).expand(true, true); diff --git a/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/LectureOptionsPageLayout.java b/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/LectureOptionsPageLayout.java index 86c68e44..28c04d81 100644 --- a/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/LectureOptionsPageLayout.java +++ b/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/LectureOptionsPageLayout.java @@ -5,13 +5,14 @@ import javax.swing.JCheckBox; import javax.swing.JLabel; import org.openslx.dozmod.gui.helper.GridManager; +import org.openslx.dozmod.gui.helper.I18n; import org.openslx.dozmod.gui.wizard.Wizard; import org.openslx.dozmod.gui.wizard.WizardPage; @SuppressWarnings("serial") public abstract class LectureOptionsPageLayout extends WizardPage { - protected static String title = "Zusätzliche Optionen"; + protected static String title = I18n.PAGE_LAYOUT.getString("LectureOptions.WizardPage.title"); protected final JCheckBox chkUsbEnabled; protected final JCheckBox chkInternetEnabled; @@ -24,23 +25,23 @@ public abstract class LectureOptionsPageLayout extends WizardPage { */ public LectureOptionsPageLayout(Wizard wizard) { super(wizard, title); - setDescription("Bitte wählen Sie aus folgenden Optionen aus:"); + setDescription(I18n.PAGE_LAYOUT.getString("LectureOptions.WizardPage.description")); GridManager grid = new GridManager(this, 2); // first column for labels hopefully clearing up some of the mess... // first category for general options - JLabel lblGeneral = new JLabel("Allgemeines"); + JLabel lblGeneral = new JLabel(I18n.PAGE_LAYOUT.getString("LectureOptions.Label.general.text")); grid.add(lblGeneral); - chkAutoUpdate = new JCheckBox("Immer auf aktuellste VM-Version updaten", true); + chkAutoUpdate = new JCheckBox(I18n.PAGE_LAYOUT.getString("LectureOptions.CheckBox.autoUpdate.text"), true); grid.add(chkAutoUpdate); grid.nextRow(); - chkIsActive = new JCheckBox("Veranstaltung ist aktiv", true); + chkIsActive = new JCheckBox(I18n.PAGE_LAYOUT.getString("LectureOptions.CheckBox.isActive.text"), true); grid.skip(); grid.add(chkIsActive); grid.nextRow(); - chkIsExam = new JCheckBox("Veranstaltung ist eine Prüfung", false); + chkIsExam = new JCheckBox(I18n.PAGE_LAYOUT.getString("LectureOptions.CheckBox.isExam.text"), false); grid.skip(); grid.add(chkIsExam); grid.nextRow(); @@ -48,15 +49,16 @@ public abstract class LectureOptionsPageLayout extends WizardPage { grid.add(Box.createVerticalStrut(10), 2); grid.nextRow(); // second category for restrictions options - JLabel lblRestriction = new JLabel("Beschränkungen"); + JLabel lblRestriction = new JLabel(I18n.PAGE_LAYOUT.getString("LectureOptions.Label.restrictions.text")); grid.add(lblRestriction); - chkInternetEnabled = new JCheckBox("Netzwerk-/Internetzugriff zulassen", true); + chkInternetEnabled = new JCheckBox(I18n.PAGE_LAYOUT.getString("LectureOptions.CheckBox.internetEnabled.text"), + true); // TODO: Hint at exception editor in lecture details window, or include here... grid.add(chkInternetEnabled).fill(true, false).expand(true, false); grid.nextRow(); - chkUsbEnabled = new JCheckBox("Speichermedien zulassen", true); + chkUsbEnabled = new JCheckBox(I18n.PAGE_LAYOUT.getString("LectureOptions.CheckBox.USBEnabled.text"), true); grid.skip(); grid.add(chkUsbEnabled); grid.nextRow(); diff --git a/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/LectureRestrictionPageLayout.java b/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/LectureRestrictionPageLayout.java index 85c508ae..02e9d7b4 100644 --- a/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/LectureRestrictionPageLayout.java +++ b/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/layout/LectureRestrictionPageLayout.java @@ -1,5 +1,6 @@ package org.openslx.dozmod.gui.wizard.layout; +import org.openslx.dozmod.gui.helper.I18n; import org.openslx.dozmod.gui.wizard.Wizard; import org.openslx.dozmod.gui.wizard.WizardPage; @@ -7,7 +8,7 @@ import org.openslx.dozmod.gui.wizard.WizardPage; public class LectureRestrictionPageLayout extends WizardPage { public LectureRestrictionPageLayout(Wizard wizard) { - super(wizard, "Beschränkungen"); + super(wizard, I18n.PAGE_LAYOUT.getString("LectureRestriction.WizardPage.title")); } } diff --git a/dozentenmodul/src/main/properties/i18n/page_layout.properties b/dozentenmodul/src/main/properties/i18n/page_layout.properties new file mode 100644 index 00000000..d03c87e8 --- /dev/null +++ b/dozentenmodul/src/main/properties/i18n/page_layout.properties @@ -0,0 +1,80 @@ +# ImageCustomPermissionPageLayout +ImageCustomPermission.WizardPage.title=Berechtigungen festlegen +ImageCustomPermission.WizardPage.description=Legen Sie hier die gewünschten Berechtigungen fest. +ImageCustomPermission.Label.defaultPerm.text=Standardberechtigungen +ImageCustomPermission.Label.defaultDesc.text=<html><body style ='width:100%'> \ + Legen Sie hier die Berechtigungen für alle anderen (nicht in der Liste \ + angezeigten) Benutzer fest.</body></html> +ImageCustomPermission.CheckBox.permissionLink.text=Verlinken +ImageCustomPermission.CheckBox.permissionRead.text=Download +ImageCustomPermission.CheckBox.permissionEdit.text=Bearbeiten +ImageCustomPermission.CheckBox.permissionAdmin.text=Admin + +# ImageMetaDataPageLayout +ImageMetaData.WizardPage.title=Metadaten +ImageMetaData.WizardPage.description=Geben Sie bitte einen aussagekräftigen Namen für die neue VM ein. +ImageMetaData.Label.OS.text=Betriebssystem +ImageMetaData.Label.startCommand.text=Startbefehl +ImageMetaData.Label.description.text=Beschreibung +ImageMetaData.CheckBox.licenseRestricted.text=VM enthält lizenzpflichtige Software +ImageMetaData.CheckBox.isTemplate.text=Vorlage erstellen + +# ImageUploadPageLayout +ImageUpload.WizardPage.title=Neue VM anlegen +ImageUpload.WizardPage.description=Bitte wählen Sie eine Virtuelle Maschine zum Hochladen aus. +ImageUpload.Label.imageFile.text=Virtuelle Maschine +ImageUpload.Button.browseForImage.text=Durchsuchen +ImageUpload.Label.imageName.text=Name +ImageUpload.CheckBox.licenseRestricted.text=enthält lizenzpflichtige Software +ImageUpload.TextArea.info.title=Hinweis +ImageUpload.TextArea.info.text=Haben Sie noch keine eigene Virtuelle Maschine erstellt, \ + können Sie sich in der Übersicht eine Virtuelle Maschine als Vorlage herunterladen, \ + diese an Ihre Bedürfnisse anpassen und anschließend über diesen Assistenten hochladen.\ + \n\nWenn Sie die VM einer bestehenden Veranstaltung aktualisieren möchten, \ + öffnen Sie die Detailansicht der bestehenden VM und wählen Sie 'Neue VM-Version hochladen'. \ + Dadurch bleiben bestehende Berechtigungen, sowie Verknüpfungen zu Veranstaltungen erhalten. + +# ImageUploadSummaryPageLayout +ImageUploadSummary.WizardPage.title=Fertig! +ImageUploadSummary.WizardPage.description=Assistent abgeschlossen +ImageUploadSummary.CheckBox.createLecture.text=Veranstaltung zu dieser VM erstellen + +# LectureCreationPageLayout +LectureCreation.WizardPage.description=Geben Sie bitte einen aussagekräftigen Namen für die neue Veranstaltung ein. +LectureCreation.Label.name.text=Veranstaltungsname +LectureCreation.Label.description.text=Beschreibung +LectureCreation.Label.startTime.text=Startdatum +LectureCreation.Label.endTime.text=Enddatum +LectureCreation.Label.period.text=Dauer der Veranstaltung: + +# LectureCustomPermissionPageLayout +LectureCustomPermission.WizardPage.title=Berechtigungen festlegen +LectureCustomPermission.WizardPage.description=Legen Sie hier die gewünschten Berechtigungen fest. +LectureCustomPermission.Label.defaultPerm.text=Standardberechtigungen +LectureCustomPermission.Label.defaultDesc.text=<html><body style ='width:100%'> \ + Legen Sie hier die Berechtigungen für alle anderen (nicht in der Liste \ + angezeigten) Benutzer fest.</body></html> +LectureCustomPermission.CheckBox.permissionEdit.text=Bearbeiten +LectureCustomPermission.CheckBox.permissionAdmin.text=Admin + +# LectureImageListPageLayout +LectureImageList.WizardPage.title=VM verknüpfen +LectureImageList.WizardPage.description=Wählen Sie eine VM für diese Veranstaltung aus + +# LectureLocationSelection +LectureLocationSelection.WizardPage.title=Raumauswahl +LectureLocationSelection.WizardPage.description=Bitte wählen Sie die Räume für diese Veranstaltung aus + +# LectureOptionsPageLayout +LectureOptions.WizardPage.title=Zusätzliche Optionen +LectureOptions.WizardPage.description=Bitte wählen Sie aus folgenden Optionen aus: +LectureOptions.Label.general.text=Allgemeines +LectureOptions.CheckBox.autoUpdate.text=Immer auf aktuellste VM-Version updaten +LectureOptions.CheckBox.isActive.text=Veranstaltung ist aktiv +LectureOptions.CheckBox.isExam.text=Veranstaltung ist eine Prüfung +LectureOptions.Label.restrictions.text=Beschränkungen +LectureOptions.CheckBox.internetEnabled.text=Netzwerk-/Internetzugriff zulassen +LectureOptions.CheckBox.USBEnabled.text=Speichermedien zulassen + +# LectureRestrictionPageLayout +LectureRestriction.WizardPage.title=Beschränkungen
\ No newline at end of file diff --git a/dozentenmodul/src/main/properties/i18n/page_layout_en_US.properties b/dozentenmodul/src/main/properties/i18n/page_layout_en_US.properties new file mode 100644 index 00000000..21effaa1 --- /dev/null +++ b/dozentenmodul/src/main/properties/i18n/page_layout_en_US.properties @@ -0,0 +1,80 @@ +# ImageCustomPermissionPageLayout +ImageCustomPermission.WizardPage.title=Set permissions +ImageCustomPermission.WizardPage.description=Define the desired permissions here. +ImageCustomPermission.Label.defaultPerm.text=Default permissions +ImageCustomPermission.Label.defaultDesc.text=<html><body style ='width:100%'> \ + Set the permissions for all other users (not shown \ + in the list) here.</body></html> +ImageCustomPermission.CheckBox.permissionLink.text=Link +ImageCustomPermission.CheckBox.permissionRead.text=Download +ImageCustomPermission.CheckBox.permissionEdit.text=Edit +ImageCustomPermission.CheckBox.permissionAdmin.text=Admin + +# ImageMetaDataPageLayout +ImageMetaData.WizardPage.title=Metadata +ImageMetaData.WizardPage.description=Please enter a meaningful name for the new VM. +ImageMetaData.Label.OS.text=Operating system +ImageMetaData.Label.startCommand.text=Start command +ImageMetaData.Label.description.text=Description +ImageMetaData.CheckBox.licenseRestricted.text=VM contains software requiring a license +ImageMetaData.CheckBox.isTemplate.text=Create template + +# ImageUploadPageLayout +ImageUpload.WizardPage.title=Create new VM +ImageUpload.WizardPage.description=Please select a virtual machine to upload. +ImageUpload.Label.imageFile.text=Virtual Machine +ImageUpload.Button.browseForImage.text=Browse +ImageUpload.Label.imageName.text=Name +ImageUpload.CheckBox.licenseRestricted.text=contains software requiring a license. +ImageUpload.TextArea.info.title=Note +ImageUpload.TextArea.info.text=If you have not created your own virtual machine yet, \ + you can download a virtual machine as a template in the overview, \ + customize it to your needs and then upload it using this wizard.\ + \n\nIf you want to update the VM of an existing lecture, \ + open the detail view of the existing VM and select 'Upload new VM version'. \ + This ensures that existing permissions and links to lectures are retained. + +# ImageUploadSummaryPageLayout +ImageUploadSummary.WizardPage.title=Done! +ImageUploadSummary.WizardPage.description=Wizard completed +ImageUploadSummary.CheckBox.createLecture.text=Create a lecture for this VM + +# LectureCreationPageLayout +LectureCreation.WizardPage.description=Please enter a meaningful name for the new lecture. +LectureCreation.Label.name.text=Lecture name +LectureCreation.Label.description.text=Description +LectureCreation.Label.startTime.text=Start date +LectureCreation.Label.endTime.text=End date +LectureCreation.Label.period.text=Duration of the lecture: + +# LectureCustomPermissionPageLayout +LectureCustomPermission.WizardPage.title=Set permissions +LectureCustomPermission.WizardPage.description=Define the desired permissions here. +LectureCustomPermission.Label.defaultPerm.text=Default permissions +LectureCustomPermission.Label.defaultDesc.text=<html><body style ='width:100%'> \ + Set the permissions for all other users (not shown \ + in the list) here.</body></html> +LectureCustomPermission.CheckBox.permissionEdit.text=Edit +LectureCustomPermission.CheckBox.permissionAdmin.text=Admin + +# LectureImageListPageLayout +LectureImageList.WizardPage.title=Link VM +LectureImageList.WizardPage.description=Select a VM for this lecture + +# LectureLocationSelection +LectureLocationSelection.WizardPage.title=Room selection +LectureLocationSelection.WizardPage.description=Please select the rooms for this lecture + +# LectureOptionsPageLayout +LectureOptions.WizardPage.title=Additional options +LectureOptions.WizardPage.description=Please choose from the following options: +LectureOptions.Label.general.text=General +LectureOptions.CheckBox.autoUpdate.text=Always update to the latest VM version +LectureOptions.CheckBox.isActive.text=Lecture is active +LectureOptions.CheckBox.isExam.text=Lecture is an exam +LectureOptions.Label.restrictions.text=Restrictions +LectureOptions.CheckBox.internetEnabled.text=Allow network/internet access +LectureOptions.CheckBox.USBEnabled.text=Allow storage media + +# LectureRestrictionPageLayout +LectureRestriction.WizardPage.title=Restrictions
\ No newline at end of file |