Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorsminto2005-07-22 21:25:41 +0000
committersminto2005-07-22 21:25:41 +0000
commita5458cd26f004f7ed59510d269ec31f551552646 (patch)
tree565c64226d70593c5ff5d127f299faa7a5bf5105 /org.eclipse.mylyn.tasks.ui
parentfff93e1a5f09d837dbaa70888092185e596c8eee (diff)
downloadorg.eclipse.mylyn.tasks-a5458cd26f004f7ed59510d269ec31f551552646.tar.gz
org.eclipse.mylyn.tasks-a5458cd26f004f7ed59510d269ec31f551552646.tar.xz
org.eclipse.mylyn.tasks-a5458cd26f004f7ed59510d269ec31f551552646.zip
applied kens patch for Bug# 104261 make time refresh automatically on task list
Diffstat (limited to 'org.eclipse.mylyn.tasks.ui')
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasklist/Task.java7
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasklist/ui/TaskSummaryEditor.java2
2 files changed, 5 insertions, 4 deletions
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasklist/Task.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasklist/Task.java
index e7a18c5ee..112ceb4f4 100644
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasklist/Task.java
+++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasklist/Task.java
@@ -327,6 +327,7 @@ public class Task implements ITask {
}
public String getElapsedTimeForDisplay() {
+ calculateElapsedTime();
long seconds = elapsed / 1000;
long minutes = 0;
long hours = 0;
@@ -349,7 +350,7 @@ public class Task implements ITask {
minutes = seconds / MIN;
if (minutes == 1) {
min = minutes + " minute ";
- } else if (minutes > 1) {
+ } else if (minutes != 1) {
min = minutes + " minutes ";
}
// seconds -= minutes * MIN;
@@ -363,7 +364,7 @@ public class Task implements ITask {
minutes = seconds / MIN;
if (minutes == 1) {
min = minutes + " minute ";
- } else if (minutes > 1) {
+ } else if (minutes != 1) {
min = minutes + " minutes ";
}
// seconds -= minutes * MIN;
@@ -379,7 +380,7 @@ public class Task implements ITask {
// } else if (seconds > 1) {
// sec = seconds + " seconds";
// }
- return sec;
+ return "0 minutes";
}
}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasklist/ui/TaskSummaryEditor.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasklist/ui/TaskSummaryEditor.java
index 79344d44c..38729531f 100644
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasklist/ui/TaskSummaryEditor.java
+++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasklist/ui/TaskSummaryEditor.java
@@ -337,7 +337,7 @@ public class TaskSummaryEditor extends EditorPart {
TableWrapData td = new TableWrapData(TableWrapData.FILL_GRAB);
td.colspan = 2;
description.setLayoutData(td);
- if (task.canEditDescription()) {
+ if (!task.canEditDescription()) {
description.setEnabled(false);
} else {
description.addModifyListener(new ModifyListener() {

Back to the top