layout the menu with a minimum number of host labels
authorjprocter <Jim Procter>
Mon, 20 Sep 2010 08:57:28 +0000 (08:57 +0000)
committerjprocter <Jim Procter>
Mon, 20 Sep 2010 08:57:28 +0000 (08:57 +0000)
src/jalview/ws/jws2/Jws2Discoverer.java

index 1f3eee9..d9b72ff 100644 (file)
@@ -405,6 +405,7 @@ public class Jws2Discoverer implements Runnable, WSMenuEntryProviderI
         }
       }
       if (!byhost && !hostLabels.contains(host + service.serviceType+service.getActionText()))
+              //!hostLabels.contains(host + (bytype ? service.serviceType+service.getActionText() : "")))
       {
         // add a marker indicating where this service is hosted
         // relies on services from the same host being listed in a contiguous
@@ -415,8 +416,10 @@ public class Jws2Discoverer implements Runnable, WSMenuEntryProviderI
         {
           atpoint.add(hitm = new JMenuItem(host));
           hitm.setForeground(Color.blue);
+          lasthost = host;
         }
-        hostLabels.addElement(host + service.serviceType+service.getActionText());
+        hostLabels.addElement(host + service.serviceType+service.getActionText() );
+        // hostLabels.addElement(host + (bytype ? service.serviceType+service.getActionText() : ""));
       }
       msacl.attachWSMenuEntry(atpoint, service, alignFrame);
       /*