Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorrelves2006-11-24 04:45:42 +0000
committerrelves2006-11-24 04:45:42 +0000
commitb0a65fdf1b710e8ba0804f98d96d4f1717de210d (patch)
treead83bec23881fe7378ab53dd43e4d26282d08346 /org.eclipse.mylyn.tasks.core/src
parent3b184b26b72730d8ef422f24b027c470b23a4aba (diff)
downloadorg.eclipse.mylyn.tasks-b0a65fdf1b710e8ba0804f98d96d4f1717de210d.tar.gz
org.eclipse.mylyn.tasks-b0a65fdf1b710e8ba0804f98d96d4f1717de210d.tar.xz
org.eclipse.mylyn.tasks-b0a65fdf1b710e8ba0804f98d96d4f1717de210d.zip
REOPENED - bug 142039: highlight bug report items changed since last viewing
https://bugs.eclipse.org/bugs/show_bug.cgi?id=142039
Diffstat (limited to 'org.eclipse.mylyn.tasks.core/src')
-rw-r--r--org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/RepositoryTaskData.java22
-rw-r--r--org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/TaskComment.java90
2 files changed, 10 insertions, 102 deletions
diff --git a/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/RepositoryTaskData.java b/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/RepositoryTaskData.java
index 4251896e7..75f1d2784 100644
--- a/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/RepositoryTaskData.java
+++ b/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/RepositoryTaskData.java
@@ -21,13 +21,14 @@ import java.util.StringTokenizer;
/**
* @author Mik Kersten
* @author Rob Elves
+ *
*/
public class RepositoryTaskData extends AttributeContainer implements Serializable {
-
- private static final long serialVersionUID = 2402511248225227689L;
+
+ private static final long serialVersionUID = 2302511248225227689L;
private boolean hasLocalChanges = false;
-
+
public static final String VAL_STATUS_NEW = "NEW";
private String reportID;
@@ -42,7 +43,7 @@ public class RepositoryTaskData extends AttributeContainer implements Serializab
/** The operation that was selected to do to the bug */
protected RepositoryOperation selectedOperation = null;
-
+
/** The repositoryOperations that can be done on the report */
protected List<RepositoryOperation> repositoryOperations = new ArrayList<RepositoryOperation>();
@@ -237,14 +238,6 @@ public class RepositoryTaskData extends AttributeContainer implements Serializab
}
public void addComment(TaskComment taskComment) {
- TaskComment preceding = null;
- if (taskComments.size() > 0) {
- // if there are some comments, get the last comment and set the next
- // value to be the new comment
- preceding = taskComments.get(taskComments.size() - 1);
- preceding.setNext(taskComment);
- }
- taskComment.setPrevious(preceding);
taskComments.add(taskComment);
}
@@ -265,8 +258,9 @@ public class RepositoryTaskData extends AttributeContainer implements Serializab
}
public RepositoryTaskAttribute getDescriptionAttribute() {
- RepositoryTaskAttribute attribute = getAttribute(RepositoryTaskAttribute.DESCRIPTION);
- // TODO: Remove the following after 1.0 release as we now just have a description attribute
+ RepositoryTaskAttribute attribute = getAttribute(RepositoryTaskAttribute.DESCRIPTION);
+ // TODO: Remove the following after 1.0 release as we now just have a
+ // description attribute
if (attribute == null) {
List<TaskComment> coms = this.getComments();
if (coms != null && coms.size() > 0) {
diff --git a/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/TaskComment.java b/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/TaskComment.java
index 9d9f56a27..2bbea0d32 100644
--- a/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/TaskComment.java
+++ b/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/TaskComment.java
@@ -20,47 +20,21 @@ import java.io.Serializable;
*/
public class TaskComment extends AttributeContainer implements Serializable {
- private static final long serialVersionUID = -1760372869047050979L;
-
- // /** Parser for dates in the report */
- // public static SimpleDateFormat creation_ts_date_format = new
- // SimpleDateFormat("yyyy-MM-dd HH:mm");
-
- /** Comment's bug */
- private final RepositoryTaskData bug;
+ private static final long serialVersionUID = 1076016406335550308L;
/** Comment's number */
private final int number;
- // /** Comment's creation timestamp */
- // private Date created;
-
- /** Preceding comment */
- private TaskComment previous;
-
- /** Following comment */
- private TaskComment next;
-
private boolean hasAttachment;
private int attachmentId;
- public TaskComment(AbstractAttributeFactory attributeFactory, RepositoryTaskData report, int num) {
+ public TaskComment(AbstractAttributeFactory attributeFactory, int num) {
super(attributeFactory);
- this.bug = report;
this.number = num;
}
/**
- * Get the bug that this comment is associated with
- *
- * @return The bug that this comment is associated with
- */
- public RepositoryTaskData getBug() {
- return bug;
- }
-
- /**
* Get this comment's number
*
* @return This comment's number
@@ -76,26 +50,6 @@ public class TaskComment extends AttributeContainer implements Serializable {
*/
public String getCreated() {
return getAttributeValue(RepositoryTaskAttribute.COMMENT_DATE);
- // TaskRepository repository =
- // MylarTaskListPlugin.getRepositoryManager().getRepository(bug.getRepositoryKind(),
- // bug.getRepositoryUrl());
- // TimeZone timeZone = TimeZone.getDefault();
- // if(repository != null) {
- // timeZone = TimeZone.getTimeZone(repository.getTimeZoneId());
- // }
- // if (created == null) {
- // created = Calendar.getInstance().getTime();
- // try {
- // creation_ts_date_format.setTimeZone(timeZone);
- // created =
- // creation_ts_date_format.parse(getAttributeValue(RepositoryTaskAttribute.COMMENT_DATE));
- // } catch (Exception e) {
- // // ignore
- // // MylarStatusHandler.log("Comment creation date parse error,
- // // setting to NOW.", Comment.class);
- // }
- // }
- // return created;
}
/**
@@ -127,46 +81,6 @@ public class TaskComment extends AttributeContainer implements Serializable {
return getAttributeValue(RepositoryTaskAttribute.COMMENT_TEXT);
}
- /**
- * Get the next comment for the bug
- *
- * @return Returns the following comment, or <code>null</code> if the last
- * one.
- */
- public TaskComment getNext() {
- return next;
- }
-
- /**
- * Set the next comment for the bug
- *
- * @param next
- * The comment that is after this one
- */
- protected void setNext(TaskComment next) {
- this.next = next;
- }
-
- /**
- * Get the previous comment
- *
- * @return Returns preceding comment, or <code>null</code> if the first
- * one
- */
- public TaskComment getPrevious() {
- return previous;
- }
-
- /**
- * Seth the previous comment for the bug
- *
- * @param previous
- * The comment that is before this one
- */
- protected void setPrevious(TaskComment previous) {
- this.previous = previous;
- }
-
public void setHasAttachment(boolean b) {
this.hasAttachment = b;
}

Back to the top