JAL-3878 Create web service class - container for service metadata and actions
[jalview.git] / src / jalview / gui / SeqPanel.java
index b2149df..fdb75a4 100644 (file)
@@ -243,6 +243,7 @@ public class SeqPanel extends JPanel
    */
   public SeqPanel(AlignViewport viewport, AlignmentPanel alignPanel)
   {
+    setName("SeqPanel");
     seqARep = new SequenceAnnotationReport(true);
     ToolTipManager.sharedInstance().registerComponent(this);
     ToolTipManager.sharedInstance().setInitialDelay(0);
@@ -291,8 +292,7 @@ public class SeqPanel extends JPanel
     int alignmentHeight = av.getAlignment().getHeight();
     if (av.getWrapAlignment())
     {
-      seqCanvas.calculateWrappedGeometry(seqCanvas.getWidth(),
-              seqCanvas.getHeight());
+      seqCanvas.calculateWrappedGeometry();
 
       /*
        * yPos modulo height of repeating width
@@ -424,8 +424,7 @@ public class SeqPanel extends JPanel
       if (editCommand != null && editCommand.getSize() > 0)
       {
         ap.alignFrame.addHistoryItem(editCommand);
-        av.firePropertyChange("alignment", null,
-                av.getAlignment().getSequences());
+        ap.av.notifyAlignment();
       }
     } finally
     {
@@ -1142,7 +1141,8 @@ public class SeqPanel extends JPanel
 
     String tooltip = AnnotationPanel.buildToolTip(anns[rowIndex], column,
             anns);
-    if (!tooltip.equals(lastTooltip))
+    boolean tooltipChanged = tooltip == null ? lastTooltip != null : !tooltip.equals(lastTooltip);
+    if (tooltipChanged)
     {
       lastTooltip = tooltip;
       lastFormattedTooltip = tooltip == null ? null