Author: rozagh
Date: 2012-04-27 16:16:06 -0700 (Fri, 27 Apr 2012)
New Revision: 29036

Modified:
   
core3/api/trunk/work-api/src/main/java/org/cytoscape/work/ServiceProperties.java
   
core3/impl/trunk/command-executor-impl/src/main/java/org/cytoscape/command/internal/CyActivator.java
   
core3/impl/trunk/core-task-impl/src/main/java/org/cytoscape/task/internal/CyActivator.java
   
core3/impl/trunk/ding-impl/ding-presentation-impl/src/main/java/org/cytoscape/ding/CyActivator.java
   
core3/impl/trunk/editor-impl/src/main/java/org/cytoscape/editor/internal/CyActivator.java
   
core3/impl/trunk/group-view-impl/src/main/java/org/cytoscape/group/view/internal/CyActivator.java
   
core3/impl/trunk/layout-cytoscape-impl/src/main/java/csapps/layout/CyActivator.java
   
core3/impl/trunk/layout-impl/src/main/java/org/cytoscape/view/layout/internal/CyActivator.java
   
core3/impl/trunk/layout-jgraph-impl/src/main/java/csapps/layout/CyActivator.java
   
core3/impl/trunk/layout-prefuse-impl/src/main/java/org/cytoscape/prefuse/layouts/internal/CyActivator.java
   
core3/impl/trunk/log-swing-impl/src/main/java/org/cytoscape/log/internal/CyActivator.java
   
core3/impl/trunk/swing-application-impl/src/main/java/org/cytoscape/internal/CyActivator.java
   
core3/support/trunk/task-testing-impl/src/main/java/org/cytoscape/internal/test/CyActivator.java
Log:
fixes #820

Modified: 
core3/api/trunk/work-api/src/main/java/org/cytoscape/work/ServiceProperties.java
===================================================================
--- 
core3/api/trunk/work-api/src/main/java/org/cytoscape/work/ServiceProperties.java
    2012-04-27 23:04:15 UTC (rev 29035)
+++ 
core3/api/trunk/work-api/src/main/java/org/cytoscape/work/ServiceProperties.java
    2012-04-27 23:16:06 UTC (rev 29036)
@@ -85,4 +85,9 @@
         * flag is set to true
         */
        public static final String IN_NETWORK_PANEL_CONTEXT_MENU = 
"inNetworkPanelContextMenu";
+       
+       /**
+        * Preferred action properties. 
+        */
+       public static final String PREFERRED_ACTION = "preferredAction";
 }

Modified: 
core3/impl/trunk/command-executor-impl/src/main/java/org/cytoscape/command/internal/CyActivator.java
===================================================================
--- 
core3/impl/trunk/command-executor-impl/src/main/java/org/cytoscape/command/internal/CyActivator.java
        2012-04-27 23:04:15 UTC (rev 29035)
+++ 
core3/impl/trunk/command-executor-impl/src/main/java/org/cytoscape/command/internal/CyActivator.java
        2012-04-27 23:16:06 UTC (rev 29036)
@@ -19,6 +19,7 @@
 
 import java.io.File;
 import java.net.URL;
+import static org.cytoscape.work.ServiceProperties.*;
 
 public class CyActivator extends AbstractCyActivator {
        public CyActivator() {
@@ -36,8 +37,8 @@
                
                
                Properties commandExecutorTaskFactoryProps = new Properties();
-               
commandExecutorTaskFactoryProps.setProperty("preferredMenu","Tools");
-               commandExecutorTaskFactoryProps.setProperty("title","Run 
Commands...");
+               
commandExecutorTaskFactoryProps.setProperty(PREFERRED_MENU,"Tools");
+               commandExecutorTaskFactoryProps.setProperty(TITLE,"Run 
Commands...");
                
registerService(bc,commandExecutorTaskFactory,TaskFactory.class, 
commandExecutorTaskFactoryProps);
 
                
registerServiceListener(bc,commandExecutorImpl,"addTaskFactory","removeTaskFactory",TaskFactory.class);

Modified: 
core3/impl/trunk/core-task-impl/src/main/java/org/cytoscape/task/internal/CyActivator.java
===================================================================
--- 
core3/impl/trunk/core-task-impl/src/main/java/org/cytoscape/task/internal/CyActivator.java
  2012-04-27 23:04:15 UTC (rev 29035)
+++ 
core3/impl/trunk/core-task-impl/src/main/java/org/cytoscape/task/internal/CyActivator.java
  2012-04-27 23:16:06 UTC (rev 29036)
@@ -907,7 +907,7 @@
                groupNodesTaskFactoryProps.setProperty(PREFERRED_MENU,"Groups");
                groupNodesTaskFactoryProps.setProperty(TITLE,"Group Selected 
Nodes");
                groupNodesTaskFactoryProps.setProperty(TOOLTIP,"Group Selected 
Nodes Together");
-               groupNodesTaskFactoryProps.setProperty("preferredAction", 
"NEW");
+               groupNodesTaskFactoryProps.setProperty(PREFERRED_ACTION, "NEW");
                groupNodesTaskFactoryProps.setProperty(COMMAND, 
"group-selected-nodes");
                groupNodesTaskFactoryProps.setProperty(COMMAND_NAMESPACE, 
"network-view");
                
registerService(bc,groupNodesTaskFactory,NetworkViewTaskFactory.class, 
groupNodesTaskFactoryProps);
@@ -919,7 +919,7 @@
                
unGroupNodesTaskFactoryProps.setProperty(PREFERRED_MENU,"Groups");
                unGroupNodesTaskFactoryProps.setProperty(TITLE,"Ungroup 
Selected Nodes");
                unGroupNodesTaskFactoryProps.setProperty(TOOLTIP,"Ungroup 
Selected Nodes");
-               unGroupNodesTaskFactoryProps.setProperty("preferredAction", 
"NEW");
+               unGroupNodesTaskFactoryProps.setProperty(PREFERRED_ACTION, 
"NEW");
                unGroupNodesTaskFactoryProps.setProperty(COMMAND, 
"ungroup-selected-nodes");
                groupNodesTaskFactoryProps.setProperty(COMMAND_NAMESPACE, 
"network-view");
                
registerService(bc,unGroupTaskFactory,NetworkViewTaskFactory.class, 
unGroupNodesTaskFactoryProps);
@@ -931,7 +931,7 @@
                
collapseGroupTaskFactoryProps.setProperty(PREFERRED_MENU,"Groups");
                collapseGroupTaskFactoryProps.setProperty(TITLE,"Collapse 
Group");
                collapseGroupTaskFactoryProps.setProperty(TOOLTIP,"Collapse 
Grouped Nodes");
-               collapseGroupTaskFactoryProps.setProperty("preferredAction", 
"NEW");
+               collapseGroupTaskFactoryProps.setProperty(PREFERRED_ACTION, 
"NEW");
                collapseGroupTaskFactoryProps.setProperty(COMMAND, 
"collapse-grouped-nodes");
                collapseGroupTaskFactoryProps.setProperty(COMMAND_NAMESPACE, 
"network-view"); // TODO right namespace?
                
registerService(bc,collapseGroupTaskFactory,NodeViewTaskFactory.class, 
collapseGroupTaskFactoryProps);
@@ -943,7 +943,7 @@
                
expandGroupTaskFactoryProps.setProperty(PREFERRED_MENU,"Groups");
                expandGroupTaskFactoryProps.setProperty(TITLE,"Expand Group");
                expandGroupTaskFactoryProps.setProperty(TOOLTIP,"Expand Group");
-               expandGroupTaskFactoryProps.setProperty("preferredAction", 
"NEW");
+               expandGroupTaskFactoryProps.setProperty(PREFERRED_ACTION, 
"NEW");
                expandGroupTaskFactoryProps.setProperty(COMMAND, 
"expand-group");
                expandGroupTaskFactoryProps.setProperty(COMMAND_NAMESPACE, 
"network-view"); // TODO right namespace
                
registerService(bc,expandGroupTaskFactory,NodeViewTaskFactory.class, 
expandGroupTaskFactoryProps);
@@ -955,7 +955,7 @@
                unGroupTaskFactoryProps.setProperty(PREFERRED_MENU,"Groups");
                unGroupTaskFactoryProps.setProperty(TITLE,"Ungroup Nodes");
                unGroupTaskFactoryProps.setProperty(TOOLTIP,"Ungroup Nodes");
-               unGroupTaskFactoryProps.setProperty("preferredAction", "NEW");
+               unGroupTaskFactoryProps.setProperty(PREFERRED_ACTION, "NEW");
                unGroupTaskFactoryProps.setProperty(COMMAND, "ungroup");
                unGroupTaskFactoryProps.setProperty(COMMAND_NAMESPACE, 
"network-view"); // TODO right namespace
                
registerService(bc,unGroupNodesTaskFactory,NodeViewTaskFactory.class, 
unGroupTaskFactoryProps);

Modified: 
core3/impl/trunk/ding-impl/ding-presentation-impl/src/main/java/org/cytoscape/ding/CyActivator.java
===================================================================
--- 
core3/impl/trunk/ding-impl/ding-presentation-impl/src/main/java/org/cytoscape/ding/CyActivator.java
 2012-04-27 23:04:15 UTC (rev 29035)
+++ 
core3/impl/trunk/ding-impl/ding-presentation-impl/src/main/java/org/cytoscape/ding/CyActivator.java
 2012-04-27 23:16:06 UTC (rev 29036)
@@ -1,7 +1,6 @@
 package org.cytoscape.ding;
 
-import static org.cytoscape.work.ServiceProperties.ID;
-import static org.cytoscape.work.ServiceProperties.TITLE;
+import static org.cytoscape.work.ServiceProperties.*;
 
 import java.net.URL;
 import java.util.Enumeration;
@@ -162,7 +161,7 @@
                registerAllServices(bc, dingNavigationRenderingEngineFactory, 
dingNavigationRenderingEngineFactoryProps);
 
                Properties addEdgeNodeViewTaskFactoryProps = new Properties();
-               addEdgeNodeViewTaskFactoryProps.setProperty("preferredAction", 
"Edge");
+               addEdgeNodeViewTaskFactoryProps.setProperty(PREFERRED_ACTION, 
"Edge");
                addEdgeNodeViewTaskFactoryProps.setProperty(TITLE, "Add Edge");
                registerService(bc, addEdgeNodeViewTaskFactory, 
NodeViewTaskFactory.class, addEdgeNodeViewTaskFactoryProps);
 
@@ -185,17 +184,17 @@
                registerService(bc, dingNetworkViewFactory, 
CyNetworkViewFactory.class, dingNetworkViewFactoryServiceProps);
 
                Properties addImageTaskFactoryProps = new Properties();
-               addImageTaskFactoryProps.setProperty("preferredAction", "NEW");
+               addImageTaskFactoryProps.setProperty(PREFERRED_ACTION, "NEW");
                addImageTaskFactoryProps.setProperty(TITLE, "Add Image");
                registerService(bc, addImageTaskFactory, 
NetworkViewLocationTaskFactory.class, addImageTaskFactoryProps);
 
                Properties addShapeTaskFactoryProps = new Properties();
-               addShapeTaskFactoryProps.setProperty("preferredAction", "NEW");
+               addShapeTaskFactoryProps.setProperty(PREFERRED_ACTION, "NEW");
                addShapeTaskFactoryProps.setProperty(TITLE, "Add Shape");
                registerService(bc, addShapeTaskFactory, 
NetworkViewLocationTaskFactory.class, addShapeTaskFactoryProps);
 
                Properties addTextTaskFactoryProps = new Properties();
-               addTextTaskFactoryProps.setProperty("preferredAction", "NEW");
+               addTextTaskFactoryProps.setProperty(PREFERRED_ACTION, "NEW");
                addTextTaskFactoryProps.setProperty(TITLE, "Add Text");
                registerService(bc, addTextTaskFactory, 
NetworkViewLocationTaskFactory.class, addTextTaskFactoryProps);
 

Modified: 
core3/impl/trunk/editor-impl/src/main/java/org/cytoscape/editor/internal/CyActivator.java
===================================================================
--- 
core3/impl/trunk/editor-impl/src/main/java/org/cytoscape/editor/internal/CyActivator.java
   2012-04-27 23:04:15 UTC (rev 29035)
+++ 
core3/impl/trunk/editor-impl/src/main/java/org/cytoscape/editor/internal/CyActivator.java
   2012-04-27 23:16:06 UTC (rev 29036)
@@ -17,6 +17,7 @@
 import org.cytoscape.view.vizmap.VisualMappingManager;
 import org.osgi.framework.BundleContext;
 
+import static org.cytoscape.work.ServiceProperties.*;
 
 public class CyActivator extends AbstractCyActivator {
        
@@ -40,36 +41,36 @@
                NodeViewTaskFactory goToNestedNetworkTaskFactory = new 
GoToNestedNetworkTaskFactory(cyNetworkManagerServiceRef, 
cyNetworkViewManagerServiceRef, cyApplicationManagerServiceRef, 
createNetworkViewTaskFactoryServiceRef);
                        
                Properties sifInterpreterTaskFactoryProps = new Properties();
-               sifInterpreterTaskFactoryProps.setProperty("enableFor", 
"networkAndView");
+               sifInterpreterTaskFactoryProps.setProperty(ENABLE_FOR, 
"networkAndView");
                // Setting preferredAction to OPEN registers this service for 
double clicks on
                // the network canvas, something we don't want right now for 
this task!
                
//sifInterpreterTaskFactoryProps.setProperty("preferredAction","OPEN");
-               sifInterpreterTaskFactoryProps.setProperty("preferredMenu", 
"Tools");
-               sifInterpreterTaskFactoryProps.setProperty("menuGravity", 
"5.0f");
-               sifInterpreterTaskFactoryProps.setProperty("title", "SIF 
Interpreter");
+               sifInterpreterTaskFactoryProps.setProperty(PREFERRED_MENU, 
"Tools");
+               sifInterpreterTaskFactoryProps.setProperty(MENU_GRAVITY, 
"5.0f");
+               sifInterpreterTaskFactoryProps.setProperty(TITLE, "SIF 
Interpreter");
                registerService(bc, sifInterpreterTaskFactory, 
NetworkViewTaskFactory.class, sifInterpreterTaskFactoryProps);
 
                Properties networkViewLocationTaskFactoryProps = new 
Properties();
-               
networkViewLocationTaskFactoryProps.setProperty("preferredAction", "NEW");
-               networkViewLocationTaskFactoryProps.setProperty("title", "Add 
Node");
+               
networkViewLocationTaskFactoryProps.setProperty(PREFERRED_ACTION, "NEW");
+               networkViewLocationTaskFactoryProps.setProperty(TITLE, "Add 
Node");
                registerService(bc, networkViewLocationTaskFactory, 
NetworkViewLocationTaskFactory.class, networkViewLocationTaskFactoryProps);
 
                Properties addNestedNetworkProps = new Properties();
-               addNestedNetworkProps.setProperty("preferredAction", "NEW");
-               addNestedNetworkProps.setProperty("preferredMenu", "Nested 
Network");
-               addNestedNetworkProps.setProperty("title", "Add Nested 
Network");
+               addNestedNetworkProps.setProperty(PREFERRED_ACTION, "NEW");
+               addNestedNetworkProps.setProperty(PREFERRED_MENU, "Nested 
Network");
+               addNestedNetworkProps.setProperty(TITLE, "Add Nested Network");
                registerService(bc, addNestedNetworkTaskFactory, 
NodeViewTaskFactory.class, addNestedNetworkProps);
 
                Properties deleteNestedNetworkProps = new Properties();
-               deleteNestedNetworkProps.setProperty("preferredAction", "NEW");
-               deleteNestedNetworkProps.setProperty("preferredMenu", "Nested 
Network");
-               deleteNestedNetworkProps.setProperty("title", "Delete Nested 
Network");
+               deleteNestedNetworkProps.setProperty(PREFERRED_ACTION, "NEW");
+               deleteNestedNetworkProps.setProperty(PREFERRED_MENU, "Nested 
Network");
+               deleteNestedNetworkProps.setProperty(TITLE, "Delete Nested 
Network");
                registerService(bc, deleteNestedNetworkTaskFactory, 
NodeViewTaskFactory.class, deleteNestedNetworkProps);
                
                Properties goToNestedNetworkProps = new Properties();
-               goToNestedNetworkProps.setProperty("preferredAction", "NEW");
-               goToNestedNetworkProps.setProperty("preferredMenu", "Nested 
Network");
-               goToNestedNetworkProps.setProperty("title", "Go to Nested 
Network");
+               goToNestedNetworkProps.setProperty(PREFERRED_ACTION, "NEW");
+               goToNestedNetworkProps.setProperty(PREFERRED_MENU, "Nested 
Network");
+               goToNestedNetworkProps.setProperty(TITLE, "Go to Nested 
Network");
                registerService(bc, goToNestedNetworkTaskFactory, 
NodeViewTaskFactory.class, goToNestedNetworkProps);
        }
 }

Modified: 
core3/impl/trunk/group-view-impl/src/main/java/org/cytoscape/group/view/internal/CyActivator.java
===================================================================
--- 
core3/impl/trunk/group-view-impl/src/main/java/org/cytoscape/group/view/internal/CyActivator.java
   2012-04-27 23:04:15 UTC (rev 29035)
+++ 
core3/impl/trunk/group-view-impl/src/main/java/org/cytoscape/group/view/internal/CyActivator.java
   2012-04-27 23:16:06 UTC (rev 29036)
@@ -20,6 +20,7 @@
 
 import java.util.Properties;
 
+import static org.cytoscape.work.ServiceProperties.*;
 
 public class CyActivator extends AbstractCyActivator {
        public CyActivator() {
@@ -48,7 +49,7 @@
                        new GroupViewDoubleClickListener(cyGroupManager, 
groupSettings);
 
                Properties doubleClickProperties = new Properties();
-               doubleClickProperties.setProperty("preferredAction", "OPEN");
+               doubleClickProperties.setProperty(PREFERRED_ACTION, "OPEN");
                registerService(bc,gvsListener,NodeViewTaskFactory.class, 
doubleClickProperties);
        }
 }

Modified: 
core3/impl/trunk/layout-cytoscape-impl/src/main/java/csapps/layout/CyActivator.java
===================================================================
--- 
core3/impl/trunk/layout-cytoscape-impl/src/main/java/csapps/layout/CyActivator.java
 2012-04-27 23:04:15 UTC (rev 29035)
+++ 
core3/impl/trunk/layout-cytoscape-impl/src/main/java/csapps/layout/CyActivator.java
 2012-04-27 23:16:06 UTC (rev 29036)
@@ -20,6 +20,7 @@
 import csapps.layout.algorithms.graphPartition.ISOMLayout;
 import csapps.layout.algorithms.hierarchicalLayout.HierarchicalLayoutAlgorithm;
 
+import static org.cytoscape.work.ServiceProperties.*;
 
 
 public class CyActivator extends AbstractCyActivator {
@@ -43,67 +44,67 @@
                
                
                Properties circularLayoutAlgorithmProps = new Properties();
-               
circularLayoutAlgorithmProps.setProperty("preferredMenu","Layout.Cytoscape 
Layouts");
+               
circularLayoutAlgorithmProps.setProperty(PREFERRED_MENU,"Layout.Cytoscape 
Layouts");
                
circularLayoutAlgorithmProps.setProperty("preferredTaskManager","menu");
-               
circularLayoutAlgorithmProps.setProperty("title",circularLayoutAlgorithm.toString());
-               circularLayoutAlgorithmProps.setProperty("menuGravity","10.2");
+               
circularLayoutAlgorithmProps.setProperty(TITLE,circularLayoutAlgorithm.toString());
+               circularLayoutAlgorithmProps.setProperty(MENU_GRAVITY,"10.2");
                
                
registerService(bc,circularLayoutAlgorithm,CyLayoutAlgorithm.class, 
circularLayoutAlgorithmProps);
                
                Properties hierarchicalLayoutAlgorithmProps = new Properties();
-               
hierarchicalLayoutAlgorithmProps.setProperty("preferredMenu","Layout.Cytoscape 
Layouts");
+               
hierarchicalLayoutAlgorithmProps.setProperty(PREFERRED_MENU,"Layout.Cytoscape 
Layouts");
                
hierarchicalLayoutAlgorithmProps.setProperty("preferredTaskManager","menu");
-               
hierarchicalLayoutAlgorithmProps.setProperty("title",hierarchicalLayoutAlgorithm.toString());
-               
hierarchicalLayoutAlgorithmProps.setProperty("menuGravity","10.8");
+               
hierarchicalLayoutAlgorithmProps.setProperty(TITLE,hierarchicalLayoutAlgorithm.toString());
+               
hierarchicalLayoutAlgorithmProps.setProperty(MENU_GRAVITY,"10.8");
                
registerService(bc,hierarchicalLayoutAlgorithm,CyLayoutAlgorithm.class, 
hierarchicalLayoutAlgorithmProps);
 
                Properties attributeCircleLayoutProps = new Properties();
-               
attributeCircleLayoutProps.setProperty("preferredMenu","Layout.Cytoscape 
Layouts");
+               
attributeCircleLayoutProps.setProperty(PREFERRED_MENU,"Layout.Cytoscape 
Layouts");
                
attributeCircleLayoutProps.setProperty("preferredTaskManager","menu");
-               
attributeCircleLayoutProps.setProperty("title",attributeCircleLayout.toString());
-               attributeCircleLayoutProps.setProperty("menuGravity","10.1");
+               
attributeCircleLayoutProps.setProperty(TITLE,attributeCircleLayout.toString());
+               attributeCircleLayoutProps.setProperty(MENU_GRAVITY,"10.1");
                
registerService(bc,attributeCircleLayout,CyLayoutAlgorithm.class, 
attributeCircleLayoutProps);
 
                Properties degreeSortedCircleLayoutProps = new Properties();
-               
degreeSortedCircleLayoutProps.setProperty("preferredMenu","Layout.Cytoscape 
Layouts");
+               
degreeSortedCircleLayoutProps.setProperty(PREFERRED_MENU,"Layout.Cytoscape 
Layouts");
                
degreeSortedCircleLayoutProps.setProperty("preferredTaskManager","menu");
-               
degreeSortedCircleLayoutProps.setProperty("title",degreeSortedCircleLayout.toString());
-               degreeSortedCircleLayoutProps.setProperty("menuGravity","10.3");
+               
degreeSortedCircleLayoutProps.setProperty(TITLE,degreeSortedCircleLayout.toString());
+               degreeSortedCircleLayoutProps.setProperty(MENU_GRAVITY,"10.3");
                
registerService(bc,degreeSortedCircleLayout,CyLayoutAlgorithm.class, 
degreeSortedCircleLayoutProps);
 
                Properties ISOMLayoutProps = new Properties();
-               ISOMLayoutProps.setProperty("preferredMenu","Layout.Cytoscape 
Layouts");
+               ISOMLayoutProps.setProperty(PREFERRED_MENU,"Layout.Cytoscape 
Layouts");
                ISOMLayoutProps.setProperty("preferredTaskManager","menu");
-               ISOMLayoutProps.setProperty("title",ISOMLayout.toString());
-               ISOMLayoutProps.setProperty("menuGravity","10.9");
+               ISOMLayoutProps.setProperty(TITLE,ISOMLayout.toString());
+               ISOMLayoutProps.setProperty(MENU_GRAVITY,"10.9");
                registerService(bc,ISOMLayout,CyLayoutAlgorithm.class, 
ISOMLayoutProps);
 
                Properties bioLayoutKKAlgorithmFALSEProps = new Properties();
-               
bioLayoutKKAlgorithmFALSEProps.setProperty("preferredMenu","Layout.Cytoscape 
Layouts");
+               
bioLayoutKKAlgorithmFALSEProps.setProperty(PREFERRED_MENU,"Layout.Cytoscape 
Layouts");
                
bioLayoutKKAlgorithmFALSEProps.setProperty("preferredTaskManager","menu");
-               
bioLayoutKKAlgorithmFALSEProps.setProperty("title",bioLayoutKKAlgorithmFALSE.toString());
-               
bioLayoutKKAlgorithmFALSEProps.setProperty("menuGravity","10.99");
+               
bioLayoutKKAlgorithmFALSEProps.setProperty(TITLE,bioLayoutKKAlgorithmFALSE.toString());
+               
bioLayoutKKAlgorithmFALSEProps.setProperty(MENU_GRAVITY,"10.99");
                
registerService(bc,bioLayoutKKAlgorithmFALSE,CyLayoutAlgorithm.class, 
bioLayoutKKAlgorithmFALSEProps);
                
                Properties bioLayoutKKAlgorithmTRUEProps = new Properties();
-               
bioLayoutKKAlgorithmTRUEProps.setProperty("preferredMenu","Layout.Cytoscape 
Layouts");
+               
bioLayoutKKAlgorithmTRUEProps.setProperty(PREFERRED_MENU,"Layout.Cytoscape 
Layouts");
                
bioLayoutKKAlgorithmTRUEProps.setProperty("preferredTaskManager","menu");
-               
bioLayoutKKAlgorithmTRUEProps.setProperty("title",bioLayoutKKAlgorithmTRUE.toString());
-               bioLayoutKKAlgorithmTRUEProps.setProperty("menuGravity","10.5");
+               
bioLayoutKKAlgorithmTRUEProps.setProperty(TITLE,bioLayoutKKAlgorithmTRUE.toString());
+               bioLayoutKKAlgorithmTRUEProps.setProperty(MENU_GRAVITY,"10.5");
                
registerService(bc,bioLayoutKKAlgorithmTRUE,CyLayoutAlgorithm.class, 
bioLayoutKKAlgorithmTRUEProps);
                
                Properties bioLayoutFRAlgorithmProps = new Properties();
-               
bioLayoutFRAlgorithmProps.setProperty("preferredMenu","Layout.Cytoscape 
Layouts");
+               
bioLayoutFRAlgorithmProps.setProperty(PREFERRED_MENU,"Layout.Cytoscape 
Layouts");
                
bioLayoutFRAlgorithmProps.setProperty("preferredTaskManager","menu");
-               
bioLayoutFRAlgorithmProps.setProperty("title",bioLayoutFRAlgorithm.toString());
-               bioLayoutFRAlgorithmProps.setProperty("menuGravity","10.4");
+               
bioLayoutFRAlgorithmProps.setProperty(TITLE,bioLayoutFRAlgorithm.toString());
+               bioLayoutFRAlgorithmProps.setProperty(MENU_GRAVITY,"10.4");
                
registerService(bc,bioLayoutFRAlgorithm,CyLayoutAlgorithm.class, 
bioLayoutFRAlgorithmProps);
 
                Properties groupAttributesLayoutProps = new Properties();
-               
groupAttributesLayoutProps.setProperty("preferredMenu","Layout.Cytoscape 
Layouts");
+               
groupAttributesLayoutProps.setProperty(PREFERRED_MENU,"Layout.Cytoscape 
Layouts");
                
groupAttributesLayoutProps.setProperty("preferredTaskManager","menu");
-               
groupAttributesLayoutProps.setProperty("title",groupAttributesLayout.toString());
-               groupAttributesLayoutProps.setProperty("menuGravity","10.6");
+               
groupAttributesLayoutProps.setProperty(TITLE,groupAttributesLayout.toString());
+               groupAttributesLayoutProps.setProperty(MENU_GRAVITY,"10.6");
                
registerService(bc,groupAttributesLayout,CyLayoutAlgorithm.class, 
groupAttributesLayoutProps);
        }
 }

Modified: 
core3/impl/trunk/layout-impl/src/main/java/org/cytoscape/view/layout/internal/CyActivator.java
===================================================================
--- 
core3/impl/trunk/layout-impl/src/main/java/org/cytoscape/view/layout/internal/CyActivator.java
      2012-04-27 23:04:15 UTC (rev 29035)
+++ 
core3/impl/trunk/layout-impl/src/main/java/org/cytoscape/view/layout/internal/CyActivator.java
      2012-04-27 23:16:06 UTC (rev 29036)
@@ -11,6 +11,7 @@
 import org.cytoscape.view.layout.internal.algorithms.GridNodeLayout;
 import org.osgi.framework.BundleContext;
 
+import static org.cytoscape.work.ServiceProperties.*;
 
 
 public class CyActivator extends AbstractCyActivator {
@@ -29,9 +30,9 @@
                registerService(bc,cyLayouts,CyLayoutAlgorithmManager.class, 
new Properties());
 
                Properties gridNodeLayoutProps = new Properties();
-               
gridNodeLayoutProps.setProperty("preferredMenu","Layout.Cytoscape Layouts");
+               
gridNodeLayoutProps.setProperty(PREFERRED_MENU,"Layout.Cytoscape Layouts");
                gridNodeLayoutProps.setProperty("preferredTaskManager","menu");
-               
gridNodeLayoutProps.setProperty("title",gridNodeLayout.toString());
+               
gridNodeLayoutProps.setProperty(TITLE,gridNodeLayout.toString());
                registerService(bc,gridNodeLayout,CyLayoutAlgorithm.class, 
gridNodeLayoutProps);
 
                
registerServiceListener(bc,cyLayouts,"addLayout","removeLayout",CyLayoutAlgorithm.class);

Modified: 
core3/impl/trunk/layout-jgraph-impl/src/main/java/csapps/layout/CyActivator.java
===================================================================
--- 
core3/impl/trunk/layout-jgraph-impl/src/main/java/csapps/layout/CyActivator.java
    2012-04-27 23:04:15 UTC (rev 29035)
+++ 
core3/impl/trunk/layout-jgraph-impl/src/main/java/csapps/layout/CyActivator.java
    2012-04-27 23:16:06 UTC (rev 29036)
@@ -10,8 +10,8 @@
 import org.cytoscape.view.layout.CyLayoutAlgorithm;
 import org.osgi.framework.BundleContext;
 
+import static org.cytoscape.work.ServiceProperties.*;
 
-
 public class CyActivator extends AbstractCyActivator {
        public CyActivator() {
                super();
@@ -31,35 +31,35 @@
                
                
                Properties jGraphAnnealingLayoutProps = new Properties();
-               jGraphAnnealingLayoutProps.setProperty("preferredMenu","JGraph 
Layouts");
+               jGraphAnnealingLayoutProps.setProperty(PREFERRED_MENU,"JGraph 
Layouts");
                
registerService(bc,jGraphAnnealingLayout,CyLayoutAlgorithm.class, 
jGraphAnnealingLayoutProps);
 
                Properties jGraphMoenLayoutProps = new Properties();
-               jGraphMoenLayoutProps.setProperty("preferredMenu","JGraph 
Layouts");
+               jGraphMoenLayoutProps.setProperty(PREFERRED_MENU,"JGraph 
Layouts");
                registerService(bc,jGraphMoenLayout,CyLayoutAlgorithm.class, 
jGraphMoenLayoutProps);
 
                Properties jGraphCircleGraphLayoutProps = new Properties();
-               
jGraphCircleGraphLayoutProps.setProperty("preferredMenu","JGraph Layouts");
+               jGraphCircleGraphLayoutProps.setProperty(PREFERRED_MENU,"JGraph 
Layouts");
                
registerService(bc,jGraphCircleGraphLayout,CyLayoutAlgorithm.class, 
jGraphCircleGraphLayoutProps);
 
                Properties jGraphRadialTreeLayoutProps = new Properties();
-               jGraphRadialTreeLayoutProps.setProperty("preferredMenu","JGraph 
Layouts");
+               jGraphRadialTreeLayoutProps.setProperty(PREFERRED_MENU,"JGraph 
Layouts");
                
registerService(bc,jGraphRadialTreeLayout,CyLayoutAlgorithm.class, 
jGraphRadialTreeLayoutProps);
 
                Properties jGraphGEMLayoutProps = new Properties();
-               jGraphGEMLayoutProps.setProperty("preferredMenu","JGraph 
Layouts");
+               jGraphGEMLayoutProps.setProperty(PREFERRED_MENU,"JGraph 
Layouts");
                registerService(bc,jGraphGEMLayout,CyLayoutAlgorithm.class, 
jGraphGEMLayoutProps);
 
                Properties jGraphSpringEmbeddedLayoutProps = new Properties();
-               
jGraphSpringEmbeddedLayoutProps.setProperty("preferredMenu","JGraph Layouts");
+               
jGraphSpringEmbeddedLayoutProps.setProperty(PREFERRED_MENU,"JGraph Layouts");
                
registerService(bc,jGraphSpringEmbeddedLayout,CyLayoutAlgorithm.class, 
jGraphSpringEmbeddedLayoutProps);
 
                Properties jGraphSugiyamaLayoutProps = new Properties();
-               jGraphSugiyamaLayoutProps.setProperty("preferredMenu","JGraph 
Layouts");
+               jGraphSugiyamaLayoutProps.setProperty(PREFERRED_MENU,"JGraph 
Layouts");
                
registerService(bc,jGraphSugiyamaLayout,CyLayoutAlgorithm.class, 
jGraphSugiyamaLayoutProps);
 
                Properties jGraphTreeLayoutProps = new Properties();
-               jGraphTreeLayoutProps.setProperty("preferredMenu","JGraph 
Layouts");
+               jGraphTreeLayoutProps.setProperty(PREFERRED_MENU,"JGraph 
Layouts");
                registerService(bc,jGraphTreeLayout,CyLayoutAlgorithm.class, 
jGraphTreeLayoutProps);
 
                

Modified: 
core3/impl/trunk/layout-prefuse-impl/src/main/java/org/cytoscape/prefuse/layouts/internal/CyActivator.java
===================================================================
--- 
core3/impl/trunk/layout-prefuse-impl/src/main/java/org/cytoscape/prefuse/layouts/internal/CyActivator.java
  2012-04-27 23:04:15 UTC (rev 29035)
+++ 
core3/impl/trunk/layout-prefuse-impl/src/main/java/org/cytoscape/prefuse/layouts/internal/CyActivator.java
  2012-04-27 23:16:06 UTC (rev 29036)
@@ -7,6 +7,7 @@
 import org.cytoscape.view.layout.CyLayoutAlgorithm;
 import org.osgi.framework.BundleContext;
 
+import static org.cytoscape.work.ServiceProperties.*;
 
 public class CyActivator extends AbstractCyActivator {
        public CyActivator() {
@@ -18,9 +19,9 @@
                ForceDirectedLayout forceDirectedLayout = new 
ForceDirectedLayout();
 
         Properties forceDirectedLayoutProps = new Properties();
-        forceDirectedLayoutProps.setProperty("preferredMenu","Layout.Prefuse 
Layouts");
+        forceDirectedLayoutProps.setProperty(PREFERRED_MENU,"Layout.Prefuse 
Layouts");
         forceDirectedLayoutProps.setProperty("preferredTaskManager","menu");
-        
forceDirectedLayoutProps.setProperty("title",forceDirectedLayout.toString());
+        
forceDirectedLayoutProps.setProperty(TITLE,forceDirectedLayout.toString());
                registerService(bc,forceDirectedLayout,CyLayoutAlgorithm.class, 
forceDirectedLayoutProps);
        }
 }

Modified: 
core3/impl/trunk/log-swing-impl/src/main/java/org/cytoscape/log/internal/CyActivator.java
===================================================================
--- 
core3/impl/trunk/log-swing-impl/src/main/java/org/cytoscape/log/internal/CyActivator.java
   2012-04-27 23:04:15 UTC (rev 29035)
+++ 
core3/impl/trunk/log-swing-impl/src/main/java/org/cytoscape/log/internal/CyActivator.java
   2012-04-27 23:16:06 UTC (rev 29036)
@@ -31,6 +31,7 @@
 import java.util.Map;
 import java.util.HashMap;
 
+import static org.cytoscape.work.ServiceProperties.*;
 
 
 public class CyActivator extends AbstractCyActivator {
@@ -90,8 +91,8 @@
                registerService(bc,statusBarAppender,PaxAppender.class, 
statusBarAppenderProps);
 
                Properties consoleTaskFactoryProps = new Properties();
-               consoleTaskFactoryProps.setProperty("preferredMenu","Help");
-               consoleTaskFactoryProps.setProperty("title","Log Console");
+               consoleTaskFactoryProps.setProperty(PREFERRED_MENU,"Help");
+               consoleTaskFactoryProps.setProperty(TITLE,"Log Console");
                registerService(bc,consoleTaskFactory,TaskFactory.class, 
consoleTaskFactoryProps);
 
        }

Modified: 
core3/impl/trunk/swing-application-impl/src/main/java/org/cytoscape/internal/CyActivator.java
===================================================================
--- 
core3/impl/trunk/swing-application-impl/src/main/java/org/cytoscape/internal/CyActivator.java
       2012-04-27 23:04:15 UTC (rev 29035)
+++ 
core3/impl/trunk/swing-application-impl/src/main/java/org/cytoscape/internal/CyActivator.java
       2012-04-27 23:16:06 UTC (rev 29036)
@@ -44,6 +44,7 @@
 import static org.cytoscape.internal.view.CyDesktopManager.Arrange.GRID;
 import static org.cytoscape.internal.view.CyDesktopManager.Arrange.HORIZONTAL;
 import static org.cytoscape.internal.view.CyDesktopManager.Arrange.VERTICAL;
+import static org.cytoscape.work.ServiceProperties.*;
 
 import java.util.Properties;
 
@@ -295,59 +296,59 @@
                }
 
                Properties helpContentsTaskFactoryProps = new Properties();
-               helpContentsTaskFactoryProps.setProperty("preferredMenu", 
"Help");
-               helpContentsTaskFactoryProps.setProperty("largeIconURL", 
getClass().getResource("/images/ximian/stock_help.png").toString());
-               helpContentsTaskFactoryProps.setProperty("title", 
"Contents...");
-               helpContentsTaskFactoryProps.setProperty("tooltip", "Show Help 
Contents...");
-               helpContentsTaskFactoryProps.setProperty("toolBarGravity", 
"20.0f");
-               helpContentsTaskFactoryProps.setProperty("inToolBar", "true");
+               helpContentsTaskFactoryProps.setProperty(PREFERRED_MENU, 
"Help");
+               helpContentsTaskFactoryProps.setProperty(LARGE_ICON_URL, 
getClass().getResource("/images/ximian/stock_help.png").toString());
+               helpContentsTaskFactoryProps.setProperty(TITLE, "Contents...");
+               helpContentsTaskFactoryProps.setProperty(TOOLTIP, "Show Help 
Contents...");
+               helpContentsTaskFactoryProps.setProperty(TOOL_BAR_GRAVITY, 
"20.0f");
+               helpContentsTaskFactoryProps.setProperty(IN_TOOL_BAR, "true");
                registerService(bc, helpContentsTaskFactory, TaskFactory.class, 
helpContentsTaskFactoryProps);
 
                Properties helpContactHelpDeskTaskFactoryProps = new 
Properties();
-               
helpContactHelpDeskTaskFactoryProps.setProperty("preferredMenu", "Help");
-               helpContactHelpDeskTaskFactoryProps.setProperty("title", 
"Contact Help Desk...");
+               helpContactHelpDeskTaskFactoryProps.setProperty(PREFERRED_MENU, 
"Help");
+               helpContactHelpDeskTaskFactoryProps.setProperty(TITLE, "Contact 
Help Desk...");
                registerService(bc, helpContactHelpDeskTaskFactory, 
TaskFactory.class,
                                helpContactHelpDeskTaskFactoryProps);
 
                Properties helpReportABugTaskFactoryProps = new Properties();
-               helpReportABugTaskFactoryProps.setProperty("preferredMenu", 
"Help");
-               helpReportABugTaskFactoryProps.setProperty("title", "Report a 
Bug...");
+               helpReportABugTaskFactoryProps.setProperty(PREFERRED_MENU, 
"Help");
+               helpReportABugTaskFactoryProps.setProperty(TITLE, "Report a 
Bug...");
                registerService(bc, helpReportABugTaskFactory, 
TaskFactory.class,
                                helpReportABugTaskFactoryProps);
 
                
                Properties helpAboutTaskFactoryProps = new Properties();
-               helpAboutTaskFactoryProps.setProperty("preferredMenu", "Help");
-               helpAboutTaskFactoryProps.setProperty("title", "About...");
+               helpAboutTaskFactoryProps.setProperty(PREFERRED_MENU, "Help");
+               helpAboutTaskFactoryProps.setProperty(TITLE, "About...");
                registerService(bc, helpAboutTaskFactory, TaskFactory.class, 
helpAboutTaskFactoryProps);
 
                Properties arrangeGridTaskFactoryProps = new Properties();
                
arrangeGridTaskFactoryProps.setProperty(ServiceProperties.ENABLE_FOR, 
"networkAndView");
-               arrangeGridTaskFactoryProps.setProperty("preferredMenu", 
"View.Arrange Network Windows[110]");
-               arrangeGridTaskFactoryProps.setProperty("title", "Grid");
+               arrangeGridTaskFactoryProps.setProperty(PREFERRED_MENU, 
"View.Arrange Network Windows[110]");
+               arrangeGridTaskFactoryProps.setProperty(TITLE, "Grid");
                registerService(bc, arrangeGridTaskFactory, TaskFactory.class, 
arrangeGridTaskFactoryProps);
 
                Properties arrangeCascadeTaskFactoryProps = new Properties();
                
arrangeCascadeTaskFactoryProps.setProperty(ServiceProperties.ENABLE_FOR, 
"networkAndView");
-               arrangeCascadeTaskFactoryProps.setProperty("preferredMenu",
+               arrangeCascadeTaskFactoryProps.setProperty(PREFERRED_MENU,
                                                           "View.Arrange 
Network Windows[110]");
-               arrangeCascadeTaskFactoryProps.setProperty("title", "Cascade");
+               arrangeCascadeTaskFactoryProps.setProperty(TITLE, "Cascade");
                registerService(bc, arrangeCascadeTaskFactory, 
TaskFactory.class,
                                arrangeCascadeTaskFactoryProps);
 
                Properties arrangeHorizontalTaskFactoryProps = new Properties();
                
arrangeHorizontalTaskFactoryProps.setProperty(ServiceProperties.ENABLE_FOR, 
"networkAndView");
-               arrangeHorizontalTaskFactoryProps.setProperty("preferredMenu",
+               arrangeHorizontalTaskFactoryProps.setProperty(PREFERRED_MENU,
                                                              "View.Arrange 
Network Windows[110]");
-               arrangeHorizontalTaskFactoryProps.setProperty("title", 
"Horizontal");
+               arrangeHorizontalTaskFactoryProps.setProperty(TITLE, 
"Horizontal");
                registerService(bc, arrangeHorizontalTaskFactory, 
TaskFactory.class,
                                arrangeHorizontalTaskFactoryProps);
 
                Properties arrangeVerticalTaskFactoryProps = new Properties();
                
arrangeVerticalTaskFactoryProps.setProperty(ServiceProperties.ENABLE_FOR, 
"networkAndView");
-               arrangeVerticalTaskFactoryProps.setProperty("preferredMenu",
+               arrangeVerticalTaskFactoryProps.setProperty(PREFERRED_MENU,
                                                            "View.Arrange 
Network Windows[110]");
-               arrangeVerticalTaskFactoryProps.setProperty("title", 
"Vertical");
+               arrangeVerticalTaskFactoryProps.setProperty(TITLE, "Vertical");
                registerService(bc, arrangeVerticalTaskFactory, 
TaskFactory.class,
                                arrangeVerticalTaskFactoryProps);
                registerAllServices(bc, cytoscapeDesktop, new Properties());

Modified: 
core3/support/trunk/task-testing-impl/src/main/java/org/cytoscape/internal/test/CyActivator.java
===================================================================
--- 
core3/support/trunk/task-testing-impl/src/main/java/org/cytoscape/internal/test/CyActivator.java
    2012-04-27 23:04:15 UTC (rev 29035)
+++ 
core3/support/trunk/task-testing-impl/src/main/java/org/cytoscape/internal/test/CyActivator.java
    2012-04-27 23:16:06 UTC (rev 29036)
@@ -27,6 +27,7 @@
 
 import java.util.Properties;
 
+import static org.cytoscape.work.ServiceProperties.*;
 
 
 public class CyActivator extends AbstractCyActivator {
@@ -54,40 +55,40 @@
                registerService(bc,multiTunableAction,CyAction.class, new 
Properties());
 
                Properties tunablesTestTaskFactoryProps = new Properties();
-               
tunablesTestTaskFactoryProps.setProperty("preferredMenu","Help");
-               tunablesTestTaskFactoryProps.setProperty("title","Tunable Task 
Test...");
+               tunablesTestTaskFactoryProps.setProperty(PREFERRED_MENU,"Help");
+               tunablesTestTaskFactoryProps.setProperty(TITLE,"Tunable Task 
Test...");
                registerService(bc,tunablesTestTaskFactory,TaskFactory.class, 
tunablesTestTaskFactoryProps);
 
                Properties tunablesTestTaskFactory2Props = new Properties();
                
tunablesTestTaskFactory2Props.setProperty("cytoPanelComponentTitle","Tunable 
Factory Test");
-               
tunablesTestTaskFactory2Props.setProperty("preferredMenu","Help");
-               tunablesTestTaskFactory2Props.setProperty("title","Tunable 
Factory Test...");
+               
tunablesTestTaskFactory2Props.setProperty(PREFERRED_MENU,"Help");
+               tunablesTestTaskFactory2Props.setProperty(TITLE,"Tunable 
Factory Test...");
                registerService(bc,tunablesTestTaskFactory2,TaskFactory.class, 
tunablesTestTaskFactory2Props);
 
                Properties tunablesTestTaskFactory3Props = new Properties();
                
tunablesTestTaskFactory3Props.setProperty("cytoPanelComponentTitle","Complex 
Tunable Test");
-               
tunablesTestTaskFactory3Props.setProperty("preferredMenu","Help");
-               tunablesTestTaskFactory3Props.setProperty("title","Complex 
Tunable Test...");
+               
tunablesTestTaskFactory3Props.setProperty(PREFERRED_MENU,"Help");
+               tunablesTestTaskFactory3Props.setProperty(TITLE,"Complex 
Tunable Test...");
                registerService(bc,tunablesTestTaskFactory3,TaskFactory.class, 
tunablesTestTaskFactory3Props);
 
                Properties infiniteTaskFactoryProps = new Properties();
-               infiniteTaskFactoryProps.setProperty("preferredMenu","Help");
-               infiniteTaskFactoryProps.setProperty("title","Infinite 
Test...");
+               infiniteTaskFactoryProps.setProperty(PREFERRED_MENU,"Help");
+               infiniteTaskFactoryProps.setProperty(TITLE,"Infinite Test...");
                registerService(bc,infiniteTaskFactory,TaskFactory.class, 
infiniteTaskFactoryProps);
 
                Properties multipleTaskFactoryProps = new Properties();
-               multipleTaskFactoryProps.setProperty("preferredMenu","Help");
-               multipleTaskFactoryProps.setProperty("title","Multiple Task 
Test...");
+               multipleTaskFactoryProps.setProperty(PREFERRED_MENU,"Help");
+               multipleTaskFactoryProps.setProperty(TITLE,"Multiple Task 
Test...");
                registerService(bc,multipleTaskFactory,TaskFactory.class, 
multipleTaskFactoryProps);
 
                Properties sharedTableTaskFactoryProps = new Properties();
-               sharedTableTaskFactoryProps.setProperty("preferredMenu","Help");
-               sharedTableTaskFactoryProps.setProperty("title","Shared Table 
Test...");
+               sharedTableTaskFactoryProps.setProperty(PREFERRED_MENU,"Help");
+               sharedTableTaskFactoryProps.setProperty(TITLE,"Shared Table 
Test...");
                
registerService(bc,sharedTableTaskFactory,NetworkTaskFactory.class, 
sharedTableTaskFactoryProps);
 
                Properties scootersTunableTaskFactoryProps = new Properties();
-               
scootersTunableTaskFactoryProps.setProperty("preferredMenu","Help");
-               scootersTunableTaskFactoryProps.setProperty("title","Scooter's 
Tunable Test...");
+               
scootersTunableTaskFactoryProps.setProperty(PREFERRED_MENU,"Help");
+               scootersTunableTaskFactoryProps.setProperty(TITLE,"Scooter's 
Tunable Test...");
                
registerService(bc,scootersTunableTaskFactory,TaskFactory.class, 
scootersTunableTaskFactoryProps);
        }
 }

-- 
You received this message because you are subscribed to the Google Groups 
"cytoscape-cvs" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/cytoscape-cvs?hl=en.

Reply via email to