JAL-1486 JAL-1543 pushed alignment viewport->view->flat file logic into jalview.io...
[jalview.git] / src / jalview / gui / PopupMenu.java
index e84a799..0957d28 100644 (file)
@@ -2109,20 +2109,7 @@ public class PopupMenu extends JPopupMenu
     // or we simply trust the user wants
     // wysiwig behaviour
 
-    AlignmentView selvew = ap.av.getAlignmentView(true, false);
-    AlignmentI aselview = selvew.getVisibleAlignment(ap.av
-            .getGapCharacter());
-    List<AlignmentAnnotation> ala = (ap.av
-            .getVisibleAlignmentAnnotation(true));
-    if (ala != null)
-    {
-      for (AlignmentAnnotation aa : ala)
-      {
-        aselview.addAnnotation(aa);
-      }
-    }
-    cap.setText(new FormatAdapter().formatSequences(e.getActionCommand(),
-            aselview, null, null, null));
+    cap.setText(new FormatAdapter().formatSequences(e.getActionCommand(), ap.av, true));
   }
 
   public void pdbFromFile_actionPerformed()