JAL-3814 NONEWS property
[jalview.git] / src / jalview / gui / FeatureRenderer.java
index c2a84c6..e22f506 100644 (file)
@@ -21,9 +21,6 @@
 package jalview.gui;
 
 import jalview.api.FeatureColourI;
-import jalview.datamodel.AlignedCodonFrame;
-import jalview.datamodel.Mapping;
-import jalview.datamodel.SearchResultMatchI;
 import jalview.datamodel.SearchResults;
 import jalview.datamodel.SearchResultsI;
 import jalview.datamodel.SequenceFeature;
@@ -272,8 +269,8 @@ public class FeatureRenderer
             name.setText(sf.getType());
             description.setText(sf.getDescription());
             group.setText(sf.getFeatureGroup());
-            start.setValue(new Integer(sf.getBegin()));
-            end.setValue(new Integer(sf.getEnd()));
+            start.setValue(Integer.valueOf(sf.getBegin()));
+            end.setValue(Integer.valueOf(sf.getEnd()));
 
             SearchResultsI highlight = new SearchResults();
             highlight.addResult(sequences.get(0), sf.getBegin(),
@@ -360,8 +357,8 @@ public class FeatureRenderer
     name.setText(featureType);
     group.setText(featureGroup);
 
-    start.setValue(new Integer(firstFeature.getBegin()));
-    end.setValue(new Integer(firstFeature.getEnd()));
+    start.setValue(Integer.valueOf(firstFeature.getBegin()));
+    end.setValue(Integer.valueOf(firstFeature.getEnd()));
     description.setText(firstFeature.getDescription());
     updateColourButton(mainPanel, colour,
             (oldcol = fcol = getFeatureStyle(featureType)));
@@ -577,49 +574,4 @@ public class FeatureRenderer
   {
     Arrays.sort(renderOrder, order);
   }
-
-  /**
-   * Answers a (possibly empty) list of features in this alignment at a position
-   * (or range) which is mappable from the given sequence residue position in a
-   * mapped alignment.
-   * 
-   * @param sequence
-   * @param pos
-   * @return
-   */
-  public List<SequenceFeature> findComplementFeaturesAtResidue(
-          SequenceI sequence, int pos)
-  {
-    SequenceI ds = sequence.getDatasetSequence();
-    List<SequenceFeature> result = new ArrayList<>();
-    List<AlignedCodonFrame> mappings = this.av.getAlignment()
-            .getCodonFrame(sequence);
-    for (AlignedCodonFrame acf : mappings)
-    {
-      Mapping mapping = acf.getMappingForSequence(sequence);
-      if (mapping.getMap().getFromRatio() == mapping.getMap().getToRatio())
-      {
-        continue; // we are only looking for 3:1 or 1:3 mappings
-      }
-      SearchResultsI sr = new SearchResults();
-      acf.markMappedRegion(ds, pos, sr);
-      for (SearchResultMatchI match : sr.getResults())
-      {
-        for (int i = match.getStart(); i <= match.getEnd(); i++)
-        {
-          List<SequenceFeature> fs = findFeaturesAtResidue(
-                  match.getSequence(), i);
-          for (SequenceFeature sf : fs)
-          {
-            if (!result.contains(sf))
-            {
-              result.addAll(fs);
-            }
-          }
-        }
-      }
-    }
-    
-    return result;
-  }
 }