summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjbouthillie2011-12-08 10:32:13 (EST)
committerjbouthillie2011-12-08 10:32:13 (EST)
commitcee41b2fa15d6c42afee1c65426522f1de2fc5ce (patch)
treea3563189f6cc6c83174526283494d65ea6e5c9ff
parent3ad0ebe14042a5865c0285f1eeeae0622ada265a (diff)
downloadorg.eclipse.mylyn.reviews.r4e-cee41b2fa15d6c42afee1c65426522f1de2fc5ce.zip
org.eclipse.mylyn.reviews.r4e-cee41b2fa15d6c42afee1c65426522f1de2fc5ce.tar.gz
org.eclipse.mylyn.reviews.r4e-cee41b2fa15d6c42afee1c65426522f1de2fc5ce.tar.bz2
NEW - bug 360595: Exit Decision default for Informal reviews
https://bugs.eclipse.org/bugs/show_bug.cgi?id=360595
-rw-r--r--org.eclipse.mylyn.reviews.r4e.ui/src/org/eclipse/mylyn/reviews/r4e/ui/internal/model/R4EUIReviewBasic.java3
-rw-r--r--org.eclipse.mylyn.reviews.r4e.ui/src/org/eclipse/mylyn/reviews/r4e/ui/internal/model/R4EUIReviewGroup.java10
2 files changed, 13 insertions, 0 deletions
diff --git a/org.eclipse.mylyn.reviews.r4e.ui/src/org/eclipse/mylyn/reviews/r4e/ui/internal/model/R4EUIReviewBasic.java b/org.eclipse.mylyn.reviews.r4e.ui/src/org/eclipse/mylyn/reviews/r4e/ui/internal/model/R4EUIReviewBasic.java
index 8d5d863..c1cc640 100644
--- a/org.eclipse.mylyn.reviews.r4e.ui/src/org/eclipse/mylyn/reviews/r4e/ui/internal/model/R4EUIReviewBasic.java
+++ b/org.eclipse.mylyn.reviews.r4e.ui/src/org/eclipse/mylyn/reviews/r4e/ui/internal/model/R4EUIReviewBasic.java
@@ -347,6 +347,9 @@ public class R4EUIReviewBasic extends R4EUIModelElement {
fReview.setEntryCriteria(((R4EReview) aModelComponent).getEntryCriteria());
fReview.setObjectives(((R4EReview) aModelComponent).getObjectives());
fReview.setReferenceMaterial(((R4EReview) aModelComponent).getReferenceMaterial());
+ // Set the default exit decision to the model
+ fReview.setDecision(((R4EReview) aModelComponent).getDecision());
+
R4EUIModelController.FResourceUpdater.checkIn(bookNum);
}
diff --git a/org.eclipse.mylyn.reviews.r4e.ui/src/org/eclipse/mylyn/reviews/r4e/ui/internal/model/R4EUIReviewGroup.java b/org.eclipse.mylyn.reviews.r4e.ui/src/org/eclipse/mylyn/reviews/r4e/ui/internal/model/R4EUIReviewGroup.java
index fb061e9..ab88d9f 100644
--- a/org.eclipse.mylyn.reviews.r4e.ui/src/org/eclipse/mylyn/reviews/r4e/ui/internal/model/R4EUIReviewGroup.java
+++ b/org.eclipse.mylyn.reviews.r4e.ui/src/org/eclipse/mylyn/reviews/r4e/ui/internal/model/R4EUIReviewGroup.java
@@ -31,13 +31,16 @@ import org.eclipse.jface.dialogs.ErrorDialog;
import org.eclipse.jface.window.Window;
import org.eclipse.mylyn.reviews.frame.core.model.Review;
import org.eclipse.mylyn.reviews.frame.core.model.ReviewComponent;
+import org.eclipse.mylyn.reviews.r4e.core.model.R4EDecision;
import org.eclipse.mylyn.reviews.r4e.core.model.R4EReview;
import org.eclipse.mylyn.reviews.r4e.core.model.R4EReviewComponent;
+import org.eclipse.mylyn.reviews.r4e.core.model.R4EReviewDecision;
import org.eclipse.mylyn.reviews.r4e.core.model.R4EReviewGroup;
import org.eclipse.mylyn.reviews.r4e.core.model.R4EReviewPhase;
import org.eclipse.mylyn.reviews.r4e.core.model.R4EReviewState;
import org.eclipse.mylyn.reviews.r4e.core.model.R4EReviewType;
import org.eclipse.mylyn.reviews.r4e.core.model.RModelFactory;
+import org.eclipse.mylyn.reviews.r4e.core.model.serial.Persistence.RModelFactoryExt;
import org.eclipse.mylyn.reviews.r4e.core.model.serial.impl.OutOfSyncException;
import org.eclipse.mylyn.reviews.r4e.core.model.serial.impl.ResourceHandlingException;
import org.eclipse.mylyn.reviews.r4e.ui.R4EUIPlugin;
@@ -291,6 +294,13 @@ public class R4EUIReviewGroup extends R4EUIModelElement {
tempReview.setEntryCriteria(dialog.getEntryCriteriaValue());
tempReview.setObjectives(dialog.getObjectivesValue());
tempReview.setReferenceMaterial(dialog.getReferenceMaterialValue());
+ //Set default exit decision for INFORMAL review
+ if (type.equals(R4EReviewType.R4E_REVIEW_TYPE_INFORMAL)) {
+ R4EReviewDecision reviewDecision = RModelFactoryExt.eINSTANCE.createR4EReviewDecision();
+ reviewDecision.setValue(R4EDecision.R4E_REVIEW_DECISION_ACCEPTED);
+ tempReview.setDecision(reviewDecision);
+
+ }
}
R4EUIModelController.setJobInProgress(false); //Enable view
return tempReview;