Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorkmoore2012-03-26 15:49:21 -0400
committerkmoore2012-03-26 15:49:21 -0400
commitceae25be6f9c5bdaaa111e1b9b9f44d25da9a284 (patch)
treeb3c8e6682edd6ba92499622e1d9e53a4ca95bdeb
parentb6b980a61465e86a3d5b22ae89f3256d46a289ab (diff)
downloadwebtools.dali-ceae25be6f9c5bdaaa111e1b9b9f44d25da9a284.tar.gz
webtools.dali-ceae25be6f9c5bdaaa111e1b9b9f44d25da9a284.tar.xz
webtools.dali-ceae25be6f9c5bdaaa111e1b9b9f44d25da9a284.zip
added comment
-rw-r--r--common/plugins/org.eclipse.jpt.common.core/src/org/eclipse/jpt/common/core/JptResourceModelListener.java7
-rw-r--r--jpa/plugins/org.eclipse.jpt.jpa.core/src/org/eclipse/jpt/jpa/core/resource/xml/JpaXmlResource.java2
2 files changed, 7 insertions, 2 deletions
diff --git a/common/plugins/org.eclipse.jpt.common.core/src/org/eclipse/jpt/common/core/JptResourceModelListener.java b/common/plugins/org.eclipse.jpt.common.core/src/org/eclipse/jpt/common/core/JptResourceModelListener.java
index a0d0d3f046..5cca6fe240 100644
--- a/common/plugins/org.eclipse.jpt.common.core/src/org/eclipse/jpt/common/core/JptResourceModelListener.java
+++ b/common/plugins/org.eclipse.jpt.common.core/src/org/eclipse/jpt/common/core/JptResourceModelListener.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2007, 2010 Oracle. All rights reserved.
+ * Copyright (c) 2007, 2012 Oracle. All rights reserved.
* This program and the accompanying materials are made available under the
* terms of the Eclipse Public License v1.0, which accompanies this distribution
* and is available at http://www.eclipse.org/legal/epl-v10.html.
@@ -10,6 +10,7 @@
package org.eclipse.jpt.common.core;
import java.util.EventListener;
+import org.eclipse.wst.common.internal.emf.resource.TranslatorResourceImpl;
/**
* The listener is notified whenever anything in the JPA resource model changes.
@@ -28,6 +29,10 @@ public interface JptResourceModelListener
{
void resourceModelChanged(JptResourceModel jpaResourceModel);
+ /**
+ * Modified resource is closed without saving
+ * @see TranslatorResourceImpl#isReverting()
+ */
void resourceModelReverted(JptResourceModel jpaResourceModel);
void resourceModelUnloaded(JptResourceModel jpaResourceModel);
diff --git a/jpa/plugins/org.eclipse.jpt.jpa.core/src/org/eclipse/jpt/jpa/core/resource/xml/JpaXmlResource.java b/jpa/plugins/org.eclipse.jpt.jpa.core/src/org/eclipse/jpt/jpa/core/resource/xml/JpaXmlResource.java
index d8f2af4944..fba2afd075 100644
--- a/jpa/plugins/org.eclipse.jpt.jpa.core/src/org/eclipse/jpt/jpa/core/resource/xml/JpaXmlResource.java
+++ b/jpa/plugins/org.eclipse.jpt.jpa.core/src/org/eclipse/jpt/jpa/core/resource/xml/JpaXmlResource.java
@@ -113,7 +113,7 @@ public class JpaXmlResource
// unload events can happen before the resource set is removed - should always react to unload events
if (this.loadedFlagCleared(notification)) {
super.eNotify(notification);
- if (this.isReverting()) {
+ if (this.isReverting()) {// closing a modified file without saving
this.resourceModelReverted();
} else {
this.resourceModelUnloaded();

Back to the top