aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorOleg Besedin2012-10-23 15:47:14 (EDT)
committerOleg Besedin2012-10-23 15:47:14 (EDT)
commit6284352db0ecc667dbb867f57ac51a2a55472cd2 (patch)
treebad8bda9b592682c36525f5b867ba5b3b3a588f8
parent4fb085bbddd9e72a75662c3daef38a9836da871d (diff)
downloadeclipse.platform.runtime-6284352db0ecc667dbb867f57ac51a2a55472cd2.zip
eclipse.platform.runtime-6284352db0ecc667dbb867f57ac51a2a55472cd2.tar.gz
eclipse.platform.runtime-6284352db0ecc667dbb867f57ac51a2a55472cd2.tar.bz2
Bug 392661 - No selection changed events anymorev20121023-194714
-rw-r--r--bundles/org.eclipse.e4.core.contexts/src/org/eclipse/e4/core/internal/contexts/EclipseContext.java5
1 files changed, 5 insertions, 0 deletions
diff --git a/bundles/org.eclipse.e4.core.contexts/src/org/eclipse/e4/core/internal/contexts/EclipseContext.java b/bundles/org.eclipse.e4.core.contexts/src/org/eclipse/e4/core/internal/contexts/EclipseContext.java
index 62cf242..6e37537 100644
--- a/bundles/org.eclipse.e4.core.contexts/src/org/eclipse/e4/core/internal/contexts/EclipseContext.java
+++ b/bundles/org.eclipse.e4.core.contexts/src/org/eclipse/e4/core/internal/contexts/EclipseContext.java
@@ -93,6 +93,7 @@ public class EclipseContext implements IEclipseContext {
private ReferenceQueue<Object> referenceQueue = new ReferenceQueue<Object>();
private Map<Reference<?>, TrackableComputationExt> activeComputations = Collections.synchronizedMap(new HashMap<Reference<?>, TrackableComputationExt>());
+ private Set<TrackableComputationExt> activeRATs = Collections.synchronizedSet(new HashSet<TrackableComputationExt>());
private final static Object[] nullArgs = new Object[] {null};
@@ -160,6 +161,7 @@ public class EclipseContext implements IEclipseContext {
}
activeComputations.clear();
+ activeRATs.clear();
ContextChangeEvent event = new ContextChangeEvent(this, ContextChangeEvent.DISPOSE, null, null, null);
Set<Scheduled> scheduled = new LinkedHashSet<Scheduled>();
@@ -305,12 +307,15 @@ public class EclipseContext implements IEclipseContext {
Reference<Object> ref = computation.getReference();
if (ref != null)
activeComputations.put(ref, computation);
+ else
+ activeRATs.add(computation);
}
}
public void removeRAT(Computation computation) {
// remove from listeners
weakListeners.remove(computation);
+ activeRATs.remove(computation);
}
protected void processScheduled(Set<Scheduled> scheduledList) {