Set<String> calcIdSet = new HashSet<String>();
// SAVE SEQUENCES
- for (int i = 0; i < rjal.getHeight(); i++)
+ for (final SequenceI jds : rjal.getSequences())
{
- final SequenceI jds = rjal.getSequenceAt(i);
final SequenceI jdatasq = jds.getDatasetSequence() == null ? jds
: jds.getDatasetSequence();
String id = seqHash(jds);
jseq.setHidden(av.getAlignment().getHiddenSequences()
.isHidden(jds));
- if (av.isHiddenRepSequence(rjal.getSequenceAt(i)))
+ if (av.isHiddenRepSequence(jds))
{
jalview.datamodel.SequenceI[] reps = av
- .getRepresentedSequences(rjal.getSequenceAt(i))
+ .getRepresentedSequences(jds)
.getSequencesInOrder(rjal);
for (int h = 0; h < reps.length; h++)
{
- if (reps[h] != rjal.getSequenceAt(i))
+ if (reps[h] != jds)
{
jseq.addHiddenSequences(rjal.findIndex(reps[h]));
}
// mark sequence as reference - if it is the reference for this view
if (jal.hasSeqrep())
{
- jseq.setViewreference(rjal.getSequenceAt(i) == jal.getSeqrep());
+ jseq.setViewreference(jds == jal.getSeqrep());
}
}