status = PDBChain.IEASTATUS;
}
SequenceFeature[] features = sequence.getSequenceFeatures();
+ if (features == null)
+ {
+ return null;
+ }
for (int i = 0; i < features.length; i++)
{
if (features[i].getFeatureGroup().equals(pdbid))
ap, true));
}
- public void pdbFromFile_actionPerformed()
- {
- jalview.io.JalviewFileChooser chooser = new jalview.io.JalviewFileChooser(
- jalview.bin.Cache.getProperty("LAST_DIRECTORY"));
- chooser.setFileView(new jalview.io.JalviewFileView());
- chooser.setDialogTitle(MessageManager.formatMessage(
- "label.select_pdb_file_for",
- new Object[] { sequence.getDisplayId(false) }));
- chooser.setToolTipText(MessageManager.formatMessage(
- "label.load_pdb_file_associate_with_sequence",
- new Object[] { sequence.getDisplayId(false) }));
-
- int value = chooser.showOpenDialog(null);
-
- if (value == jalview.io.JalviewFileChooser.APPROVE_OPTION)
- {
- String choice = chooser.getSelectedFile().getPath();
- jalview.bin.Cache.setProperty("LAST_DIRECTORY", choice);
- new AssociatePdbFileWithSeq().associatePdbWithSeq(choice,
- jalview.io.AppletFormatAdapter.FILE, sequence, true,
- Desktop.instance);
- }
-
- }
-
public void enterPDB_actionPerformed()
{
String id = JOptionPane.showInternalInputDialog(Desktop.desktop,