JAL-1713 fix typo; overview in project with open overview in preferences
authorgmungoc <g.m.carstairs@dundee.ac.uk>
Fri, 11 Dec 2020 07:51:51 +0000 (07:51 +0000)
committergmungoc <g.m.carstairs@dundee.ac.uk>
Fri, 11 Dec 2020 07:51:51 +0000 (07:51 +0000)
src/jalview/gui/AlignFrame.java
src/jalview/renderer/OverviewResColourFinder.java

index 2c079b8..6916a55 100644 (file)
@@ -3375,11 +3375,6 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
   @Override
   public void overviewMenuItem_actionPerformed(ActionEvent e)
   {
-    if (alignPanel.overviewPanel != null)
-    {
-      return;
-    }
-
     boolean showHiddenRegions = Cache.getDefault(Preferences.SHOW_OV_HIDDEN_AT_START,
                 false);
     openOverviewPanel(showHiddenRegions);
@@ -3387,6 +3382,10 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
 
   public OverviewPanel openOverviewPanel(boolean showHidden)
   {
+    if (alignPanel.overviewPanel != null)
+    {
+      return alignPanel.overviewPanel;
+    }
     JInternalFrame frame = new JInternalFrame();
     final OverviewPanel overview = new OverviewPanel(alignPanel, showHidden);
     frame.setContentPane(overview);
index 89dc9e7..ef4d04b 100644 (file)
@@ -152,6 +152,6 @@ public class OverviewResColourFinder extends ResidueColourFinder
    */
   public Color getResidueColour()
   {
-    return gapColour;
+    return residueColour;
   }
 }