JAL-1919 Fixed failing tests, enabled HETATM processing from structure file to be...
[jalview.git] / src / MCview / PDBfile.java
index 9a9b6f6..9acc2e7 100755 (executable)
@@ -25,6 +25,7 @@ import jalview.datamodel.DBRefSource;
 import jalview.datamodel.SequenceI;
 import jalview.io.FileParse;
 import jalview.io.StructureFile;
+import jalview.structure.StructureImportSettings;
 import jalview.util.MessageManager;
 
 import java.io.IOException;
@@ -46,10 +47,10 @@ public class PDBfile extends StructureFile
   }
 
   public PDBfile(boolean addAlignmentAnnotations, boolean predictSecStr,
-          boolean externalSecStr, String file, String protocol)
+          boolean externalSecStr, String dataObject, String protocol)
           throws IOException
   {
-    super(false, file, protocol);
+    super(false, dataObject, protocol);
     addSettings(addAlignmentAnnotations, predictSecStr, externalSecStr);
     doParse();
   }
@@ -131,7 +132,8 @@ public class PDBfile extends StructureFile
           break;
         }
         if (line.indexOf("ATOM") == 0
-                || (line.indexOf("HETATM") == 0 && !terFlag))
+                || (StructureImportSettings.isProcessHETATMs()
+                        && line.indexOf("HETATM") == 0 && !terFlag))
         {
           terFlag = false;