From f12647d7d95d675fefbf1e488d055cad54783235 Mon Sep 17 00:00:00 2001 From: Michael Wilson Date: Mon, 24 Nov 2014 17:22:43 +0100 Subject: • All Fonts checked and corrected --- .../main/java/gui/image/FTPEditDownloader_GUI.java | 56 +++++++++++++--------- 1 file changed, 34 insertions(+), 22 deletions(-) (limited to 'dozentenmodul/src/main/java/gui/image/FTPEditDownloader_GUI.java') diff --git a/dozentenmodul/src/main/java/gui/image/FTPEditDownloader_GUI.java b/dozentenmodul/src/main/java/gui/image/FTPEditDownloader_GUI.java index a3e4c6cf..a9bd4880 100644 --- a/dozentenmodul/src/main/java/gui/image/FTPEditDownloader_GUI.java +++ b/dozentenmodul/src/main/java/gui/image/FTPEditDownloader_GUI.java @@ -98,20 +98,20 @@ public class FTPEditDownloader_GUI extends JFrame implements private boolean isCurrentlyLoading = false; // currently up or downloading // file private boolean isAborted = false; // down- or upload was manually aborted - private static final String HELP_MESSAGE = "
" + - "Hier können Sie Images herunterladen.
" + - "Klicken Sie anschließend auf \"Zurück\", um zu Ihrer vorherigen Auswahl zurückzugelangen.
" + - "
"; + private static final String HELP_MESSAGE = "
" + + "Hier können Sie Images herunterladen.
" + + "Klicken Sie anschließend auf \"Zurück\", um zu Ihrer vorherigen Auswahl zurückzugelangen.
" + + "
"; /** * Create the frame. */ public FTPEditDownloader_GUI(Component formerGUI) { - + try { client.setTokenForSession(SessionData.session.getAuthToken()); } catch (TException e1) { - // TODO Auto-generated catch block + e1.printStackTrace(); } @@ -136,7 +136,7 @@ public class FTPEditDownloader_GUI extends JFrame implements client.DeleteFtpUser(user.userName); con.closeThriftConnection(); } catch (TException e1) { - // TODO Auto-generated catch block + e1.printStackTrace(); } task.cancel(true); @@ -153,7 +153,7 @@ public class FTPEditDownloader_GUI extends JFrame implements UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName()); } catch (ClassNotFoundException | InstantiationException | IllegalAccessException | UnsupportedLookAndFeelException e) { - // TODO Auto-generated catch block + e.printStackTrace(); } @@ -304,6 +304,15 @@ public class FTPEditDownloader_GUI extends JFrame implements label_1.setForeground(Color.BLUE); label_1.setBounds(20, 92, 61, 20); contentPanel.add(label_1); + label_1.addMouseListener(new MouseAdapter() { + @Override + public void mouseClicked(MouseEvent arg0) { + // oeffnet das Hauptmenue + dispose(); + MainMenue_GUI main = new MainMenue_GUI(c); + main.setVisible(true); + } + }); JLabel label_2 = new JLabel(">"); label_2.setBounds(80, 95, 14, 14); @@ -338,8 +347,7 @@ public class FTPEditDownloader_GUI extends JFrame implements lblSchritt_3.setBounds(20, 423, 57, 14); contentPanel.add(lblSchritt_3); - JLabel lblKlickenSieAuf = new JLabel( - "Klicken Sie auf \"Zurück\"."); + JLabel lblKlickenSieAuf = new JLabel("Klicken Sie auf \"Zurück\"."); lblKlickenSieAuf.setBounds(102, 423, 241, 14); contentPanel.add(lblKlickenSieAuf); @@ -360,7 +368,7 @@ public class FTPEditDownloader_GUI extends JFrame implements windows = new URI(Links.getFAQ()); open.openWebpage(windows); } catch (URISyntaxException e) { - // TODO Auto-generated catch block + e.printStackTrace(); } } @@ -378,7 +386,7 @@ public class FTPEditDownloader_GUI extends JFrame implements windows = new URI(Links.getOTRS()); open.openWebpage(windows); } catch (URISyntaxException e) { - // TODO Auto-generated catch block + e.printStackTrace(); } } @@ -408,7 +416,7 @@ public class FTPEditDownloader_GUI extends JFrame implements anleitung = new URI(Links.getAnleitungVMDK()); open.openWebpage(anleitung); } catch (URISyntaxException e) { - // TODO Auto-generated catch block + e.printStackTrace(); } } @@ -423,7 +431,7 @@ public class FTPEditDownloader_GUI extends JFrame implements client.DeleteFtpUser(user.userName); LOGGER.info("FTP user deleted."); } catch (TException e1) { - // TODO Auto-generated catch block + e1.printStackTrace(); } task.cancel(true); @@ -461,12 +469,13 @@ public class FTPEditDownloader_GUI extends JFrame implements try { client.DeleteFtpUser(user.userName); } catch (TException e1) { - // TODO Auto-generated catch block + e1.printStackTrace(); } // go back one page - SearchEditImage_GUI se = new SearchEditImage_GUI(c); + SearchEditImage_GUI se = new SearchEditImage_GUI( + c); se.setVisible(true); dispose(); }// end choice @@ -496,16 +505,18 @@ public class FTPEditDownloader_GUI extends JFrame implements } } setVisible(true); - + JMenu mnNewMenu_Info = new JMenu("Info"); mnNewMenu_Info.addMouseListener(new MouseAdapter() { @Override public void mouseClicked(MouseEvent arg0) { - JOptionPane.showMessageDialog(c, HELP_MESSAGE, "Hilfe zu dieser Oberfläche", JOptionPane.INFORMATION_MESSAGE); + JOptionPane.showMessageDialog(c, HELP_MESSAGE, + "Hilfe zu dieser Oberfläche", + JOptionPane.INFORMATION_MESSAGE); } }); menuBar.add(mnNewMenu_Info); - + c = this; } @@ -526,7 +537,7 @@ public class FTPEditDownloader_GUI extends JFrame implements Image.image.getVersion()); } catch (TException e) { - // TODO Auto-generated catch block + e.printStackTrace(); JOptionPane.showMessageDialog(c, e.getCause() + "\n" + e.getStackTrace(), "Debug-Message", @@ -559,9 +570,10 @@ public class FTPEditDownloader_GUI extends JFrame implements } // Button zum Fertigstellen freischalten, wenn 100% erreicht sind - if (isCurrentlyLoading() == false || progressBar.getPercentComplete() == 1.0) { + if (isCurrentlyLoading() == false + || progressBar.getPercentComplete() == 1.0) { // no download - //LOGGER.info("finished downloading file"); + // LOGGER.info("finished downloading file"); btnDownloadStoppen.setEnabled(false); } else { // currently uploading, don't let user interact -- cgit v1.2.3-55-g7522