// allocate enough slots to store the mapping from positions in
// sequence[s] to the associated chain
- int[][] mapping = new int[maxChain.sequence.getEnd() + 2][2];
+ int[][] mapping = new int[sequence[s].findPosition(sequence[s].getLength()) + 2][2];
int resNum = -10000;
int index = 0;
public void removeStructureViewerListener(Object svl, String[] pdbfiles)
{
listeners.removeElement(svl);
+ if (svl instanceof SequenceListener)
+ {
+ for (int i=0;i<listeners.size();i++)
+ {
+ if (listeners.elementAt(i) instanceof StructureListener)
+ {
+ ((StructureListener)listeners.elementAt(i)).releaseReferences(svl);
+ }
+ }
+ }
+
if (pdbfiles == null)
{
return;