JAL-4155 Replace unsafe casting to AlignmentPanel with generics
[jalview.git] / src / jalview / gui / AlignViewport.java
index 944bb6b..4b4e82a 100644 (file)
@@ -79,7 +79,7 @@ import jalview.ws.params.AutoCalcSetting;
  * @author $author$
  * @version $Revision: 1.141 $
  */
-public class AlignViewport extends AlignmentViewport
+public class AlignViewport extends AlignmentViewport<AlignmentPanel>
         implements SelectionSource
 {
   Font font;
@@ -524,7 +524,6 @@ public class AlignViewport extends AlignmentViewport
                     new HiddenColumns(getAlignment().getHiddenColumns()),
                     this);
   }
-
   
   public boolean getSortByTree()
   {
@@ -535,19 +534,7 @@ public class AlignViewport extends AlignmentViewport
   {
     sortByTree = sort;
   }
-  /**
-   * return the alignPanel containing the given viewport. Use this to get the
-   * components currently handling the given viewport.
-   * 
-   * @param av
-   * @return null or an alignPanel guaranteed to have non-null alignFrame
-   *         reference
-   */
-  
-  public AlignmentPanel getAlignPanel()
-  {
-    return (AlignmentPanel) alignPanel;
-  }
+
   /**
    * Returns the (Desktop) instance of the StructureSelectionManager
    */