JAL-1691 applet SplitFrame scrolling; pull up of 5 fields to
[jalview.git] / src / jalview / gui / AlignmentPanel.java
index 851c58b..c7ef3ce 100644 (file)
@@ -338,7 +338,7 @@ public class AlignmentPanel extends GAlignmentPanel implements
     // TODO: properly locate search results in view when large numbers of hidden
     // columns exist before highlighted region
     // do we need to scroll the panel?
-    // TODO: tons of nullpointereexceptions raised here.
+    // TODO: tons of nullpointerexceptions raised here.
     if (results != null && results.getSize() > 0 && av != null
             && av.getAlignment() != null)
     {
@@ -814,7 +814,7 @@ public class AlignmentPanel extends GAlignmentPanel implements
     }
     else
     {
-      av.scrollComplementaryAlignment(evt.getSource() == hscroll);
+      av.scrollComplementaryAlignment();
     }
   }
 
@@ -1721,11 +1721,8 @@ public class AlignmentPanel extends GAlignmentPanel implements
    *          'to'; may be modified for sequence offset by this method
    * @param seqOffset
    *          the number of visible sequences to show above the mapped region
-   * @param horizontal
-   *          if true, horizontal scrolling, else vertical
    */
-  public void scrollAsComplement(SearchResults sr, int seqOffset,
-          boolean horizontal)
+  public void scrollToCentre(SearchResults sr, int seqOffset)
   {
     /*
      * To avoid jumpy vertical scrolling (if some sequences are gapped or not
@@ -1759,10 +1756,8 @@ public class AlignmentPanel extends GAlignmentPanel implements
             .setSequence(av.getAlignment().getSequenceAt(sequenceIndex));
 
     /*
-     * Scroll to position but centring the target residue. Also set a state flag
-     * to prevent adjustmentValueChanged performing this recursively.
+     * Scroll to position but centring the target residue.
      */
-    setFollowingComplementScroll(true);
     scrollToPosition(sr, true, true);
   }