diff options
| author | Michael Wilson | 2014-11-20 19:10:10 +0100 |
|---|---|---|
| committer | Michael Wilson | 2014-11-20 19:10:10 +0100 |
| commit | c067221e05dcf17d6b86772b1135640d14cfcd28 (patch) | |
| tree | 42a1dcac2c293fc5a8e2eefb85289ad6ff70a065 /dozentenmodul/src/main/java/gui/lecture/CreateLectureAllgemein_GUI.java | |
| parent | Lists now have the functionality to show complete lists, when role=="Admin" (diff) | |
| parent | • replaced getText() with getText().trim() (diff) | |
| download | tutor-module-c067221e05dcf17d6b86772b1135640d14cfcd28.tar.gz tutor-module-c067221e05dcf17d6b86772b1135640d14cfcd28.tar.xz tutor-module-c067221e05dcf17d6b86772b1135640d14cfcd28.zip | |
Merge branch 'master' of ssh://git.openslx.org/openslx-ng/tutor-module
Diffstat (limited to 'dozentenmodul/src/main/java/gui/lecture/CreateLectureAllgemein_GUI.java')
| -rw-r--r-- | dozentenmodul/src/main/java/gui/lecture/CreateLectureAllgemein_GUI.java | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/dozentenmodul/src/main/java/gui/lecture/CreateLectureAllgemein_GUI.java b/dozentenmodul/src/main/java/gui/lecture/CreateLectureAllgemein_GUI.java index 3969eb0d..9f2c56d1 100644 --- a/dozentenmodul/src/main/java/gui/lecture/CreateLectureAllgemein_GUI.java +++ b/dozentenmodul/src/main/java/gui/lecture/CreateLectureAllgemein_GUI.java @@ -384,8 +384,8 @@ public class CreateLectureAllgemein_GUI extends JFrame { } Lecture.lecture.setName(txtFldVeranstaltungsname - .getText()); - Lecture.lecture.setDesc(description.getText()); + .getText().trim()); + Lecture.lecture.setDesc(description.getText().trim()); Lecture.lecture.setEnddate(dateChooserend.getDate()); Lecture.lecture.setStartdate(dateChooserstart.getDate()); @@ -434,8 +434,8 @@ public class CreateLectureAllgemein_GUI extends JFrame { isDateMaxLifeTimeCorrect = true; } // Pruefen ob alles eingegeben wurde - if (txtFldVeranstaltungsname.getText().isEmpty() == true - || description.getText().isEmpty() == true) { + if (txtFldVeranstaltungsname.getText().trim().isEmpty() == true + || description.getText().trim().isEmpty() == true) { // mind 1 Textfeld ist leer isAllInformationReady = false; JOptionPane @@ -463,8 +463,8 @@ public class CreateLectureAllgemein_GUI extends JFrame { && descriptionLenghtOK() == true) { // everything is ok, proceed Lecture.lecture.setName(txtFldVeranstaltungsname - .getText()); - Lecture.lecture.setDesc(description.getText()); + .getText().trim()); + Lecture.lecture.setDesc(description.getText().trim()); Lecture.lecture.setEnddate(dateChooserend.getDate()); Lecture.lecture.setStartdate(dateChooserstart .getDate()); @@ -567,11 +567,11 @@ public class CreateLectureAllgemein_GUI extends JFrame { descriptionLengthOK = false; // max length is 254 chars - if (description.getText().length() >= MAX_DESCRIPTION_LENGTH) { + if (description.getText().trim().length() >= MAX_DESCRIPTION_LENGTH) { descriptionLengthOK = false; JOptionPane.showMessageDialog(c, "Die Beschreibung darf max 254 Zeichen enthalten. Aktuell enthält sie " - + description.getText().length() + ".", + + description.getText().trim().length() + ".", "Beschreibung zu umfangreich", JOptionPane.INFORMATION_MESSAGE); } else { |
