Skip to content

Commit 36500ce

Browse files
committed
Removed AutoAnnotate
1 parent c29a525 commit 36500ce

38 files changed

+143
-6106
lines changed

EnrichmentMapPlugin/src/main/java/org/baderlab/csplugins/enrichmentmap/CyActivator.java

Lines changed: 1 addition & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,6 @@
1313
import org.baderlab.csplugins.enrichmentmap.actions.LoadPostAnalysisPanelAction;
1414
import org.baderlab.csplugins.enrichmentmap.actions.ShowAboutPanelAction;
1515
import org.baderlab.csplugins.enrichmentmap.actions.ShowEdgeWidthDialogAction;
16-
import org.baderlab.csplugins.enrichmentmap.autoannotate.AutoAnnotationManager;
17-
import org.baderlab.csplugins.enrichmentmap.autoannotate.action.AutoAnnotationPanelAction;
18-
import org.baderlab.csplugins.enrichmentmap.autoannotate.action.DisplayOptionsPanelAction;
1916
import org.baderlab.csplugins.enrichmentmap.commands.EnrichmentMapGSEACommandHandlerTaskFactory;
2017
import org.baderlab.csplugins.enrichmentmap.task.BuildEnrichmentMapTuneableTaskFactory;
2118
import org.baderlab.csplugins.enrichmentmap.task.CreatePublicationVisualStyleTaskFactory;
@@ -28,7 +25,6 @@
2825
import org.cytoscape.application.CyApplicationManager;
2926
import org.cytoscape.application.events.SetCurrentNetworkListener;
3027
import org.cytoscape.application.events.SetCurrentNetworkViewListener;
31-
import org.cytoscape.application.events.SetSelectedNetworkViewsListener;
3228
import org.cytoscape.application.swing.CyAction;
3329
import org.cytoscape.application.swing.CySwingApplication;
3430
import org.cytoscape.command.CommandExecutorTaskFactory;
@@ -40,9 +36,6 @@
4036
import org.cytoscape.model.CyNetworkManager;
4137
import org.cytoscape.model.CyTableFactory;
4238
import org.cytoscape.model.CyTableManager;
43-
import org.cytoscape.model.events.ColumnCreatedListener;
44-
import org.cytoscape.model.events.ColumnDeletedListener;
45-
import org.cytoscape.model.events.ColumnNameChangedListener;
4639
import org.cytoscape.model.events.NetworkAboutToBeDestroyedListener;
4740
import org.cytoscape.model.events.RowsSetListener;
4841
import org.cytoscape.service.util.AbstractCyActivator;
@@ -57,7 +50,6 @@
5750
import org.cytoscape.view.layout.CyLayoutAlgorithmManager;
5851
import org.cytoscape.view.model.CyNetworkViewFactory;
5952
import org.cytoscape.view.model.CyNetworkViewManager;
60-
import org.cytoscape.view.model.events.NetworkViewAboutToBeDestroyedListener;
6153
import org.cytoscape.view.presentation.annotations.AnnotationFactory;
6254
import org.cytoscape.view.presentation.annotations.AnnotationManager;
6355
import org.cytoscape.view.presentation.annotations.ShapeAnnotation;
@@ -137,37 +129,15 @@ public void start(BundleContext bc) {
137129
EnrichmentMapActionListener EMActionListener = new EnrichmentMapActionListener(heatMapPanel_node,heatMapPanel_edge, cyApplicationManagerRef, cySwingApplicationRef,fileUtil,streamUtil,syncTaskManager);
138130
registerService(bc,EMActionListener, RowsSetListener.class, new Properties());
139131

140-
// Set up autoAnnotationManager, hand it all of the services it needs
141-
AutoAnnotationManager autoAnnotationManager = AutoAnnotationManager.getInstance();
142-
autoAnnotationManager.initialize(cySwingApplicationRef, tableManager, commandExecutor, dialogTaskManager, syncTaskManager, annotationManager, layoutManager, shapeFactory, textFactory, groupFactory, groupManager, heatMapPanel_node, EMActionListener, eventHelper,cyApplicationManagerRef);
143-
//register network/table events to autoAnnotationManager
144-
registerService(bc, autoAnnotationManager, SetSelectedNetworkViewsListener.class, new Properties());
145-
registerService(bc, autoAnnotationManager, NetworkViewAboutToBeDestroyedListener.class, new Properties());
146-
registerService(bc, autoAnnotationManager, ColumnCreatedListener.class, new Properties());
147-
registerService(bc, autoAnnotationManager, ColumnDeletedListener.class, new Properties());
148-
registerService(bc, autoAnnotationManager, ColumnNameChangedListener.class, new Properties());
149-
registerService(bc, autoAnnotationManager, RowsSetListener.class, new Properties());
150132

151133
//Create each Action within Enrichment map as a service
152134
Map<String,String> serviceProperties;
153-
154135
//About Action
155136
serviceProperties = new HashMap<>();
156137
serviceProperties.put("inMenuBar", "true");
157138
serviceProperties.put("preferredMenu", "Apps.EnrichmentMap");
158139
ShowAboutPanelAction aboutAction = new ShowAboutPanelAction(serviceProperties,cyApplicationManagerRef ,cyNetworkViewManagerRef, cySwingApplicationRef, openBrowserRef);
159140

160-
//Auto-annotate Panel Action - opens Annotation panel
161-
serviceProperties = new HashMap<>();
162-
serviceProperties.put("inMenuBar", "true");
163-
serviceProperties.put("preferredMenu", "Apps.EnrichmentMap");
164-
AutoAnnotationPanelAction autoAnnotationPanelAction = new AutoAnnotationPanelAction(serviceProperties,cyApplicationManagerRef, cyNetworkViewManagerRef, cySwingApplicationRef, annotationManager, registrar);
165-
166-
//Auto-annotate Display Options Panel Action - opens display options panel
167-
serviceProperties = new HashMap<>();
168-
DisplayOptionsPanelAction displayOptionsPanelAction = new DisplayOptionsPanelAction(serviceProperties,cyApplicationManagerRef, cyNetworkViewManagerRef, cySwingApplicationRef, annotationManager, registrar);
169-
autoAnnotationManager.setDisplayOptionsPanelAction(displayOptionsPanelAction);
170-
171141
//Build Enrichment Map Action - opens EM panel
172142
serviceProperties = new HashMap<>();
173143
serviceProperties.put("inMenuBar", "true");
@@ -193,14 +163,13 @@ public void start(BundleContext bc) {
193163

194164
//register the services
195165
registerService(bc, LoadEnrichmentMapInputPanelAction, CyAction.class, new Properties());
196-
registerService(bc, autoAnnotationPanelAction, CyAction.class, new Properties());
197166
registerService(bc, BulkEMInputPanelAction, CyAction.class, new Properties());
198167
registerService(bc, loadPostAnalysisAction, CyAction.class, new Properties());
199168
registerService(bc, edgeWidthPanelAction, CyAction.class, new Properties());
200169
registerService(bc, aboutAction, CyAction.class,new Properties());
201170

202171
//register the session save and restore
203-
EnrichmentMapSessionAction sessionAction = new EnrichmentMapSessionAction(cyNetworkManagerRef, sessionManager, cyApplicationManagerRef, streamUtil, autoAnnotationPanelAction);
172+
EnrichmentMapSessionAction sessionAction = new EnrichmentMapSessionAction(cyNetworkManagerRef, sessionManager, cyApplicationManagerRef, streamUtil);
204173
registerService(bc,sessionAction,SessionAboutToBeSavedListener.class, new Properties());
205174
registerService(bc,sessionAction,SessionLoadedListener.class, new Properties());
206175

0 commit comments

Comments
 (0)