X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=src%2Fjalview%2Fdatamodel%2FAlignedCodonFrame.java;h=6faf7a69179a11f7a6a83c058b93bb52dcef8f6a;hb=9c16178c0601ea3169d7a5d5d623dafa45c54f85;hp=6e83fbb7d262331d3dff05336b5c939a50bbe900;hpb=c19ee8bb9c1b1f2b0996522a4935333d43ac9671;p=jalview.git diff --git a/src/jalview/datamodel/AlignedCodonFrame.java b/src/jalview/datamodel/AlignedCodonFrame.java index 6e83fbb..6faf7a6 100644 --- a/src/jalview/datamodel/AlignedCodonFrame.java +++ b/src/jalview/datamodel/AlignedCodonFrame.java @@ -433,7 +433,8 @@ public class AlignedCodonFrame /** * Add search results for regions in other sequences that translate or are - * translated from a particular position in seq + * translated from a particular position in seq (which may be an aligned or + * dataset sequence) * * @param seq * @param index @@ -445,6 +446,10 @@ public class AlignedCodonFrame SearchResultsI results) { SequenceI ds = seq.getDatasetSequence(); + if (ds == null) + { + ds = seq; + } for (SequenceToSequenceMapping ssm : mappings) { ssm.markMappedRegion(ds, index, results); @@ -949,9 +954,9 @@ public class AlignedCodonFrame } /** - * Returns the first mapping found which is between the given sequence and - * another, is a triplet mapping (3:1 or 1:3), and covers the full extent of - * both sequences involved. + * Returns the first mapping found which is between the given dataset sequence + * and another, is a triplet mapping (3:1 or 1:3), and covers the full extent + * of both sequences involved * * @param seq * @return