From: Tuukka Lehtonen Date: Thu, 13 Dec 2018 11:45:52 +0000 (+0200) Subject: Revert "Fire selection change events on every selection change" X-Git-Url: https://gerrit.simantics.org/r/gitweb?p=simantics%2Fplatform.git;a=commitdiff_plain;h=c185093225c7cbc7f2f1e25b5470cbf126ed3d8e Revert "Fire selection change events on every selection change" This reverts commit 68f350c72673e7052ccadf3b352bc01d232a5f85. --- diff --git a/bundles/org.simantics.browsing.ui.swt/src/org/simantics/browsing/ui/swt/GraphExplorerImpl.java b/bundles/org.simantics.browsing.ui.swt/src/org/simantics/browsing/ui/swt/GraphExplorerImpl.java index e90ae5eee..df4860d42 100644 --- a/bundles/org.simantics.browsing.ui.swt/src/org/simantics/browsing/ui/swt/GraphExplorerImpl.java +++ b/bundles/org.simantics.browsing.ui.swt/src/org/simantics/browsing/ui/swt/GraphExplorerImpl.java @@ -173,8 +173,6 @@ import org.simantics.utils.ui.SWTUtils; import org.simantics.utils.ui.jface.BasePostSelectionProvider; import org.simantics.utils.ui.widgets.VetoingEventHandler; import org.simantics.utils.ui.workbench.WorkbenchUtils; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; import gnu.trove.map.hash.THashMap; import gnu.trove.procedure.TObjectProcedure; @@ -187,8 +185,6 @@ import gnu.trove.set.hash.THashSet; */ class GraphExplorerImpl extends GraphExplorerImplBase implements Listener, GraphExplorer /*, IPostSelectionProvider*/ { - private static final Logger LOGGER = LoggerFactory.getLogger(GraphExplorerImpl.class); - private static class GraphExplorerPostSelectionProvider implements IPostSelectionProvider { private GraphExplorerImpl ge; @@ -1557,14 +1553,10 @@ class GraphExplorerImpl extends GraphExplorerImplBase implements Listener, Graph OpenStrategy os = new OpenStrategy(tree); os.addSelectionListener(SelectionListener.widgetSelectedAdapter(e -> { - ISelection s = resetSelectionFromWidget(); - if (s != null) { - LOGGER.trace("Fire selection change: {}", s); - selectionProvider.fireSelection(s); - } + resetSelectionFromWidget(); })); os.addPostSelectionListener(SelectionListener.widgetSelectedAdapter(e -> { - LOGGER.trace("Fire post-selection change: {}", selectionProvider.getSelection()); + //System.out.println("OPENSTRATEGY: post selection changed: " + e); resetSelectionFromWidgetAndFirePostSelection(true); }));