JAL-1641 Further refactoring of JSON export option, introduction of Viewport to the...
[jalview.git] / src / jalview / io / FormatAdapter.java
index 86ec140..7c117b9 100755 (executable)
@@ -37,10 +37,20 @@ import jalview.datamodel.SequenceI;
  */
 public class FormatAdapter extends AppletFormatAdapter
 {
+  public FormatAdapter(AlignViewportI viewport)
+  {
+    super(viewport);
+    init();
+  }
 
   public FormatAdapter()
   {
     super();
+    init();
+  }
+
+  private void init()
+  {
     if (jalview.bin.Cache.getDefault("STRUCT_FROM_PDB", true))
     {
       annotFromStructure = jalview.bin.Cache.getDefault("ADD_TEMPFACT_ANN",
@@ -58,6 +68,7 @@ public class FormatAdapter extends AppletFormatAdapter
       serviceSecondaryStruct = false;
     }
   }
+
   public String formatSequences(String format, SequenceI[] seqs,
           String[] omitHiddenColumns)
   {