diff options
| author | Michael Wilson | 2014-09-01 17:10:23 +0200 |
|---|---|---|
| committer | Michael Wilson | 2014-09-01 17:10:23 +0200 |
| commit | 8682518876d11d103016f0a9bc65250b3bfa7b81 (patch) | |
| tree | 5f1fb5646258320ec2efb9ecfc6d807af41348bb | |
| parent | Detailfelder sind nicht mehr editable (diff) | |
| download | tutor-module-8682518876d11d103016f0a9bc65250b3bfa7b81.tar.gz tutor-module-8682518876d11d103016f0a9bc65250b3bfa7b81.tar.xz tutor-module-8682518876d11d103016f0a9bc65250b3bfa7b81.zip | |
(Quick and Dirty) Pfad des letzten Images wir nun nur noch unter Windows-Maschinen gespeichert, nicht unter Linux -> Verhindert Abstürze
| -rw-r--r-- | Dozentenmodul/bin/gui/image/FTPCreateUploader_GUI.class | bin | 14663 -> 14667 bytes | |||
| -rw-r--r-- | Dozentenmodul/bin/gui/image/FTPEditUploader_GUI.class | bin | 14286 -> 14290 bytes | |||
| -rw-r--r-- | Dozentenmodul/src/gui/image/FTPCreateUploader_GUI.java | 30 | ||||
| -rw-r--r-- | Dozentenmodul/src/gui/image/FTPEditUploader_GUI.java | 38 | ||||
| -rw-r--r-- | Dozentenmodul/src/gui/intro/About_GUI.java | 4 | ||||
| -rw-r--r-- | Dozentenmodulserver/src/server/startServer.java | 4 |
6 files changed, 46 insertions, 30 deletions
diff --git a/Dozentenmodul/bin/gui/image/FTPCreateUploader_GUI.class b/Dozentenmodul/bin/gui/image/FTPCreateUploader_GUI.class Binary files differindex 230c7fb1..8bd011a2 100644 --- a/Dozentenmodul/bin/gui/image/FTPCreateUploader_GUI.class +++ b/Dozentenmodul/bin/gui/image/FTPCreateUploader_GUI.class diff --git a/Dozentenmodul/bin/gui/image/FTPEditUploader_GUI.class b/Dozentenmodul/bin/gui/image/FTPEditUploader_GUI.class Binary files differindex 43defd4a..38dcb46d 100644 --- a/Dozentenmodul/bin/gui/image/FTPEditUploader_GUI.class +++ b/Dozentenmodul/bin/gui/image/FTPEditUploader_GUI.class diff --git a/Dozentenmodul/src/gui/image/FTPCreateUploader_GUI.java b/Dozentenmodul/src/gui/image/FTPCreateUploader_GUI.java index 9e5b7db8..a9461bb4 100644 --- a/Dozentenmodul/src/gui/image/FTPCreateUploader_GUI.java +++ b/Dozentenmodul/src/gui/image/FTPCreateUploader_GUI.java @@ -372,14 +372,21 @@ public class FTPCreateUploader_GUI extends JFrame implements "C:\\Users\\" + System.getProperty("user.name") + "\\AppData\\Roaming\\bwLehrpoolSuite\\config.ini")); - ini.put("main", - "Letzter Uploadpfad", - lblPath.getText() - .substring( - 0, - lblPath.getText() - .lastIndexOf("\\"))); - ini.store(); + + // check if path has content, then write to file + if (lblPath.getText().contains("\\") == true) { + System.out.println("Hole Infos aus Label: " + + lblPath.getText()); + ini.put("main", + "Letzter Uploadpfad", + lblPath.getText().substring( + 0, + lblPath.getText().lastIndexOf( + "\\"))); + ini.store(); + } else { + System.out.println("Mache nix"); + }// end if } catch (InvalidFileFormatException e2) { // TODO Auto-generated catch block e2.printStackTrace(); @@ -553,7 +560,7 @@ public class FTPCreateUploader_GUI extends JFrame implements } // Fertigstellen erlauben wenn upload abgeschlossen - if (isCurrentlyLoading() == false) { + if (isCurrentlyLoading() == false) { // isCurrentlyLoading(); finishButton.setEnabled(true); } else { @@ -639,12 +646,13 @@ public class FTPCreateUploader_GUI extends JFrame implements public boolean isCurrentlyLoading() { isCurrentlyLoading = false; - if (labelverbleibend.getText().equals("0 MB") || labelverbleibend.getText().equals("0")) { + if (labelverbleibend.getText().equals("0 MB") + || labelverbleibend.getText().equals("0")) { isCurrentlyLoading = false; } else { isCurrentlyLoading = true; } - + return isCurrentlyLoading; }// end isCurrentlyLoading() diff --git a/Dozentenmodul/src/gui/image/FTPEditUploader_GUI.java b/Dozentenmodul/src/gui/image/FTPEditUploader_GUI.java index 4954f81d..5d679ea5 100644 --- a/Dozentenmodul/src/gui/image/FTPEditUploader_GUI.java +++ b/Dozentenmodul/src/gui/image/FTPEditUploader_GUI.java @@ -80,7 +80,7 @@ public class FTPEditUploader_GUI extends JFrame implements long filesize; double speed; long bytesread; - boolean fileupload=false; + boolean fileupload = false; boolean taskrun = false; int progress = 0; ThriftConnection con = new ThriftConnection(); @@ -365,14 +365,21 @@ public class FTPEditUploader_GUI extends JFrame implements "C:\\Users\\" + System.getProperty("user.name") + "\\AppData\\Roaming\\bwLehrpoolSuite\\config.ini")); - ini.put("main", - "Letzter Uploadpfad", - lblPath.getText() - .substring( - 0, - lblPath.getText() - .lastIndexOf("\\"))); - ini.store(); + + // check if path has content, then write to file + if (lblPath.getText().contains("\\") == true) { + System.out.println("Hole Infos aus Label: " + + lblPath.getText()); + ini.put("main", + "Letzter Uploadpfad", + lblPath.getText().substring( + 0, + lblPath.getText().lastIndexOf( + "\\"))); + ini.store(); + } else { + System.out.println("Mache nix"); + }// end if } catch (InvalidFileFormatException e2) { // TODO Auto-generated catch block e2.printStackTrace(); @@ -511,7 +518,7 @@ public class FTPEditUploader_GUI extends JFrame implements } private void buttonUploadActionPerformed(ActionEvent event) { - fileupload=true; + fileupload = true; progressBar.setValue(0); btnUploadStarten.setEnabled(false); // verhindert einen weiteren klick btnUploadStarten.setText("Bitte warten"); @@ -611,10 +618,10 @@ public class FTPEditUploader_GUI extends JFrame implements Image.image.getVersion(), Image.image.isVorlage(), Image.image.getFilesize(), Image.image.getShareMode(), Image.image.getOS()); - if(fileupload==true){ + if (fileupload == true) { client.startFileCopy(Image.image.getNewName()); } - + } else { client.updateImageData(Image.image.getImagename(), @@ -625,8 +632,8 @@ public class FTPEditUploader_GUI extends JFrame implements Image.image.getImageId(), Image.image.getVersion(), Image.image.isVorlage(), Image.image.getFilesize(), Image.image.getShareMode(), Image.image.getOS()); - - if(fileupload==true){ + + if (fileupload == true) { client.startFileCopy(Image.image.getNewName()); } } @@ -645,7 +652,8 @@ public class FTPEditUploader_GUI extends JFrame implements public boolean isCurrentlyLoading() { isCurrentlyLoading = false; - if (labelverbleibend.getText().equals("0 MB") || labelverbleibend.getText().equals("0")) { + if (labelverbleibend.getText().equals("0 MB") + || labelverbleibend.getText().equals("0")) { isCurrentlyLoading = false; } else { isCurrentlyLoading = true; diff --git a/Dozentenmodul/src/gui/intro/About_GUI.java b/Dozentenmodul/src/gui/intro/About_GUI.java index 19d4d2eb..6209a87b 100644 --- a/Dozentenmodul/src/gui/intro/About_GUI.java +++ b/Dozentenmodul/src/gui/intro/About_GUI.java @@ -23,8 +23,8 @@ public class About_GUI extends JFrame { private JPanel contentPane; private JTextPane txtpnVersionVBuilddate; - private String buildDate ="29.08.2014"; - private String version="1.03"; + private String buildDate ="01.09.2014"; + private String version="1.04"; /** * Create the frame. diff --git a/Dozentenmodulserver/src/server/startServer.java b/Dozentenmodulserver/src/server/startServer.java index 58a3543d..1ac3435f 100644 --- a/Dozentenmodulserver/src/server/startServer.java +++ b/Dozentenmodulserver/src/server/startServer.java @@ -25,8 +25,8 @@ public class startServer { public static void main(String[] args) { - String version = "Version: 1.01"; - String buildDate = "Build Date: 26.08.2014"; + String version = "Version: 1.02"; + String buildDate = "Build Date: 01.09.2014"; //get going and show basic information in logfile BasicConfigurator.configure(); |
