|
7 | 7 | import static org.cytoscape.work.ServiceProperties.PREFERRED_MENU;
|
8 | 8 | import static org.cytoscape.work.ServiceProperties.TITLE;
|
9 | 9 |
|
| 10 | +import java.io.File; |
| 11 | +import java.io.IOException; |
| 12 | +import java.nio.file.Files; |
| 13 | +import java.nio.file.Path; |
10 | 14 | import java.util.HashMap;
|
11 | 15 | import java.util.Map;
|
12 | 16 | import java.util.Properties;
|
|
26 | 30 | import org.baderlab.csplugins.enrichmentmap.view.HeatMapPanel;
|
27 | 31 | import org.baderlab.csplugins.enrichmentmap.view.ParametersPanel;
|
28 | 32 | import org.baderlab.csplugins.enrichmentmap.view.PostAnalysisPanel;
|
| 33 | +import org.cytoscape.application.CyApplicationConfiguration; |
29 | 34 | import org.cytoscape.application.CyApplicationManager;
|
30 | 35 | import org.cytoscape.application.events.SetCurrentNetworkListener;
|
31 | 36 | import org.cytoscape.application.events.SetCurrentNetworkViewListener;
|
|
64 | 69 | import org.cytoscape.work.SynchronousTaskManager;
|
65 | 70 | import org.cytoscape.work.TaskFactory;
|
66 | 71 | import org.cytoscape.work.swing.DialogTaskManager;
|
| 72 | +import org.osgi.framework.Bundle; |
67 | 73 | import org.osgi.framework.BundleContext;
|
| 74 | +import org.osgi.framework.Version; |
68 | 75 |
|
69 | 76 |
|
70 | 77 |
|
@@ -98,17 +105,7 @@ public void start(BundleContext bc) {
|
98 | 105 | @SuppressWarnings("rawtypes")
|
99 | 106 | SynchronousTaskManager syncTaskManager = getService(bc, SynchronousTaskManager.class);
|
100 | 107 | DialogTaskManager dialogTaskManager = getService(bc, DialogTaskManager.class);
|
101 |
| - // Used with annotations to make Groups of nodes |
102 |
| - CyGroupFactory groupFactory = getService(bc, CyGroupFactory.class); |
103 |
| - CyGroupManager groupManager = getService(bc, CyGroupManager.class); |
104 |
| - // Used to create/remove the annotations (ellipses and text labels) |
105 |
| - AnnotationManager annotationManager = getService(bc, AnnotationManager.class); |
106 |
| - @SuppressWarnings("unchecked") |
107 |
| - AnnotationFactory<ShapeAnnotation> shapeFactory = (AnnotationFactory<ShapeAnnotation>) getService(bc, AnnotationFactory.class, "(type=ShapeAnnotation.class)"); |
108 |
| - @SuppressWarnings("unchecked") |
109 |
| - AnnotationFactory<TextAnnotation> textFactory = (AnnotationFactory<TextAnnotation>) getService(bc, AnnotationFactory.class, "(type=TextAnnotation.class)"); |
110 |
| - CommandExecutorTaskFactory commandExecutor = getService(bc, CommandExecutorTaskFactory.class); |
111 |
| - //get the service registrar so we can register new services in different classes |
| 108 | + CyApplicationConfiguration applicationConfiguration = getService(bc, CyApplicationConfiguration.class); |
112 | 109 | CyServiceRegistrar registrar = getService(bc, CyServiceRegistrar.class);
|
113 | 110 |
|
114 | 111 |
|
@@ -142,8 +139,7 @@ public void start(BundleContext bc) {
|
142 | 139 | serviceProperties.put(IN_MENU_BAR, "true");
|
143 | 140 | serviceProperties.put(PREFERRED_MENU, APP_MENU);
|
144 | 141 | serviceProperties.put(INSERT_SEPARATOR_BEFORE, "true");
|
145 |
| - HelpAction helpAction = new HelpAction(serviceProperties, cyApplicationManagerRef, cyNetworkViewManagerRef, |
146 |
| - registrar); |
| 142 | + HelpAction helpAction = new HelpAction(serviceProperties, cyApplicationManagerRef, cyNetworkViewManagerRef, registrar); |
147 | 143 | helpAction.setMenuGravity(2.1f);
|
148 | 144 |
|
149 | 145 | //About Action
|
@@ -210,5 +206,7 @@ public void start(BundleContext bc) {
|
210 | 206 | tableColumnTaskFactoryProps.setProperty("tableTypes", "edge");
|
211 | 207 | registerService(bc, tableColumnTaskFactory, TableColumnTaskFactory.class, tableColumnTaskFactoryProps);
|
212 | 208 |
|
| 209 | + Em21Handler.removeVersion21(bc, applicationConfiguration); |
213 | 210 | }
|
| 211 | + |
214 | 212 | }
|
0 commit comments