diff options
Diffstat (limited to 'plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/cdo/eresource/impl/CDOResourceImpl.java')
-rw-r--r-- | plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/cdo/eresource/impl/CDOResourceImpl.java | 37 |
1 files changed, 31 insertions, 6 deletions
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/cdo/eresource/impl/CDOResourceImpl.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/cdo/eresource/impl/CDOResourceImpl.java index 53636742ab..7571b88b5e 100644 --- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/cdo/eresource/impl/CDOResourceImpl.java +++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/cdo/eresource/impl/CDOResourceImpl.java @@ -1121,13 +1121,10 @@ public class CDOResourceImpl extends CDOResourceNodeImpl implements CDOResource, */ protected void loaded() { - if (!isLoaded()) + Notification notification = setLoaded(true); + if (notification != null) { - Notification notification = setLoaded(true); - if (notification != null) - { - eNotify(notification); - } + eNotify(notification); } } @@ -1168,5 +1165,33 @@ public class CDOResourceImpl extends CDOResourceNodeImpl implements CDOResource, { return true; } + + /** + * @since 4.0 + */ + @Override + protected void didAdd(int index, Object newObject) + { + super.didAdd(index, newObject); + + if (!isExisting() && !isLoaded()) + { + loaded(); + } + } + + /** + * @since 4.0 + */ + @Override + protected void didClear(int size, Object[] oldObjects) + { + super.didClear(size, oldObjects); + + if (!isExisting() && !isLoaded()) + { + loaded(); + } + } } } // CDOResourceImpl |