Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorUwe Stieber2011-12-31 15:18:35 +0000
committerUwe Stieber2011-12-31 15:18:35 +0000
commit85b8abce60538d62768eaf2eef08e1aacae391b0 (patch)
treedcbbde07a284f0b26861e105df646dc3140cb171 /target_explorer/plugins/org.eclipse.tcf.te.runtime.model
parent8591befe75b62ef23b58411f50af38b6bc7b183e (diff)
downloadorg.eclipse.tcf-85b8abce60538d62768eaf2eef08e1aacae391b0.tar.gz
org.eclipse.tcf-85b8abce60538d62768eaf2eef08e1aacae391b0.tar.xz
org.eclipse.tcf-85b8abce60538d62768eaf2eef08e1aacae391b0.zip
Target Explorer: Save changes to transport section and recalculate editor pages on state changes
Diffstat (limited to 'target_explorer/plugins/org.eclipse.tcf.te.runtime.model')
-rw-r--r--target_explorer/plugins/org.eclipse.tcf.te.runtime.model/src/org/eclipse/tcf/te/runtime/model/ContainerModelNode.java12
1 files changed, 3 insertions, 9 deletions
diff --git a/target_explorer/plugins/org.eclipse.tcf.te.runtime.model/src/org/eclipse/tcf/te/runtime/model/ContainerModelNode.java b/target_explorer/plugins/org.eclipse.tcf.te.runtime.model/src/org/eclipse/tcf/te/runtime/model/ContainerModelNode.java
index d9c21cc14..35ee8901c 100644
--- a/target_explorer/plugins/org.eclipse.tcf.te.runtime.model/src/org/eclipse/tcf/te/runtime/model/ContainerModelNode.java
+++ b/target_explorer/plugins/org.eclipse.tcf.te.runtime.model/src/org/eclipse/tcf/te/runtime/model/ContainerModelNode.java
@@ -10,7 +10,6 @@
package org.eclipse.tcf.te.runtime.model;
import java.util.ArrayList;
-import java.util.EventObject;
import java.util.List;
import java.util.UUID;
import java.util.concurrent.locks.Lock;
@@ -18,7 +17,6 @@ import java.util.concurrent.locks.ReentrantLock;
import org.eclipse.core.runtime.Assert;
import org.eclipse.core.runtime.jobs.ISchedulingRule;
-import org.eclipse.tcf.te.runtime.events.EventManager;
import org.eclipse.tcf.te.runtime.model.interfaces.IContainerModelNode;
import org.eclipse.tcf.te.runtime.model.interfaces.IModelNode;
@@ -129,9 +127,7 @@ public class ContainerModelNode extends ModelNode implements IContainerModelNode
childListLock.unlock();
}
- EventObject event = newEvent(this, NOTIFY_ADDED, null, new IModelNode[] { node });
- if (event != null) EventManager.getInstance().fireEvent(event);
-
+ fireChangeEvent(NOTIFY_ADDED, null, new IModelNode[] { node });
return true;
}
return false;
@@ -152,8 +148,7 @@ public class ContainerModelNode extends ModelNode implements IContainerModelNode
try { childListLock.lock(); removed = childList.remove(node); } finally { childListLock.unlock(); }
// Unlink the parent and fire the removed notification if the element got removed
if (removed) {
- EventObject event = newEvent(this, NOTIFY_REMOVED, new IModelNode[] { node }, null);
- if (event != null) EventManager.getInstance().fireEvent(event);
+ fireChangeEvent(NOTIFY_REMOVED, new IModelNode[] { node }, null);
}
return removed;
@@ -176,8 +171,7 @@ public class ContainerModelNode extends ModelNode implements IContainerModelNode
}
if (removed) {
- EventObject event = newEvent(this, NOTIFY_REMOVED, children, null);
- if (event != null) EventManager.getInstance().fireEvent(event);
+ fireChangeEvent(NOTIFY_REMOVED, children, null);
}
return removed;

Back to the top