X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=src%2Fjalview%2Fgui%2FAlignFrame.java;h=8ae4601ba56279fff7430aebfeb52e4d05b7bf80;hb=4df015be529a2e1b12c6b82b061798e186cc154b;hp=7011d4dca3263be869b7b0322186803d46a45d23;hpb=d43fac59026bd44f9d6125f331263384c693fedf;p=jalview.git diff --git a/src/jalview/gui/AlignFrame.java b/src/jalview/gui/AlignFrame.java index 7011d4d..8ae4601 100644 --- a/src/jalview/gui/AlignFrame.java +++ b/src/jalview/gui/AlignFrame.java @@ -20,6 +20,71 @@ */ package jalview.gui; +import java.util.Locale; + +import java.io.IOException; +import java.util.HashSet; +import java.util.Set; + +import javax.swing.JFileChooser; +import javax.swing.JOptionPane; +import java.awt.BorderLayout; +import java.awt.Color; +import java.awt.Component; +import java.awt.Dimension; +import java.awt.Rectangle; +import java.awt.Toolkit; +import java.awt.datatransfer.Clipboard; +import java.awt.datatransfer.DataFlavor; +import java.awt.datatransfer.StringSelection; +import java.awt.datatransfer.Transferable; +import java.awt.dnd.DnDConstants; +import java.awt.dnd.DropTargetDragEvent; +import java.awt.dnd.DropTargetDropEvent; +import java.awt.dnd.DropTargetEvent; +import java.awt.dnd.DropTargetListener; +import java.awt.event.ActionEvent; +import java.awt.event.ActionListener; +import java.awt.event.FocusAdapter; +import java.awt.event.FocusEvent; +import java.awt.event.ItemEvent; +import java.awt.event.ItemListener; +import java.awt.event.KeyAdapter; +import java.awt.event.KeyEvent; +import java.awt.event.MouseEvent; +import java.awt.print.PageFormat; +import java.awt.print.PrinterJob; +import java.beans.PropertyChangeEvent; +import java.beans.PropertyChangeListener; +import java.io.File; +import java.io.FileWriter; +import java.io.PrintWriter; +import java.net.URL; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Collection; +import java.util.Deque; +import java.util.Enumeration; +import java.util.Hashtable; +import java.util.List; +import java.util.Vector; + +import javax.swing.ButtonGroup; +import javax.swing.JCheckBoxMenuItem; +import javax.swing.JComponent; +import javax.swing.JEditorPane; +import javax.swing.JInternalFrame; +import javax.swing.JLabel; +import javax.swing.JLayeredPane; +import javax.swing.JMenu; +import javax.swing.JMenuItem; +import javax.swing.JPanel; +import javax.swing.JScrollPane; +import javax.swing.SwingUtilities; +import javax.swing.event.InternalFrameAdapter; +import javax.swing.event.InternalFrameEvent; + +import ext.vamsas.ServiceHandle; import jalview.analysis.AlignmentSorter; import jalview.analysis.AlignmentUtils; import jalview.analysis.CrossRef; @@ -38,6 +103,7 @@ import jalview.api.SplitContainerI; import jalview.api.ViewStyleI; import jalview.api.analysis.SimilarityParamsI; import jalview.bin.Cache; +import jalview.bin.Console; import jalview.bin.Jalview; import jalview.commands.CommandI; import jalview.commands.EditCommand; @@ -98,6 +164,7 @@ import jalview.schemes.ColourSchemeI; import jalview.schemes.ColourSchemes; import jalview.schemes.ResidueColourScheme; import jalview.schemes.TCoffeeColourScheme; +import jalview.util.HttpUtils; import jalview.util.ImageMaker.TYPE; import jalview.util.MessageManager; import jalview.util.Platform; @@ -116,6 +183,7 @@ import jalview.ws.params.ParamDatastoreI; import jalview.ws.params.WsParamSetI; import jalview.ws.seqfetcher.DbSourceProxy; import jalview.ws2.client.api.WebServiceDiscovererI; +import jalview.ws2.client.ebi.JobDispatcherWSDiscoverer; import jalview.ws2.client.slivka.SlivkaWSDiscoverer; import jalview.ws2.gui.WebServicesMenuManager; @@ -197,7 +265,6 @@ public class AlignFrame extends GAlignFrame { public static int frameCount; - public static final int DEFAULT_WIDTH = 700; public static final int DEFAULT_HEIGHT = 500; @@ -231,7 +298,6 @@ public class AlignFrame extends GAlignFrame private int id; private DataSourceType protocol ; - /** * Creates a new AlignFrame object with specific width and height. * @@ -326,9 +392,7 @@ public class AlignFrame extends GAlignFrame public AlignFrame(AlignmentI al, HiddenColumns hiddenColumns, int width, int height, String sequenceSetId, String viewId) { - id = (++frameCount); - setSize(width, height); if (al.getDataset() == null) @@ -385,7 +449,6 @@ public class AlignFrame extends GAlignFrame * initalise the alignframe from the underlying viewport data and the * configurations */ - void init() { boolean newPanel = (alignPanel == null); @@ -408,7 +471,6 @@ public class AlignFrame extends GAlignFrame alignPanel = new AlignmentPanel(this, viewport); } addAlignmentPanel(alignPanel, newPanel); - // setBackground(Color.white); // BH 2019 if (!Jalview.isHeadlessMode()) @@ -431,7 +493,7 @@ public class AlignFrame extends GAlignFrame // modifyPID.setEnabled(false); } - String sortby = jalview.bin.Cache.getDefault(Preferences.SORT_ALIGNMENT, + String sortby = Cache.getDefault(Preferences.SORT_ALIGNMENT, "No sort"); if (sortby.equals("Id")) @@ -476,14 +538,14 @@ public class AlignFrame extends GAlignFrame wrapMenuItem_actionPerformed(null); } - if (jalview.bin.Cache.getDefault(Preferences.SHOW_OVERVIEW, false)) + if (Cache.getDefault(Preferences.SHOW_OVERVIEW, false)) { this.overviewMenuItem_actionPerformed(null); } addKeyListener(); - final List selviews = new ArrayList<>(); + final List selviews = new ArrayList<>(); final List origview = new ArrayList<>(); final String menuLabel = MessageManager .getString("label.copy_format_from"); @@ -551,16 +613,15 @@ public class AlignFrame extends GAlignFrame } } }); - if (Cache.getDefault("VERSION", "DEVELOPMENT").toLowerCase() + if (Cache.getDefault("VERSION", "DEVELOPMENT").toLowerCase(Locale.ROOT) .indexOf("devel") > -1 - || Cache.getDefault("VERSION", "DEVELOPMENT").toLowerCase() - .indexOf("test") > -1) + || Cache.getDefault("VERSION", "DEVELOPMENT") + .toLowerCase(Locale.ROOT).indexOf("test") > -1) { formatMenu.add(vsel); } addFocusListener(new FocusAdapter() { - @Override public void focusGained(FocusEvent e) { @@ -579,7 +640,6 @@ public class AlignFrame extends GAlignFrame * @param format * format of file */ - @Deprecated public void setFileName(String file, FileFormatI format) { @@ -610,7 +670,6 @@ public class AlignFrame extends GAlignFrame * * @param file */ - public void setFileObject(File file) { this.fileObject = file; @@ -620,12 +679,10 @@ public class AlignFrame extends GAlignFrame * Add a KeyListener with handlers for various KeyPressed and KeyReleased * events */ - void addKeyListener() { addKeyListener(new KeyAdapter() { - @Override public void keyPressed(KeyEvent evt) { @@ -655,7 +712,7 @@ public class AlignFrame extends GAlignFrame } if (viewport.cursorMode) { - alignPanel.getSeqPanel().moveCursor(0, 1); + alignPanel.getSeqPanel().moveCursor(0, 1, evt.isShiftDown()); } break; @@ -666,7 +723,7 @@ public class AlignFrame extends GAlignFrame } if (viewport.cursorMode) { - alignPanel.getSeqPanel().moveCursor(0, -1); + alignPanel.getSeqPanel().moveCursor(0, -1, evt.isShiftDown()); } break; @@ -679,7 +736,7 @@ public class AlignFrame extends GAlignFrame } else { - alignPanel.getSeqPanel().moveCursor(-1, 0); + alignPanel.getSeqPanel().moveCursor(-1, 0, evt.isShiftDown()); } break; @@ -691,7 +748,7 @@ public class AlignFrame extends GAlignFrame } else { - alignPanel.getSeqPanel().moveCursor(1, 0); + alignPanel.getSeqPanel().moveCursor(1, 0, evt.isShiftDown()); } break; @@ -921,6 +978,15 @@ public class AlignFrame extends GAlignFrame menu.setNoServices(services.isEmpty() && discoverer.isDone()); }; + private WebServiceDiscovererI.ServicesChangeListener ebiServiceChangeListener = + (discoverer, services) -> { + // run when ebi services change + var menu = AlignFrame.this.ebiMenu; + menu.setServices(discoverer); + menu.setInProgress(discoverer.isRunning()); + menu.setNoServices(services.isEmpty() && discoverer.isDone()); + }; + /* Set up intrinsic listeners for dynamically generated GUI bits. */ private void addServiceListeners() { @@ -929,6 +995,10 @@ public class AlignFrame extends GAlignFrame WebServiceDiscovererI discoverer = SlivkaWSDiscoverer.getInstance(); discoverer.addServicesChangeListener(slivkaServiceChangeListener); } + if (Cache.getDefault("SHOW_EBI_SERVICES", true)) + { + JobDispatcherWSDiscoverer.getInstance().addServicesChangeListener(ebiServiceChangeListener); + } if (Cache.getDefault("SHOW_JWS2_SERVICES", true)) { WSDiscovererI discoverer = Jws2Discoverer.getInstance(); @@ -957,7 +1027,6 @@ public class AlignFrame extends GAlignFrame * Configure menu items that vary according to whether the alignment is * nucleotide or protein */ - public void setGUINucleotide() { AlignmentI al = getViewport().getAlignment(); @@ -982,7 +1051,6 @@ public class AlignFrame extends GAlignFrame * operation that affects the data in the current view (selection changed, * etc) to update the menus to reflect the new state. */ - @Override public void setMenusForViewport() { @@ -996,7 +1064,6 @@ public class AlignFrame extends GAlignFrame * @param av * AlignViewport */ - public void setMenusFromViewport(AlignViewport av) { padGapsMenuitem.setSelected(av.isPadGaps()); @@ -1052,7 +1119,6 @@ public class AlignFrame extends GAlignFrame * * @param b */ - public void setGroovyEnabled(boolean b) { runGroovy.setEnabled(b); @@ -1065,7 +1131,6 @@ public class AlignFrame extends GAlignFrame * * @see jalview.gui.IProgressIndicator#setProgressBar(java.lang.String, long) */ - @Override public void setProgressBar(String message, long id) { @@ -1095,7 +1160,6 @@ public class AlignFrame extends GAlignFrame * * @return true if any progress bars are still active */ - @Override public boolean operationInProgress() { @@ -1107,7 +1171,6 @@ public class AlignFrame extends GAlignFrame * will cause the status bar to be hidden, with possibly undesirable flicker * of the screen layout. */ - @Override public void setStatus(String text) { @@ -1117,10 +1180,9 @@ public class AlignFrame extends GAlignFrame /* * Added so Castor Mapping file can obtain Jalview Version */ - public String getVersion() { - return jalview.bin.Cache.getProperty("VERSION"); + return Cache.getProperty("VERSION"); } public FeatureRenderer getFeatureRenderer() @@ -1433,10 +1495,7 @@ public class AlignFrame extends GAlignFrame Desktop.getInstance().closeAssociatedWindows(); FileLoader loader = new FileLoader(); -// DataSourceType protocol = fileName.startsWith("http:") -// ? DataSourceType.URL -// : DataSourceType.FILE; - loader.LoadFile(viewport, (fileObject == null ? fileName : fileObject), protocol, currentFileFormat); + loader.LoadFile(viewport, (fileObject == null ? fileName : fileObject), protocol, currentFileFormat); } else { @@ -1467,7 +1526,6 @@ public class AlignFrame extends GAlignFrame final FeatureSettings nfs = newframe.featureSettings; SwingUtilities.invokeLater(new Runnable() { - @Override public void run() { @@ -1479,7 +1537,6 @@ public class AlignFrame extends GAlignFrame } this.closeMenuItem_actionPerformed(true); } - } @Override @@ -1499,7 +1556,7 @@ public class AlignFrame extends GAlignFrame public void save_actionPerformed(ActionEvent e) { if (fileName == null || (currentFileFormat == null) - || fileName.startsWith("http")) + || HttpUtils.startsWithHttpOrHttps(fileName)) { saveAs_actionPerformed(); } @@ -1513,7 +1570,6 @@ public class AlignFrame extends GAlignFrame * Saves the alignment to a file with a name chosen by the user, if necessary * warning if a file would be overwritten */ - @Override public void saveAs_actionPerformed() { @@ -1568,17 +1624,25 @@ public class AlignFrame extends GAlignFrame * * @return true if last call to saveAlignment(file, format) was successful. */ - public boolean isSaveAlignmentSuccessful() { if (!lastSaveSuccessful) { - JvOptionPane.showInternalMessageDialog(this, MessageManager - .formatMessage("label.couldnt_save_file", new Object[] - { lastFilenameSaved }), - MessageManager.getString("label.error_saving_file"), - JvOptionPane.WARNING_MESSAGE); + if (!Platform.isHeadless()) + { + JvOptionPane.showInternalMessageDialog(this, MessageManager + .formatMessage("label.couldnt_save_file", new Object[] + { lastFilenameSaved }), + MessageManager.getString("label.error_saving_file"), + JvOptionPane.WARNING_MESSAGE); + } + else + { + Console.error(MessageManager + .formatMessage("label.couldnt_save_file", new Object[] + { lastFilenameSaved })); + } } else { @@ -1601,7 +1665,6 @@ public class AlignFrame extends GAlignFrame * @param file * @param format */ - public void saveAlignment(String file, FileFormatI format) { lastSaveSuccessful = true; @@ -1629,7 +1692,6 @@ public class AlignFrame extends GAlignFrame AlignExportSettingsI options = new AlignExportSettingsAdapter(false); Runnable cancelAction = new Runnable() { - @Override public void run() { @@ -1638,7 +1700,6 @@ public class AlignFrame extends GAlignFrame }; Runnable outputAction = new Runnable() { - @Override public void run() { @@ -1658,32 +1719,65 @@ public class AlignFrame extends GAlignFrame { // create backupfiles object and get new temp filename destination boolean doBackup = BackupFiles.getEnabled(); - BackupFiles backupfiles = doBackup ? new BackupFiles(file) : null; + BackupFiles backupfiles = null; + if (doBackup) + { + Console.trace( + "ALIGNFRAME making backupfiles object for " + file); + backupfiles = new BackupFiles(file); + } try { String tempFilePath = doBackup ? backupfiles.getTempFilePath() : file; + Console.trace("ALIGNFRAME setting PrintWriter"); PrintWriter out = new PrintWriter(new FileWriter(tempFilePath)); + if (backupfiles != null) + { + Console.trace("ALIGNFRAME about to write to temp file " + + backupfiles.getTempFilePath()); + } + out.print(output); + Console.trace("ALIGNFRAME about to close file"); out.close(); + Console.trace("ALIGNFRAME closed file"); AlignFrame.this.setTitle(file); statusBar.setText(MessageManager.formatMessage( "label.successfully_saved_to_file_in_format", new Object[] { fileName, format.getName() })); lastSaveSuccessful = true; + } catch (IOException e) + { + lastSaveSuccessful = false; + Console.error( + "ALIGNFRAME Something happened writing the temp file"); + Console.error(e.getMessage()); + Console.debug(Cache.getStackTraceString(e)); } catch (Exception ex) { lastSaveSuccessful = false; - ex.printStackTrace(); + Console.error( + "ALIGNFRAME Something unexpected happened writing the temp file"); + Console.error(ex.getMessage()); + Console.debug(Cache.getStackTraceString(ex)); } if (doBackup) { backupfiles.setWriteSuccess(lastSaveSuccessful); + Console.debug("ALIGNFRAME writing temp file was " + + (lastSaveSuccessful ? "" : "NOT ") + "successful"); // do the backup file roll and rename the temp file to actual file + Console.trace( + "ALIGNFRAME about to rollBackupsAndRenameTempFile"); lastSaveSuccessful = backupfiles.rollBackupsAndRenameTempFile(); + Console.debug( + "ALIGNFRAME performed rollBackupsAndRenameTempFile " + + (lastSaveSuccessful ? "" : "un") + + "successfully"); } } } @@ -1713,7 +1807,6 @@ public class AlignFrame extends GAlignFrame * * @param fileFormatName */ - @Override protected void outputText_actionPerformed(String fileFormatName) { @@ -1722,7 +1815,6 @@ public class AlignFrame extends GAlignFrame AlignExportSettingsI options = new AlignExportSettingsAdapter(false); Runnable outputAction = new Runnable() { - @Override public void run() { @@ -1773,7 +1865,6 @@ public class AlignFrame extends GAlignFrame * @param e * DOCUMENT ME! */ - @Override protected void htmlMenuItem_actionPerformed(ActionEvent e) { @@ -1789,7 +1880,6 @@ public class AlignFrame extends GAlignFrame } // ?? - public void createImageMap(File file, String image) { alignPanel.makePNGImageMap(file, image); @@ -1801,7 +1891,6 @@ public class AlignFrame extends GAlignFrame * * @param f */ - @Override public void createPNG(File f) { @@ -1814,7 +1903,6 @@ public class AlignFrame extends GAlignFrame * * @param f */ - @Override public void createEPS(File f) { @@ -1827,7 +1915,6 @@ public class AlignFrame extends GAlignFrame * * @param f */ - @Override public void createSVG(File f) { @@ -1847,7 +1934,6 @@ public class AlignFrame extends GAlignFrame * @param e * DOCUMENT ME! */ - @Override public void printMenuItem_actionPerformed(ActionEvent e) { @@ -1873,7 +1959,7 @@ public class AlignFrame extends GAlignFrame throws IOException, InterruptedException { final JalviewFileChooser chooser = new JalviewFileChooser( - jalview.bin.Cache.getProperty("LAST_DIRECTORY")); + Cache.getProperty("LAST_DIRECTORY")); chooser.setFileView(new JalviewFileView()); String tooltip = MessageManager .getString("label.load_jalview_annotations"); @@ -1881,12 +1967,11 @@ public class AlignFrame extends GAlignFrame chooser.setToolTipText(tooltip); chooser.setResponseHandler(0, new Runnable() { - @Override public void run() { String choice = chooser.getSelectedFile().getPath(); - jalview.bin.Cache.setProperty("LAST_DIRECTORY", choice); + Cache.setProperty("LAST_DIRECTORY", choice); loadJalviewDataFile(chooser.getSelectedFile(), null, null, null); } }); @@ -1900,7 +1985,6 @@ public class AlignFrame extends GAlignFrame * * @param closeAllTabs */ - @Override public void closeMenuItem_actionPerformed(boolean closeAllTabs) { @@ -1955,7 +2039,6 @@ public class AlignFrame extends GAlignFrame * * @param panelToClose */ - public void closeView(AlignmentPanel panelToClose) { int index = tabbedPane.getSelectedIndex(); @@ -1979,7 +2062,6 @@ public class AlignFrame extends GAlignFrame /** * DOCUMENT ME! */ - void updateEditMenuBar() { @@ -2033,7 +2115,6 @@ public class AlignFrame extends GAlignFrame * * @return alignment objects for all views */ - AlignmentI[] getViewAlignments() { if (alignPanels != null) @@ -2059,7 +2140,6 @@ public class AlignFrame extends GAlignFrame * @param e * DOCUMENT ME! */ - @Override protected void undoMenuItem_actionPerformed(ActionEvent e) { @@ -2078,7 +2158,7 @@ public class AlignFrame extends GAlignFrame { if (originalSource != viewport) { - Cache.log.warn( + Console.warn( "Implementation worry: mismatch of viewport origin for undo"); } originalSource.updateHiddenColumns(); @@ -2088,7 +2168,6 @@ public class AlignFrame extends GAlignFrame // viewport.getColumnSelection() // .getHiddenColumns().size() > 0); originalSource.notifyAlignment(); - } } @@ -2098,7 +2177,6 @@ public class AlignFrame extends GAlignFrame * @param e * DOCUMENT ME! */ - @Override protected void redoMenuItem_actionPerformed(ActionEvent e) { @@ -2119,7 +2197,7 @@ public class AlignFrame extends GAlignFrame if (originalSource != viewport) { - Cache.log.warn( + Console.warn( "Implementation worry: mismatch of viewport origin for redo"); } originalSource.updateHiddenColumns(); @@ -2129,7 +2207,6 @@ public class AlignFrame extends GAlignFrame // viewport.getColumnSelection() // .getHiddenColumns().size() > 0); originalSource.notifyAlignment(); - } } @@ -2176,20 +2253,37 @@ public class AlignFrame extends GAlignFrame } /** - * DOCUMENT ME! + * Calls AlignmentI.moveSelectedSequencesByOne with current sequence selection + * or the sequence under cursor in keyboard mode * * @param up - * DOCUMENT ME! + * or down (if !up) */ - public void moveSelectedSequences(boolean up) { SequenceGroup sg = viewport.getSelectionGroup(); if (sg == null) { + if (viewport.cursorMode) + { + sg = new SequenceGroup(); + sg.addSequence(viewport.getAlignment().getSequenceAt( + alignPanel.getSeqPanel().seqCanvas.cursorY), false); + } + else + { + return; + } + } + + if (sg.getSize() < 1) + { return; } + + // TODO: JAL-3733 - add an event to the undo buffer for this ! + viewport.getAlignment().moveSelectedSequencesByOne(sg, viewport.getHiddenRepSequences(), up); alignPanel.paintAlignment(true, false); @@ -2306,7 +2400,6 @@ public class AlignFrame extends GAlignFrame * @param e * DOCUMENT ME! */ - @Override protected void copy_actionPerformed() { @@ -2339,7 +2432,7 @@ public class AlignFrame extends GAlignFrame .setContents(new StringSelection(""), null); Toolkit.getDefaultToolkit().getSystemClipboard().setContents(ss, - Desktop.getInstance()); + d); } catch (OutOfMemoryError er) { new OOMWarning("copying region", er); @@ -2374,7 +2467,6 @@ public class AlignFrame extends GAlignFrame * @throws InterruptedException * @throws IOException */ - @Override protected void pasteNew_actionPerformed(ActionEvent e) throws IOException, InterruptedException @@ -2390,7 +2482,6 @@ public class AlignFrame extends GAlignFrame * @throws InterruptedException * @throws IOException */ - @Override protected void pasteThis_actionPerformed(ActionEvent e) throws IOException, InterruptedException @@ -2735,6 +2826,7 @@ public class AlignFrame extends GAlignFrame System.out.println("Exception whilst pasting: " + ex); // could be anything being pasted in here } + } @Override @@ -2747,6 +2839,7 @@ public class AlignFrame extends GAlignFrame AlignFrame af = new AlignFrame(alignment, DEFAULT_WIDTH, DEFAULT_HEIGHT); String newtitle = new String("Flanking alignment"); + Desktop d = Desktop.getInstance(); if (d.jalviewClipboard != null && d.jalviewClipboard[2] != null) { @@ -2789,7 +2882,6 @@ public class AlignFrame extends GAlignFrame /** * Action Cut (delete and copy) the selected region */ - @Override protected void cut_actionPerformed() { @@ -2800,7 +2892,6 @@ public class AlignFrame extends GAlignFrame /** * Performs menu option to Delete the currently selected region */ - @Override protected void delete_actionPerformed() { @@ -2813,7 +2904,6 @@ public class AlignFrame extends GAlignFrame Runnable okAction = new Runnable() { - @Override public void run() { @@ -2831,7 +2921,6 @@ public class AlignFrame extends GAlignFrame viewport.getAlignment().deleteGroup(sg); viewport.notifyAlignment(); - if (viewport.getAlignment().getHeight() < 1) { try @@ -2878,7 +2967,6 @@ public class AlignFrame extends GAlignFrame * @param e * DOCUMENT ME! */ - @Override protected void deleteGroups_actionPerformed(ActionEvent e) { @@ -2912,7 +3000,6 @@ public class AlignFrame extends GAlignFrame * @param e * DOCUMENT ME! */ - @Override public void selectAllSequenceMenuItem_actionPerformed(ActionEvent e) { @@ -2925,7 +3012,6 @@ public class AlignFrame extends GAlignFrame * @param e * DOCUMENT ME! */ - @Override public void deselectAllSequenceMenuItem_actionPerformed(ActionEvent e) { @@ -2938,7 +3024,6 @@ public class AlignFrame extends GAlignFrame * @param e * DOCUMENT ME! */ - @Override public void invertSequenceMenuItem_actionPerformed(ActionEvent e) { @@ -2978,7 +3063,6 @@ public class AlignFrame extends GAlignFrame * @param e * DOCUMENT ME! */ - @Override public void remove2LeftMenuItem_actionPerformed(ActionEvent e) { @@ -2991,7 +3075,6 @@ public class AlignFrame extends GAlignFrame * @param e * DOCUMENT ME! */ - @Override public void remove2RightMenuItem_actionPerformed(ActionEvent e) { @@ -3054,7 +3137,6 @@ public class AlignFrame extends GAlignFrame } viewport.notifyAlignment(); - } } @@ -3064,7 +3146,6 @@ public class AlignFrame extends GAlignFrame * @param e * DOCUMENT ME! */ - @Override public void removeGappedColumnMenuItem_actionPerformed(ActionEvent e) { @@ -3106,7 +3187,6 @@ public class AlignFrame extends GAlignFrame ranges.setStartRes(seq.findIndex(startRes) - 1); viewport.notifyAlignment(); - } /** @@ -3115,7 +3195,6 @@ public class AlignFrame extends GAlignFrame * @param e * DOCUMENT ME! */ - @Override public void removeAllGapsMenuItem_actionPerformed(ActionEvent e) { @@ -3143,6 +3222,7 @@ public class AlignFrame extends GAlignFrame viewport.getAlignment())); viewport.getRanges().setStartRes(seq.findIndex(startRes) - 1); + viewport.notifyAlignment(); } @@ -3153,32 +3233,27 @@ public class AlignFrame extends GAlignFrame * @param e * DOCUMENT ME! */ - @Override public void padGapsMenuitem_actionPerformed(ActionEvent e) { viewport.setPadGaps(padGapsMenuitem.isSelected()); viewport.notifyAlignment(); - } /** - * DOCUMENT ME! + * Opens a Finder dialog * * @param e - * DOCUMENT ME! */ - @Override public void findMenuItem_actionPerformed(ActionEvent e) { - new Finder(); + new Finder(alignPanel, false, null); } /** * Create a new view of the current alignment. */ - @Override public void newView_actionPerformed(ActionEvent e) { @@ -3194,7 +3269,6 @@ public class AlignFrame extends GAlignFrame * if true then duplicate all annnotation, groups and settings * @return new alignment panel, already displayed. */ - public AlignmentPanel newView(String viewTitle, boolean copyAnnotation) { /* @@ -3267,7 +3341,6 @@ public class AlignFrame extends GAlignFrame * @param viewTitle * @return */ - protected String getNewViewName(String viewTitle) { int index = Desktop.getViewCount(viewport.getSequenceSetId()); @@ -3302,7 +3375,6 @@ public class AlignFrame extends GAlignFrame * @param comps * @return */ - protected List getExistingViewNames(List comps) { List existingNames = new ArrayList<>(); @@ -3323,7 +3395,6 @@ public class AlignFrame extends GAlignFrame /** * Explode tabbed views into separate windows. */ - @Override public void expandViews_actionPerformed(ActionEvent e) { @@ -3333,7 +3404,6 @@ public class AlignFrame extends GAlignFrame /** * Gather views in separate windows back into a tabbed presentation. */ - @Override public void gatherViews_actionPerformed(ActionEvent e) { @@ -3346,7 +3416,6 @@ public class AlignFrame extends GAlignFrame * @param e * DOCUMENT ME! */ - @Override public void font_actionPerformed(ActionEvent e) { @@ -3359,7 +3428,6 @@ public class AlignFrame extends GAlignFrame * @param e * DOCUMENT ME! */ - @Override protected void seqLimit_actionPerformed(ActionEvent e) { @@ -3389,7 +3457,6 @@ public class AlignFrame extends GAlignFrame * * @see jalview.jbgui.GAlignFrame#followHighlight_actionPerformed() */ - @Override protected void followHighlight_actionPerformed() { @@ -3411,7 +3478,6 @@ public class AlignFrame extends GAlignFrame * @param e * DOCUMENT ME! */ - @Override protected void colourTextMenuItem_actionPerformed(ActionEvent e) { @@ -3425,7 +3491,6 @@ public class AlignFrame extends GAlignFrame * @param e * DOCUMENT ME! */ - @Override public void wrapMenuItem_actionPerformed(ActionEvent e) { @@ -3462,7 +3527,6 @@ public class AlignFrame extends GAlignFrame * @param toggleSeqs * @param toggleCols */ - protected void toggleHiddenRegions(boolean toggleSeqs, boolean toggleCols) { @@ -3530,7 +3594,6 @@ public class AlignFrame extends GAlignFrame * jalview.jbgui.GAlignFrame#hideAllButSelection_actionPerformed(java.awt. * event.ActionEvent) */ - @Override public void hideAllButSelection_actionPerformed(ActionEvent e) { @@ -3545,7 +3608,6 @@ public class AlignFrame extends GAlignFrame * jalview.jbgui.GAlignFrame#hideAllSelection_actionPerformed(java.awt.event * .ActionEvent) */ - @Override public void hideAllSelection_actionPerformed(ActionEvent e) { @@ -3565,7 +3627,6 @@ public class AlignFrame extends GAlignFrame * jalview.jbgui.GAlignFrame#showAllhidden_actionPerformed(java.awt.event. * ActionEvent) */ - @Override public void showAllhidden_actionPerformed(ActionEvent e) { @@ -3597,7 +3658,6 @@ public class AlignFrame extends GAlignFrame * @param e * DOCUMENT ME! */ - @Override protected void scaleAbove_actionPerformed(ActionEvent e) { @@ -3612,7 +3672,6 @@ public class AlignFrame extends GAlignFrame * @param e * DOCUMENT ME! */ - @Override protected void scaleLeft_actionPerformed(ActionEvent e) { @@ -3627,7 +3686,6 @@ public class AlignFrame extends GAlignFrame * @param e * DOCUMENT ME! */ - @Override protected void scaleRight_actionPerformed(ActionEvent e) { @@ -3642,7 +3700,6 @@ public class AlignFrame extends GAlignFrame * @param e * DOCUMENT ME! */ - @Override public void viewBoxesMenuItem_actionPerformed(ActionEvent e) { @@ -3656,7 +3713,6 @@ public class AlignFrame extends GAlignFrame * @param e * DOCUMENT ME! */ - @Override public void viewTextMenuItem_actionPerformed(ActionEvent e) { @@ -3670,7 +3726,6 @@ public class AlignFrame extends GAlignFrame * @param e * DOCUMENT ME! */ - @Override protected void renderGapsMenuItem_actionPerformed(ActionEvent e) { @@ -3716,7 +3771,6 @@ public class AlignFrame extends GAlignFrame * @param evt * DOCUMENT ME! */ - @Override public void showSeqFeatures_actionPerformed(ActionEvent evt) { @@ -3733,7 +3787,6 @@ public class AlignFrame extends GAlignFrame * * @param e */ - @Override public void annotationPanelMenuItem_actionPerformed(ActionEvent e) { @@ -3812,7 +3865,6 @@ public class AlignFrame extends GAlignFrame * @param e * DOCUMENT ME! */ - @Override public void overviewMenuItem_actionPerformed(ActionEvent e) { @@ -3822,7 +3874,6 @@ public class AlignFrame extends GAlignFrame } JInternalFrame frame = new JInternalFrame(); - // BH 2019.07.26 we allow for an embedded // undecorated overview with defined size frame.setName(Platform.getAppID("overview")); @@ -3833,7 +3884,6 @@ public class AlignFrame extends GAlignFrame dim = null; // hidden, not embedded } OverviewPanel overview = new OverviewPanel(alignPanel, dim); - frame.setContentPane(overview); if (dim == null) { @@ -3857,7 +3907,6 @@ public class AlignFrame extends GAlignFrame frame.addInternalFrameListener( new javax.swing.event.InternalFrameAdapter() { - @Override public void internalFrameClosed( javax.swing.event.InternalFrameEvent evt) @@ -3886,7 +3935,6 @@ public class AlignFrame extends GAlignFrame * CovariationColourScheme(viewport.getAlignment().getAlignmentAnnotation * ()[0])); } */ - @Override public void annotationColour_actionPerformed() { @@ -3906,7 +3954,6 @@ public class AlignFrame extends GAlignFrame * * @param selected */ - @Override public void applyToAllGroups_actionPerformed(boolean selected) { @@ -3919,7 +3966,6 @@ public class AlignFrame extends GAlignFrame * @param name * the name (not the menu item label!) of the colour scheme */ - @Override public void changeColour_actionPerformed(String name) { @@ -3947,7 +3993,6 @@ public class AlignFrame extends GAlignFrame * * @param cs */ - @Override public void changeColour(ColourSchemeI cs) { @@ -3962,7 +4007,6 @@ public class AlignFrame extends GAlignFrame /** * Show the PID threshold slider panel */ - @Override protected void modifyPID_actionPerformed() { @@ -3974,7 +4018,6 @@ public class AlignFrame extends GAlignFrame /** * Show the Conservation slider panel */ - @Override protected void modifyConservation_actionPerformed() { @@ -3986,7 +4029,6 @@ public class AlignFrame extends GAlignFrame /** * Action on selecting or deselecting (Colour) By Conservation */ - @Override public void conservationMenuItem_actionPerformed(boolean selected) { @@ -4008,7 +4050,6 @@ public class AlignFrame extends GAlignFrame /** * Action on selecting or deselecting (Colour) Above PID Threshold */ - @Override public void abovePIDThreshold_actionPerformed(boolean selected) { @@ -4037,7 +4078,6 @@ public class AlignFrame extends GAlignFrame * @param e * DOCUMENT ME! */ - @Override public void sortPairwiseMenuItem_actionPerformed(ActionEvent e) { @@ -4055,7 +4095,6 @@ public class AlignFrame extends GAlignFrame * @param e * DOCUMENT ME! */ - @Override public void sortIDMenuItem_actionPerformed(ActionEvent e) { @@ -4072,7 +4111,6 @@ public class AlignFrame extends GAlignFrame * @param e * DOCUMENT ME! */ - @Override public void sortLengthMenuItem_actionPerformed(ActionEvent e) { @@ -4089,7 +4127,6 @@ public class AlignFrame extends GAlignFrame * @param e * DOCUMENT ME! */ - @Override public void sortGroupMenuItem_actionPerformed(ActionEvent e) { @@ -4122,14 +4159,12 @@ public class AlignFrame extends GAlignFrame alignPanel.paintAlignment(true, false); } - /** * DOCUMENT ME! * * @param e * DOCUMENT ME! */ - @Override public void removeRedundancyMenuItem_actionPerformed(ActionEvent e) { @@ -4142,7 +4177,6 @@ public class AlignFrame extends GAlignFrame * @param e * DOCUMENT ME! */ - @Override public void pairwiseAlignmentMenuItem_actionPerformed(ActionEvent e) { @@ -4171,9 +4205,6 @@ public class AlignFrame extends GAlignFrame viewport.setAutoCalculateConsensusAndConservation( autoCalculate.isSelected()); if (viewport.getAutoCalculateConsensusAndConservation()) - // ?? - // viewport.autoCalculateConsensus = autoCalculate.isSelected(); - // if (viewport.autoCalculateConsensus) { viewport.notifyAlignment(); } @@ -4201,7 +4232,6 @@ public class AlignFrame extends GAlignFrame * @param options * parameters for the distance or similarity calculation */ - void newTreePanel(String type, String modelName, SimilarityParamsI options) { @@ -4263,7 +4293,6 @@ public class AlignFrame extends GAlignFrame * @param order * DOCUMENT ME! */ - public void addSortByOrderMenuItem(String title, final AlignmentOrder order) { @@ -4273,7 +4302,6 @@ public class AlignFrame extends GAlignFrame sort.add(item); item.addActionListener(new java.awt.event.ActionListener() { - @Override public void actionPerformed(ActionEvent e) { @@ -4300,7 +4328,6 @@ public class AlignFrame extends GAlignFrame * the label used to retrieve scores for each sequence on the * alignment */ - public void addSortByAnnotScoreMenuItem(JMenu sort, final String scoreLabel) { @@ -4308,7 +4335,6 @@ public class AlignFrame extends GAlignFrame sort.add(item); item.addActionListener(new java.awt.event.ActionListener() { - @Override public void actionPerformed(ActionEvent e) { @@ -4334,7 +4360,6 @@ public class AlignFrame extends GAlignFrame * rebuilding in subsequence calls. * */ - @Override public void buildSortByAnnotationScoresMenu() { @@ -4392,7 +4417,6 @@ public class AlignFrame extends GAlignFrame * closed, and adjust the tree leaf to sequence mapping when the alignment is * modified. */ - @Override public void buildTreeSortMenu() { @@ -4405,7 +4429,6 @@ public class AlignFrame extends GAlignFrame final JMenuItem item = new JMenuItem(tp.getTitle()); item.addActionListener(new java.awt.event.ActionListener() { - @Override public void actionPerformed(ActionEvent e) { @@ -4433,7 +4456,6 @@ public class AlignFrame extends GAlignFrame } return treePanels; } - public boolean sortBy(AlignmentOrder alorder, String undoname) { SequenceI[] oldOrder = viewport.getAlignment().getSequencesArray(); @@ -4452,7 +4474,6 @@ public class AlignFrame extends GAlignFrame * be submitted for multiple alignment. * */ - public jalview.datamodel.AlignmentView gatherSequencesForAlignment() { // Now, check we have enough sequences @@ -4498,7 +4519,6 @@ public class AlignFrame extends GAlignFrame * region or the whole alignment. (where the first sequence in the set is the * one that the prediction will be for). */ - public AlignmentView gatherSeqOrMsaForSecStrPrediction() { AlignmentView seqs = null; @@ -4532,13 +4552,12 @@ public class AlignFrame extends GAlignFrame * @param e * DOCUMENT ME! */ - @Override protected void loadTreeMenuItem_actionPerformed(ActionEvent e) { // Pick the tree file JalviewFileChooser chooser = new JalviewFileChooser( - jalview.bin.Cache.getProperty("LAST_DIRECTORY")); + Cache.getProperty("LAST_DIRECTORY")); chooser.setFileView(new JalviewFileView()); chooser.setDialogTitle( MessageManager.getString("label.select_newick_like_tree_file")); @@ -4547,7 +4566,6 @@ public class AlignFrame extends GAlignFrame chooser.setResponseHandler(0, new Runnable() { - @Override public void run() { @@ -4612,7 +4630,6 @@ public class AlignFrame extends GAlignFrame * position * @return TreePanel handle */ - public TreePanel showNewickTree(NewickFile nf, String treeTitle, AlignmentView input, int w, int h, int x, int y) { @@ -4625,6 +4642,7 @@ public class AlignFrame extends GAlignFrame if (nf.getTree() != null) { tp = new TreePanel(alignPanel, nf, treeTitle, input); + Dimension dim = Platform.getDimIfEmbedded(tp, -1, -1); if (dim == null) { @@ -4653,6 +4671,7 @@ public class AlignFrame extends GAlignFrame } private WebServicesMenuManager slivkaMenu = new WebServicesMenuManager("slivka", this); + private WebServicesMenuManager ebiMenu = new WebServicesMenuManager("job dispatcher", this); /** * Schedule the web services menu rebuild to the event dispatch thread. @@ -4660,17 +4679,26 @@ public class AlignFrame extends GAlignFrame public void buildWebServicesMenu() { SwingUtilities.invokeLater(() -> { - Cache.log.info("Rebuiling WS menu"); + Console.info("Rebuiling WS menu"); webService.removeAll(); if (Cache.getDefault("SHOW_SLIVKA_SERVICES", true)) { - Cache.log.info("Building web service menu for slivka"); + Console.info("Building web service menu for slivka"); SlivkaWSDiscoverer discoverer = SlivkaWSDiscoverer.getInstance(); slivkaMenu.setServices(discoverer); slivkaMenu.setInProgress(discoverer.isRunning()); slivkaMenu.setNoServices(discoverer.isDone() && !discoverer.hasServices()); webService.add(slivkaMenu.getMenu()); } + if (Cache.getDefault("SHOW_EBI_SERVICES", true)) + { + Console.info("Building web services menu for jobs dispatcher"); + JobDispatcherWSDiscoverer discoverer = JobDispatcherWSDiscoverer.getInstance(); + ebiMenu.setServices(discoverer); + ebiMenu.setInProgress(discoverer.isRunning()); + ebiMenu.setNoServices(discoverer.isDone() && !discoverer.hasServices()); + webService.add(ebiMenu.getMenu()); + } if (Cache.getDefault("SHOW_JWS2_SERVICES", true)) { WSDiscovererI jws2servs = Jws2Discoverer.getInstance(); @@ -4738,7 +4766,6 @@ public class AlignFrame extends GAlignFrame * * @param webService */ - protected void build_urlServiceMenu(JMenu webService) { // TODO: remove this code when 2.7 is released @@ -4776,7 +4803,6 @@ public class AlignFrame extends GAlignFrame * * @return true if Show Cross-references menu should be enabled */ - public boolean canShowProducts() { SequenceI[] seqs = viewport.getAlignment().getSequencesArray(); @@ -4804,7 +4830,6 @@ public class AlignFrame extends GAlignFrame JMenuItem xtype = new JMenuItem(source); xtype.addActionListener(new ActionListener() { - @Override public void actionPerformed(ActionEvent e) { @@ -4818,7 +4843,7 @@ public class AlignFrame extends GAlignFrame showProducts.setEnabled(showp); } catch (Exception e) { - Cache.log.warn( + Console.warn( "canShowProducts threw an exception - please report to help@jalview.org", e); return false; @@ -4837,7 +4862,6 @@ public class AlignFrame extends GAlignFrame * @param source * the database to show cross-references for */ - protected void showProductsFor(final SequenceI[] sel, final boolean _odna, final String source) { @@ -4849,7 +4873,6 @@ public class AlignFrame extends GAlignFrame * Construct and display a new frame containing the translation of this * frame's DNA sequences to their aligned protein (amino acid) equivalents. */ - @Override public void showTranslation_actionPerformed(GeneticCodeI codeTable) { @@ -4861,8 +4884,8 @@ public class AlignFrame extends GAlignFrame al = dna.translateCdna(codeTable); } catch (Exception ex) { - jalview.bin.Cache.log.error( - "Exception during translation. Please report this !", ex); + Console.error("Exception during translation. Please report this !", + ex); final String msg = MessageManager.getString( "label.error_when_translating_sequences_submit_bug_report"); final String errorTitle = MessageManager @@ -4907,7 +4930,6 @@ public class AlignFrame extends GAlignFrame * * @param format */ - public void setFileFormat(FileFormatI format) { this.currentFileFormat = format; @@ -4922,7 +4944,6 @@ public class AlignFrame extends GAlignFrame * access mode of file (see jalview.io.AlignFile) * @return true if features file was parsed correctly. */ - public boolean parseFeaturesFile(Object file, DataSourceType sourceType) { // BH 2018 @@ -5114,6 +5135,7 @@ public class AlignFrame extends GAlignFrame + " with " + toassoc.getDisplayId(true)); assocfiles++; } + } // TODO: do we need to update overview ? only if features are // shown I guess @@ -5174,7 +5196,6 @@ public class AlignFrame extends GAlignFrame * @throws InterruptedException * @throws IOException */ - public void loadJalviewDataFile(Object file, DataSourceType sourceType, FileFormatI format, SequenceI assocSeq) { @@ -5232,7 +5253,7 @@ public class AlignFrame extends GAlignFrame } } catch (Exception x) { - Cache.log.debug( + Console.debug( "Exception when processing data source as T-COFFEE score file", x); tcf = null; @@ -5289,6 +5310,7 @@ public class AlignFrame extends GAlignFrame } if (isAnnotation) { + updateForAnnotations(); } } catch (Exception ex) @@ -5361,7 +5383,6 @@ public class AlignFrame extends GAlignFrame * Method invoked by the ChangeListener on the tabbed pane, in other words * when a different tabbed pane is selected by the user or programmatically. */ - @Override public void tabSelectionChanged(int index) { @@ -5432,7 +5453,6 @@ public class AlignFrame extends GAlignFrame /** * On right mouse click on view tab, prompt for and set new view name. */ - @Override public void tabbedPane_mousePressed(MouseEvent e) { @@ -5459,7 +5479,6 @@ public class AlignFrame extends GAlignFrame /** * Open the dialog for regex description parsing. */ - @Override protected void extractScores_actionPerformed(ActionEvent e) { @@ -5483,7 +5502,6 @@ public class AlignFrame extends GAlignFrame * jalview.jbgui.GAlignFrame#showDbRefs_actionPerformed(java.awt.event.ActionEvent * ) */ - @Override protected void showDbRefs_actionPerformed(ActionEvent e) { @@ -5496,7 +5514,6 @@ public class AlignFrame extends GAlignFrame * @seejalview.jbgui.GAlignFrame#showNpFeats_actionPerformed(java.awt.event. * ActionEvent) */ - @Override protected void showNpFeats_actionPerformed(ActionEvent e) { @@ -5509,7 +5526,6 @@ public class AlignFrame extends GAlignFrame * * @param av */ - public boolean closeView(AlignViewportI av) { if (viewport == av) @@ -5553,7 +5569,6 @@ public class AlignFrame extends GAlignFrame Cache.getDefault(DBRefFetcher.TRIM_RETRIEVED_SEQUENCES, true)); trimrs.addActionListener(new ActionListener() { - @Override public void actionPerformed(ActionEvent e) { @@ -5575,7 +5590,6 @@ public class AlignFrame extends GAlignFrame { new Thread(new Runnable() { - @Override public void run() { @@ -5587,7 +5601,6 @@ public class AlignFrame extends GAlignFrame alignPanel.alignFrame.featureSettings, isNucleotide); dbRefFetcher.addListener(new FetchFinishedListenerI() { - @Override public void finished() { @@ -5611,7 +5624,6 @@ public class AlignFrame extends GAlignFrame rfetch.add(fetchr); new Thread(new Runnable() { - @Override public void run() { @@ -5620,7 +5632,6 @@ public class AlignFrame extends GAlignFrame // .getSequenceFetcherSingleton(); javax.swing.SwingUtilities.invokeLater(new Runnable() { - @Override public void run() { @@ -5675,7 +5686,6 @@ public class AlignFrame extends GAlignFrame dbRefFetcher .addListener(new FetchFinishedListenerI() { - @Override public void finished() { @@ -5710,7 +5720,6 @@ public class AlignFrame extends GAlignFrame { src.getDbSource() })); fetchr.addActionListener(new ActionListener() { - @Override public void actionPerformed(ActionEvent e) { @@ -5731,7 +5740,6 @@ public class AlignFrame extends GAlignFrame dbRefFetcher .addListener(new FetchFinishedListenerI() { - @Override public void finished() { @@ -5800,7 +5808,6 @@ public class AlignFrame extends GAlignFrame dbRefFetcher .addListener(new FetchFinishedListenerI() { - @Override public void finished() { @@ -5852,7 +5859,6 @@ public class AlignFrame extends GAlignFrame /** * Left justify the whole alignment. */ - @Override protected void justifyLeftMenuItem_actionPerformed(ActionEvent e) { @@ -5863,7 +5869,6 @@ public class AlignFrame extends GAlignFrame /** * Right justify the whole alignment. */ - @Override protected void justifyRightMenuItem_actionPerformed(ActionEvent e) { @@ -5885,7 +5890,6 @@ public class AlignFrame extends GAlignFrame * jalview.jbgui.GAlignFrame#showUnconservedMenuItem_actionPerformed(java. * awt.event.ActionEvent) */ - @Override protected void showUnconservedMenuItem_actionPerformed(ActionEvent e) { @@ -5900,7 +5904,6 @@ public class AlignFrame extends GAlignFrame * jalview.jbgui.GAlignFrame#showGroupConsensus_actionPerformed(java.awt.event * .ActionEvent) */ - @Override protected void showGroupConsensus_actionPerformed(ActionEvent e) { @@ -5916,7 +5919,6 @@ public class AlignFrame extends GAlignFrame * jalview.jbgui.GAlignFrame#showGroupConservation_actionPerformed(java.awt * .event.ActionEvent) */ - @Override protected void showGroupConservation_actionPerformed(ActionEvent e) { @@ -5931,7 +5933,6 @@ public class AlignFrame extends GAlignFrame * jalview.jbgui.GAlignFrame#showConsensusHistogram_actionPerformed(java.awt * .event.ActionEvent) */ - @Override protected void showConsensusHistogram_actionPerformed(ActionEvent e) { @@ -5946,7 +5947,6 @@ public class AlignFrame extends GAlignFrame * jalview.jbgui.GAlignFrame#showConsensusProfile_actionPerformed(java.awt * .event.ActionEvent) */ - @Override protected void showSequenceLogo_actionPerformed(ActionEvent e) { @@ -5976,7 +5976,6 @@ public class AlignFrame extends GAlignFrame * jalview.jbgui.GAlignFrame#makeGrpsFromSelection_actionPerformed(java.awt * .event.ActionEvent) */ - @Override protected void makeGrpsFromSelection_actionPerformed(ActionEvent e) { @@ -6028,7 +6027,6 @@ public class AlignFrame extends GAlignFrame * * @param alignmentPanel */ - public void setDisplayedView(AlignmentPanel alignmentPanel) { if (!viewport.getSequenceSetId() @@ -6053,7 +6051,6 @@ public class AlignFrame extends GAlignFrame * @param forAlignment * update non-sequence-related annotations */ - @Override protected void setAnnotationsVisibility(boolean visible, boolean forSequences, boolean forAlignment) @@ -6087,7 +6084,6 @@ public class AlignFrame extends GAlignFrame /** * Store selected annotation sort order for the view and repaint. */ - @Override protected void sortAnnotations_actionPerformed() { @@ -6101,7 +6097,6 @@ public class AlignFrame extends GAlignFrame * * @return alignment panels in this alignment frame */ - public List getAlignPanels() { // alignPanels is never null @@ -6113,7 +6108,6 @@ public class AlignFrame extends GAlignFrame * Open a new alignment window, with the cDNA associated with this (protein) * alignment, aligned as is the protein. */ - protected void viewAsCdna_actionPerformed() { // TODO no longer a menu action - refactor as required @@ -6164,7 +6158,6 @@ public class AlignFrame extends GAlignFrame * * @param show */ - @Override protected void showComplement_actionPerformed(boolean show) { @@ -6179,7 +6172,6 @@ public class AlignFrame extends GAlignFrame * Generate the reverse (optionally complemented) of the selected sequences, * and add them to the alignment */ - @Override protected void showReverse_actionPerformed(boolean complement) { @@ -6205,7 +6197,6 @@ public class AlignFrame extends GAlignFrame * AlignFrame is set as currentAlignFrame in Desktop, to allow the script to * be targeted at this alignment. */ - @Override protected void runGroovy_actionPerformed() { @@ -6239,7 +6230,6 @@ public class AlignFrame extends GAlignFrame * @param columnsContaining * @return */ - public boolean hideFeatureColumns(String featureType, boolean columnsContaining) { @@ -6272,7 +6262,6 @@ public class AlignFrame extends GAlignFrame * Rebuilds the Colour menu, including any user-defined colours which have * been loaded either on startup or during the session */ - public void buildColourMenu() { colourMenu.removeAll(); @@ -6300,7 +6289,6 @@ public class AlignFrame extends GAlignFrame * Open a dialog (if not already open) that allows the user to select and * calculate PCA or Tree analysis */ - protected void openTreePcaDialog() { if (alignPanel.getCalculationDialog() == null) @@ -6316,7 +6304,6 @@ public class AlignFrame extends GAlignFrame { hmmerMenu.setEnabled(HmmerCommand.isHmmerAvailable()); } - @Override protected void loadVcf_actionPerformed() { @@ -6328,7 +6315,6 @@ public class AlignFrame extends GAlignFrame final AlignFrame us = this; chooser.setResponseHandler(0, new Runnable() { - @Override public void run() { @@ -6461,4 +6447,3 @@ public class AlignFrame extends GAlignFrame } } } -