JAL-4036 Don't autosearch changing index when autosearch is de-selected
authorBen Soares <b.soares@dundee.ac.uk>
Thu, 21 Jul 2022 20:00:49 +0000 (21:00 +0100)
committerBen Soares <b.soares@dundee.ac.uk>
Thu, 21 Jul 2022 20:00:49 +0000 (21:00 +0100)
src/jalview/fts/core/GFTSPanel.java

index ea206e9..f73d430 100644 (file)
 
 package jalview.fts.core;
 
-import jalview.bin.Cache;
-import jalview.fts.api.FTSDataColumnI;
-import jalview.fts.api.GFTSPanelI;
-import jalview.fts.core.FTSDataColumnPreferences.PreferenceSource;
-import jalview.gui.Desktop;
-import jalview.gui.IProgressIndicator;
-import jalview.gui.JvSwingUtils;
-import jalview.gui.SequenceFetcher;
-import jalview.io.cache.JvCacheableInputBox;
-import jalview.util.MessageManager;
-import jalview.util.Platform;
-
 import java.awt.BorderLayout;
 import java.awt.CardLayout;
 import java.awt.Dimension;
@@ -77,6 +65,18 @@ import javax.swing.event.InternalFrameEvent;
 import javax.swing.table.DefaultTableModel;
 import javax.swing.table.TableColumn;
 
+import jalview.bin.Cache;
+import jalview.fts.api.FTSDataColumnI;
+import jalview.fts.api.GFTSPanelI;
+import jalview.fts.core.FTSDataColumnPreferences.PreferenceSource;
+import jalview.gui.Desktop;
+import jalview.gui.IProgressIndicator;
+import jalview.gui.JvSwingUtils;
+import jalview.gui.SequenceFetcher;
+import jalview.io.cache.JvCacheableInputBox;
+import jalview.util.MessageManager;
+import jalview.util.Platform;
+
 /**
  * This class provides the swing GUI layout for FTS Panel and implements most of
  * the contracts defined in GFSPanelI
@@ -544,7 +544,8 @@ public abstract class GFTSPanel extends JPanel implements GFTSPanelI
           }
           txt_search.getComponent().setToolTipText(
                   JvSwingUtils.wrapTooltip(true, tooltipText));
-          searchAction(true);
+          if (btn_autosearch.isSelected())
+            searchAction(true);
         }
       }
     });