JAL-3056 no Save/Load colours xml in JalviewJS
authorgmungoc <g.m.carstairs@dundee.ac.uk>
Tue, 14 Aug 2018 10:04:02 +0000 (11:04 +0100)
committergmungoc <g.m.carstairs@dundee.ac.uk>
Tue, 14 Aug 2018 10:04:02 +0000 (11:04 +0100)
src/jalview/gui/FeatureSettings.java

index 37258e4..2512a1b 100644 (file)
@@ -22,6 +22,7 @@ package jalview.gui;
 
 import jalview.api.FeatureColourI;
 import jalview.api.FeatureSettingsControllerI;
+import jalview.bin.Jalview;
 import jalview.datamodel.AlignmentI;
 import jalview.datamodel.SequenceI;
 import jalview.datamodel.features.FeatureMatcher;
@@ -44,6 +45,7 @@ import java.awt.BorderLayout;
 import java.awt.Color;
 import java.awt.Component;
 import java.awt.Dimension;
+import java.awt.FlowLayout;
 import java.awt.Font;
 import java.awt.Graphics;
 import java.awt.GridLayout;
@@ -1348,8 +1350,14 @@ public class FeatureSettings extends JPanel
     JPanel buttonPanel = new JPanel();
     buttonPanel.add(ok);
     buttonPanel.add(cancel);
-    buttonPanel.add(loadColours);
-    buttonPanel.add(saveColours);
+    if (!Jalview.isJS())
+    {
+      /*
+       * no save/load XML in JalviewJS for now
+       */
+      buttonPanel.add(loadColours);
+      buttonPanel.add(saveColours);
+    }
     bigPanel.add(scrollPane, BorderLayout.CENTER);
     settingsPane.add(bigPanel, BorderLayout.CENTER);
     settingsPane.add(buttonPanel, BorderLayout.SOUTH);