X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=src%2Fjalview%2Fgui%2FSequenceFetcher.java;h=9c51409ae83802cf809f05913ec995ebb727e9b8;hb=f52f7b378972cc884b5d3e5cc250f89667f558f7;hp=e43f82c8455ea4cce88eeb48ed3b20b6a79cc1d5;hpb=6357db6c20614a666b7b446aeb3260c5379637eb;p=jalview.git diff --git a/src/jalview/gui/SequenceFetcher.java b/src/jalview/gui/SequenceFetcher.java index e43f82c..9c51409 100755 --- a/src/jalview/gui/SequenceFetcher.java +++ b/src/jalview/gui/SequenceFetcher.java @@ -1,18 +1,18 @@ /* * Jalview - A Sequence Alignment Editor and Viewer (Version 2.7) * Copyright (C) 2011 J Procter, AM Waterhouse, J Engelhardt, LM Lui, G Barton, M Clamp, S Searle - * + * * This file is part of Jalview. - * + * * Jalview is free software: you can redistribute it and/or - * modify it under the terms of the GNU General Public License + * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. - * - * Jalview is distributed in the hope that it will be useful, but - * WITHOUT ANY WARRANTY; without even the implied warranty - * of MERCHANTABILITY or FITNESS FOR A PARTICULAR + * + * Jalview is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty + * of MERCHANTABILITY or FITNESS FOR A PARTICULAR * PURPOSE. See the GNU General Public License for more details. - * + * * You should have received a copy of the GNU General Public License along with Jalview. If not, see . */ package jalview.gui; @@ -25,16 +25,11 @@ import java.awt.event.*; import javax.swing.*; import javax.swing.tree.DefaultMutableTreeNode; -import javax.swing.tree.MutableTreeNode; -import javax.swing.tree.TreeModel; - import jalview.datamodel.*; import jalview.io.*; import jalview.util.DBRefUtils; import jalview.ws.dbsources.das.api.DasSourceRegistryI; import jalview.ws.seqfetcher.DbSourceProxy; -import jalview.ws.seqfetcher.DbSourceProxyImpl; - import java.awt.BorderLayout; public class SequenceFetcher extends JPanel implements Runnable @@ -63,7 +58,7 @@ public class SequenceFetcher extends JPanel implements Runnable /** * Blocking method that initialises and returns the shared instance of the * SequenceFetcher client - * + * * @param guiWindow * - where the initialisation delay message should be shown * @return the singleton instance of the sequence fetcher client @@ -142,6 +137,7 @@ public class SequenceFetcher extends JPanel implements Runnable Thread sf = new Thread(new Runnable() { + @Override public void run() { if (getSequenceFetcherSingleton(guiWindow) != null) @@ -152,6 +148,7 @@ public class SequenceFetcher extends JPanel implements Runnable { javax.swing.SwingUtilities.invokeLater(new Runnable() { + @Override public void run() { JOptionPane @@ -182,7 +179,7 @@ public class SequenceFetcher extends JPanel implements Runnable /** * called by thread spawned by constructor - * + * * @param guiWindow */ private void initGui(IProgressIndicator guiWindow) @@ -236,6 +233,7 @@ public class SequenceFetcher extends JPanel implements Runnable ok.setText("OK"); ok.addActionListener(new ActionListener() { + @Override public void actionPerformed(ActionEvent e) { ok_actionPerformed(); @@ -244,6 +242,7 @@ public class SequenceFetcher extends JPanel implements Runnable clear.setText("Clear"); clear.addActionListener(new ActionListener() { + @Override public void actionPerformed(ActionEvent e) { clear_actionPerformed(); @@ -253,6 +252,7 @@ public class SequenceFetcher extends JPanel implements Runnable example.setText("Example"); example.addActionListener(new ActionListener() { + @Override public void actionPerformed(ActionEvent e) { example_actionPerformed(); @@ -261,6 +261,7 @@ public class SequenceFetcher extends JPanel implements Runnable close.setText("Close"); close.addActionListener(new ActionListener() { + @Override public void actionPerformed(ActionEvent e) { close_actionPerformed(e); @@ -270,6 +271,7 @@ public class SequenceFetcher extends JPanel implements Runnable textArea.setLineWrap(true); textArea.addKeyListener(new KeyAdapter() { + @Override public void keyPressed(KeyEvent e) { if (e.getKeyCode() == KeyEvent.VK_ENTER) @@ -289,6 +291,7 @@ public class SequenceFetcher extends JPanel implements Runnable database.addActionListener(new ActionListener() { + @Override public void actionPerformed(ActionEvent e) { try @@ -416,6 +419,7 @@ public class SequenceFetcher extends JPanel implements Runnable close.setEnabled(true); } + @Override public void run() { String error = ""; @@ -721,7 +725,7 @@ public class SequenceFetcher extends JPanel implements Runnable } /** - * + * * @return a standard title for any results retrieved using the currently * selected source and settings */ @@ -809,6 +813,7 @@ public class SequenceFetcher extends JPanel implements Runnable resetDialog(); javax.swing.SwingUtilities.invokeLater(new Runnable() { + @Override public void run() { JOptionPane.showInternalMessageDialog(Desktop.desktop, error,