Jalview.isJS() --> Platform.isJS(), DBRefEntry[] --> List<DBRefEntry>
[jalview.git] / src / jalview / gui / OverviewCanvas.java
index ec2c49f..ca27a9c 100644 (file)
@@ -181,7 +181,7 @@ public class OverviewCanvas extends JPanel
   @Override
   public void paintComponent(Graphics g)
   {
-    super.paintComponent(g);
+    //super.paintComponent(g);
 
     if (restart)
     {
@@ -206,7 +206,9 @@ public class OverviewCanvas extends JPanel
       {
         // if there is annotation, scale the alignment and annotation
         // separately
-        if (od.getGraphHeight() > 0)
+        if (od.getGraphHeight() > 0 
+                       && od.getSequencesHeight() > 0  // BH 2019
+                       )
         {
           BufferedImage topImage = lastMiniMe.getSubimage(0, 0,
                   od.getWidth(), od.getSequencesHeight());
@@ -257,6 +259,7 @@ public class OverviewCanvas extends JPanel
   public void dispose()
   {
     dispose = true;
+    od = null;
     synchronized (this)
     {
       restart = true;