X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=src%2Fjalview%2Fgui%2FStructureChooser.java;fp=src%2Fjalview%2Fgui%2FStructureChooser.java;h=358412d81f5efeb19e3ec00262245533c009ba1b;hb=9e8c6798b524aa8743c271a3115f6cb307eb83ea;hp=cd4faf62f691dcba35feb23e7b5dbbe0b79b2fe2;hpb=e6139c0f78da30cdf0dabb986706f3a2110c02fc;p=jalview.git diff --git a/src/jalview/gui/StructureChooser.java b/src/jalview/gui/StructureChooser.java index cd4faf6..358412d 100644 --- a/src/jalview/gui/StructureChooser.java +++ b/src/jalview/gui/StructureChooser.java @@ -179,6 +179,7 @@ public class StructureChooser extends GStructureChooser DefaultTableModel tableModel = new DefaultTableModel(); tableModel.addColumn("Sequence"); tableModel.addColumn("PDB Id"); + tableModel.addColumn("Chain"); tableModel.addColumn("Type"); tableModel.addColumn("File"); cachedEntryMap = new Hashtable(); @@ -189,8 +190,12 @@ public class StructureChooser extends GStructureChooser { for (PDBEntry pdbEntry : seq.getDatasetSequence().getPDBId()) { + String chain = pdbEntry.getChainCode() == null ? "_" : pdbEntry + .getChainCode(); String[] pdbEntryRowData = new String[] - { seq.getDisplayId(false), pdbEntry.getId(), pdbEntry.getType(), + { seq.getDisplayId(false), pdbEntry.getId(), + chain, + pdbEntry.getType(), pdbEntry.getFile() }; tableModel.addRow(pdbEntryRowData); cachedEntryMap.put(seq.getDisplayId(false) + pdbEntry.getId(), @@ -217,7 +222,7 @@ public class StructureChooser extends GStructureChooser { PDBEntry newEntry = new PDBEntry(); newEntry.setId(response.getPdbId()); - newEntry.setType("PDB"); + newEntry.setType(PDBEntry.Type.PDB); seq.getDatasetSequence().addPDBId(newEntry); } } @@ -597,7 +602,7 @@ public class StructureChooser extends GStructureChooser .toString(); PDBEntry pdbEntry = new PDBEntry(); pdbEntry.setId(pdbIdStr); - pdbEntry.setType("PDB"); + pdbEntry.setType(PDBEntry.Type.PDB); pdbEntriesToView[count++] = pdbEntry; } @@ -626,7 +631,7 @@ public class StructureChooser extends GStructureChooser } PDBEntry pdbEntry = new PDBEntry(); pdbEntry.setId(txt_search.getText()); - pdbEntry.setType("PDB"); + pdbEntry.setType(PDBEntry.Type.PDB); selectedSequence.getDatasetSequence().addPDBId(pdbEntry); PDBEntry[] pdbEntriesToView = new PDBEntry[] { pdbEntry };