JAL-1517 fix copyright for 2.8.2
[jalview.git] / src / jalview / jbgui / GAlignFrame.java
index ee6ba9f..16e78f5 100755 (executable)
@@ -1,19 +1,21 @@
 /*
- * Jalview - A Sequence Alignment Editor and Viewer (Version 2.8.0b1)
+ * Jalview - A Sequence Alignment Editor and Viewer (Version 2.8.2)
  * Copyright (C) 2014 The Jalview Authors
  * 
  * 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 
- * as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
+ * 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 
  * 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 <http://www.gnu.org/licenses/>.
+ * You should have received a copy of the GNU General Public License
+ * along with Jalview.  If not, see <http://www.gnu.org/licenses/>.
  * The Jalview Authors are detailed in the 'AUTHORS' file.
  */
 package jalview.jbgui;
@@ -140,6 +142,8 @@ public class GAlignFrame extends JInternalFrame
   protected JRadioButtonMenuItem nucleotideColour = new JRadioButtonMenuItem();
 
   protected JRadioButtonMenuItem purinePyrimidineColour = new JRadioButtonMenuItem();
+  
+  protected JRadioButtonMenuItem RNAInteractionColour = new JRadioButtonMenuItem();
 
   // protected JRadioButtonMenuItem covariationColour = new
   // JRadioButtonMenuItem();
@@ -242,6 +246,8 @@ public class GAlignFrame extends JInternalFrame
   protected JMenuItem showTranslation = new JMenuItem();
 
   protected JMenuItem extractScores = new JMenuItem();
+  
+  protected JMenuItem expandAlignment = new JMenuItem();
 
   protected JMenu showProducts = new JMenu();
 
@@ -458,7 +464,7 @@ public class GAlignFrame extends JInternalFrame
     colours.add(purinePyrimidineColour);
     // colours.add(covariationColour);
     colours.add(tcoffeeColour);
-
+    colours.add(RNAInteractionColour);
     setColourSelected(jalview.bin.Cache
             .getDefault("DEFAULT_COLOUR", "None"));
 
@@ -536,6 +542,11 @@ public class GAlignFrame extends JInternalFrame
         purinePyrimidineColour.setSelected(true);
 
         break;
+        
+      case ColourSchemeProperty.RNAINTERACTION:
+          RNAInteractionColour.setSelected(true);
+
+          break;
       /*
        * case ColourSchemeProperty.COVARIATION:
        * covariationColour.setSelected(true);
@@ -630,7 +641,15 @@ public class GAlignFrame extends JInternalFrame
         makeGrpsFromSelection_actionPerformed(e);
       }
     });
-
+    expandAlignment.setText(MessageManager.getString("action.view_flanking_regions"));
+    expandAlignment.setToolTipText(MessageManager.getString("label.view_flanking_regions"));
+    expandAlignment.addActionListener(new java.awt.event.ActionListener() {
+      @Override
+      public void actionPerformed(ActionEvent e)
+      {
+        expand_newalign(e);
+      }
+    });
     remove2LeftMenuItem.setText(MessageManager.getString("action.remove_left"));
     remove2LeftMenuItem.setAccelerator(javax.swing.KeyStroke.getKeyStroke(
             java.awt.event.KeyEvent.VK_L, Toolkit.getDefaultToolkit()
@@ -865,7 +884,7 @@ public class GAlignFrame extends JInternalFrame
         strandColour_actionPerformed(e);
       }
     });
-    turnColour.setText(MessageManager.getString("Turn Propensity"));
+    turnColour.setText(MessageManager.getString("label.turn_propensity"));
     turnColour.addActionListener(new java.awt.event.ActionListener()
     {
       public void actionPerformed(ActionEvent e)
@@ -873,7 +892,7 @@ public class GAlignFrame extends JInternalFrame
         turnColour_actionPerformed(e);
       }
     });
-    buriedColour.setText(MessageManager.getString("Buried Index"));
+    buriedColour.setText(MessageManager.getString("label.buried_index"));
     buriedColour.addActionListener(new java.awt.event.ActionListener()
     {
       public void actionPerformed(ActionEvent e)
@@ -923,6 +942,15 @@ public class GAlignFrame extends JInternalFrame
                 purinePyrimidineColour_actionPerformed(e);
               }
             });
+    
+    RNAInteractionColour.setText("RNA Interaction type");
+    RNAInteractionColour.addActionListener(new java.awt.event.ActionListener()
+            {
+              public void actionPerformed(ActionEvent e)
+              {
+                 RNAInteractionColour_actionPerformed(e);
+              }
+            });
     /*
      * covariationColour.setText("Covariation");
      * covariationColour.addActionListener(new java.awt.event.ActionListener() {
@@ -1899,6 +1927,7 @@ public class GAlignFrame extends JInternalFrame
     colourMenu.add(buriedColour);
     colourMenu.add(nucleotideColour);
     colourMenu.add(purinePyrimidineColour);
+    colourMenu.add(RNAInteractionColour);
     // colourMenu.add(covariationColour);
     colourMenu.add(tcoffeeColour);
     colourMenu.add(userDefinedColour);
@@ -1908,7 +1937,7 @@ public class GAlignFrame extends JInternalFrame
     colourMenu.add(abovePIDThreshold);
     colourMenu.add(modifyPID);
     colourMenu.add(annotationColour);
-    colourMenu.add(rnahelicesColour);
+    colourMenu.add(rnahelicesColour);  
     calculateMenu.add(sort);
     calculateMenu.add(calculateTree);
     calculateMenu.addSeparator();
@@ -1930,10 +1959,6 @@ public class GAlignFrame extends JInternalFrame
     sort.add(sortGroupMenuItem);
     sort.add(sortPairwiseMenuItem);
     sort.add(sortByTreeMenu);
-    calculateTree.add(averageDistanceTreeMenuItem);
-    calculateTree.add(neighbourTreeMenuItem);
-    calculateTree.add(avDistanceTreeBlosumMenuItem);
-    calculateTree.add(njTreeBlosumMenuItem);
     jMenu2.add(htmlMenuItem);
     jMenu2.add(epsFile);
     jMenu2.add(createPNG);
@@ -1976,6 +2001,7 @@ public class GAlignFrame extends JInternalFrame
     selectMenu.add(unGroup);
     selectMenu.add(grpsFromSelection);
     selectMenu.add(deleteGroups);
+    calculateMenu.add(expandAlignment);
     // TODO - determine if the listenToViewSelections button is needed : see bug
     // JAL-574
     // selectMenu.addSeparator();
@@ -2295,6 +2321,11 @@ public class GAlignFrame extends JInternalFrame
   protected void purinePyrimidineColour_actionPerformed(ActionEvent e)
   {
   }
+  
+  protected void RNAInteractionColour_actionPerformed(ActionEvent e)
+  {
+  }
+  
 
   /*
    * protected void covariationColour_actionPerformed(ActionEvent e) { }
@@ -2616,4 +2647,10 @@ public class GAlignFrame extends JInternalFrame
   {
 
   }
+
+  protected void expand_newalign(ActionEvent e)
+  {
+    // TODO Auto-generated method stub
+    
+  }
 }