Program: 59170
Project: 59170
Buggy source:
private void renderPathwayPool(final GL gl){
  ArrayList<Integer> alMagnificationFactor=new ArrayList<Integer>();
  for (int i=0; i < alSetData.get(0).getStorageByDimAndIndex(0,0).getSize(StorageType.INT); i++) {
    alMagnificationFactor.add(0);
  }
  IStorage tmpStorage=alSetData.get(0).getStorageByDimAndIndex(0,0);
  int[] iArPathwayIDs=tmpStorage.getArrayInt();
  int iPathwayId=0;
  for (int iPathwayIndex=0; iPathwayIndex < tmpStorage.getSize(StorageType.INT); iPathwayIndex++) {
    iPathwayId=iArPathwayIDs[iPathwayIndex];
    if (iMouseOverPickedPathwayId == iPathwayId) {
      if ((iPathwayIndex - 2 >= 0) && (alMagnificationFactor.get(iPathwayIndex - 2) < 1))       alMagnificationFactor.set(iPathwayIndex - 2,1);
      if ((iPathwayIndex - 1 >= 0) && (alMagnificationFactor.get(iPathwayIndex - 1) < 2))       alMagnificationFactor.set(iPathwayIndex - 1,2);
      alMagnificationFactor.set(iPathwayIndex,3);
      if ((iPathwayIndex + 1 < alMagnificationFactor.size()) && (alMagnificationFactor.get(iPathwayIndex + 1) < 2))       alMagnificationFactor.set(iPathwayIndex + 1,2);
      if ((iPathwayIndex + 2 < alMagnificationFactor.size()) && (alMagnificationFactor.get(iPathwayIndex + 2) < 1))       alMagnificationFactor.set(iPathwayIndex + 2,1);
    }
 else     if (pathwayLayeredLayer.containsElement(iPathwayId) || pathwayUnderInteractionLayer.containsElement(iPathwayId)) {
      alMagnificationFactor.set(iPathwayIndex,2);
    }
 else     if (refHashPathwayContainingSelectedVertex2VertexCount.containsKey(iPathwayId)) {
      alMagnificationFactor.set(iPathwayIndex,1);
    }
  }
  recalculatePathwayPoolTransformation(alMagnificationFactor);
  String sRenderText;
  float fYPos=0;
  for (int iPathwayIndex=0; iPathwayIndex < tmpStorage.getSize(StorageType.INT); iPathwayIndex++) {
    gl.glPushMatrix();
    iPathwayId=iArPathwayIDs[iPathwayIndex];
    gl.glLoadName(iPathwayIndex + 1);
    if (!refHashPoolLinePickId2PathwayId.containsKey(iPathwayIndex + 1))     refHashPoolLinePickId2PathwayId.put(iPathwayIndex + 1,iPathwayId);
    Transform transform=pathwayPoolLayer.getTransformByElementId(iPathwayId);
    Vec3f translation=transform.getTranslation();
    gl.glTranslatef(translation.x(),translation.y(),translation.z());
    sRenderText=((Pathway)refGeneralManager.getSingelton().getPathwayManager().getItem(iPathwayId)).getTitle();
    if (refHashPathwayContainingSelectedVertex2VertexCount.containsKey(iPathwayId)) {
      sRenderText=sRenderText + "String_Node_Str" + refHashPathwayContainingSelectedVertex2VertexCount.get(iPathwayId).toString();
    }
    if (pathwayUnderInteractionLayer.containsElement(iPathwayId))     gl.glColor4f(1,0,0,1);
 else     gl.glColor4f(0,0,0,1);
    if (alMagnificationFactor.get(iPathwayIndex) == 3) {
      GLTextUtils.renderText(gl,sRenderText,18,0,0.06f,1);
      fYPos=0.15f;
    }
 else     if (alMagnificationFactor.get(iPathwayIndex) == 2) {
      GLTextUtils.renderText(gl,sRenderText,12,0,0.04f,1);
      fYPos=0.1f;
    }
 else     if (alMagnificationFactor.get(iPathwayIndex) == 1) {
      GLTextUtils.renderText(gl,sRenderText,10,0,0.02f,1);
      fYPos=0.07f;
    }
 else     if (alMagnificationFactor.get(iPathwayIndex) == 0) {
      fYPos=0.02f;
      gl.glColor3f(0,0,0);
      gl.glBegin(GL.GL_QUADS);
      gl.glVertex3f(0,0,0);
      gl.glVertex3f(0,fYPos,0);
      gl.glVertex3f(0.1f,fYPos,0);
      gl.glVertex3f(0.1f,0,0);
      gl.glEnd();
    }
    gl.glColor4f(0,0,0,0);
    gl.glBegin(GL.GL_QUADS);
    gl.glVertex3f(0,0,0.1f);
    gl.glVertex3f(0,fYPos,0.1f);
    gl.glVertex3f(0.5f,fYPos,0.1f);
    gl.glVertex3f(0.5f,0,0.1f);
    gl.glEnd();
    gl.glPopMatrix();
  }
}

Fixed version (ground truth):
private void renderPathwayPool(final GL gl){
  ArrayList<Integer> alMagnificationFactor=new ArrayList<Integer>();
  for (int i=0; i < alSetData.get(0).getStorageByDimAndIndex(0,0).getSize(StorageType.INT); i++) {
    alMagnificationFactor.add(0);
  }
  IStorage tmpStorage=alSetData.get(0).getStorageByDimAndIndex(0,0);
  int[] iArPathwayIDs=tmpStorage.getArrayInt();
  int iPathwayId=0;
  for (int iPathwayIndex=0; iPathwayIndex < tmpStorage.getSize(StorageType.INT); iPathwayIndex++) {
    iPathwayId=iArPathwayIDs[iPathwayIndex];
    if (iMouseOverPickedPathwayId == iPathwayId) {
      if ((iPathwayIndex - 2 >= 0) && (alMagnificationFactor.get(iPathwayIndex - 2) < 1)) {
        alMagnificationFactor.set(iPathwayIndex - 2,1);
      }
      if ((iPathwayIndex - 1 >= 0) && (alMagnificationFactor.get(iPathwayIndex - 1) < 2)) {
        alMagnificationFactor.set(iPathwayIndex - 1,2);
      }
      alMagnificationFactor.set(iPathwayIndex,3);
      if ((iPathwayIndex + 1 < alMagnificationFactor.size()) && (alMagnificationFactor.get(iPathwayIndex + 1) < 2)) {
        alMagnificationFactor.set(iPathwayIndex + 1,2);
      }
      if ((iPathwayIndex + 2 < alMagnificationFactor.size()) && (alMagnificationFactor.get(iPathwayIndex + 2) < 1)) {
        alMagnificationFactor.set(iPathwayIndex + 2,1);
      }
    }
 else     if (pathwayLayeredLayer.containsElement(iPathwayId) || pathwayUnderInteractionLayer.containsElement(iPathwayId)) {
      alMagnificationFactor.set(iPathwayIndex,2);
    }
 else     if (refHashPathwayContainingSelectedVertex2VertexCount.containsKey(iPathwayId)) {
      alMagnificationFactor.set(iPathwayIndex,1);
    }
  }
  recalculatePathwayPoolTransformation(alMagnificationFactor);
  String sRenderText;
  float fYPos=0;
  for (int iPathwayIndex=0; iPathwayIndex < tmpStorage.getSize(StorageType.INT); iPathwayIndex++) {
    gl.glPushMatrix();
    iPathwayId=iArPathwayIDs[iPathwayIndex];
    gl.glLoadName(iPathwayIndex + 1);
    if (!refHashPoolLinePickId2PathwayId.containsKey(iPathwayIndex + 1))     refHashPoolLinePickId2PathwayId.put(iPathwayIndex + 1,iPathwayId);
    Transform transform=pathwayPoolLayer.getTransformByElementId(iPathwayId);
    Vec3f translation=transform.getTranslation();
    gl.glTranslatef(translation.x(),translation.y(),translation.z());
    sRenderText=((Pathway)refGeneralManager.getSingelton().getPathwayManager().getItem(iPathwayId)).getTitle();
    if (refHashPathwayContainingSelectedVertex2VertexCount.containsKey(iPathwayId)) {
      sRenderText=sRenderText + "String_Node_Str" + refHashPathwayContainingSelectedVertex2VertexCount.get(iPathwayId).toString();
    }
    if (pathwayUnderInteractionLayer.containsElement(iPathwayId))     gl.glColor4f(1,0,0,1);
 else     gl.glColor4f(0,0,0,1);
    if (alMagnificationFactor.get(iPathwayIndex) == 3) {
      GLTextUtils.renderText(gl,sRenderText,18,0,0.06f,0);
      fYPos=0.15f;
    }
 else     if (alMagnificationFactor.get(iPathwayIndex) == 2) {
      GLTextUtils.renderText(gl,sRenderText,12,0,0.04f,0);
      fYPos=0.1f;
    }
 else     if (alMagnificationFactor.get(iPathwayIndex) == 1) {
      GLTextUtils.renderText(gl,sRenderText,10,0,0.02f,0);
      fYPos=0.07f;
    }
 else     if (alMagnificationFactor.get(iPathwayIndex) == 0) {
      fYPos=0.02f;
      gl.glColor3f(0,0,0);
      gl.glBegin(GL.GL_QUADS);
      gl.glVertex3f(0,0,0);
      gl.glVertex3f(0,fYPos,0);
      gl.glVertex3f(0.1f,fYPos,0);
      gl.glVertex3f(0.1f,0,0);
      gl.glEnd();
    }
    gl.glColor4f(0,0,0,0);
    gl.glBegin(GL.GL_QUADS);
    gl.glVertex3f(0,0,0.1f);
    gl.glVertex3f(0,fYPos,0.1f);
    gl.glVertex3f(0.5f,fYPos,0.1f);
    gl.glVertex3f(0.5f,0,0.1f);
    gl.glEnd();
    gl.glPopMatrix();
  }
}