From 48e09f7d3cfa93b2a9c9721740540a35de7c13f1 Mon Sep 17 00:00:00 2001 From: tjc <tjc@ee4ac58c-ac51-4696-9907-e4b3aa274f04> Date: Fri, 18 Feb 2011 11:48:38 +0000 Subject: [PATCH] organise menu for writing and viewing fasta git-svn-id: svn+ssh://svn.internal.sanger.ac.uk/repos/svn/pathsoft/artemis/trunk@15562 ee4ac58c-ac51-4696-9907-e4b3aa274f04 --- .../artemis/components/variant/VCFview.java | 26 ++++++++++--------- 1 file changed, 14 insertions(+), 12 deletions(-) diff --git a/uk/ac/sanger/artemis/components/variant/VCFview.java b/uk/ac/sanger/artemis/components/variant/VCFview.java index 289ca3e50..228348770 100644 --- a/uk/ac/sanger/artemis/components/variant/VCFview.java +++ b/uk/ac/sanger/artemis/components/variant/VCFview.java @@ -497,10 +497,10 @@ public class VCFview extends JPanel popup.addSeparator(); - final JMenu export = new JMenu("Export / View"); + final JMenu export = new JMenu("Write"); popup.add(export); - final JMenuItem exportVCF = new JMenuItem("Write Filtered VCF"); + final JMenuItem exportVCF = new JMenuItem("Filtered VCF"); exportVCF.addActionListener(new ActionListener(){ public void actionPerformed(ActionEvent e) { @@ -511,7 +511,7 @@ public class VCFview extends JPanel }); export.add(exportVCF); - final JMenuItem exportFastaSelected = new JMenuItem("Write FASTA of selected feature(s)"); + final JMenuItem exportFastaSelected = new JMenuItem("FASTA of selected feature(s)"); exportFastaSelected.addActionListener(new ActionListener(){ public void actionPerformed(ActionEvent e) { @@ -523,28 +523,30 @@ public class VCFview extends JPanel }); export.add(exportFastaSelected); - final JMenuItem viewFastaSelected = new JMenuItem("View FASTA of selected feature(s)"); - viewFastaSelected.addActionListener(new ActionListener(){ + final JMenuItem exportFasta = new JMenuItem("FASTA"); + exportFasta.addActionListener(new ActionListener(){ public void actionPerformed(ActionEvent e) { VCFview.this.setCursor(new Cursor(Cursor.WAIT_CURSOR)); - IOUtils.exportFasta(entryGroup, vcfReaders, chr, VCFview.this, vcf_v4, - selection.getAllFeatures(), true); + IOUtils.exportFasta(entryGroup, vcfReaders, chr, VCFview.this, vcf_v4); VCFview.this.setCursor(new Cursor(Cursor.DEFAULT_CURSOR)); } }); - export.add(viewFastaSelected); + export.add(exportFasta); - final JMenuItem exportFasta = new JMenuItem("FASTA"); - exportFasta.addActionListener(new ActionListener(){ + final JMenu view = new JMenu("View"); + popup.add(view); + final JMenuItem viewFastaSelected = new JMenuItem("FASTA of selected feature(s)"); + viewFastaSelected.addActionListener(new ActionListener(){ public void actionPerformed(ActionEvent e) { VCFview.this.setCursor(new Cursor(Cursor.WAIT_CURSOR)); - IOUtils.exportFasta(entryGroup, vcfReaders, chr, VCFview.this, vcf_v4); + IOUtils.exportFasta(entryGroup, vcfReaders, chr, VCFview.this, vcf_v4, + selection.getAllFeatures(), true); VCFview.this.setCursor(new Cursor(Cursor.DEFAULT_CURSOR)); } }); - export.add(exportFasta); + view.add(viewFastaSelected); } private static EntryGroup getReference(String reference) -- GitLab