Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorsminto2005-07-19 20:40:13 +0000
committersminto2005-07-19 20:40:13 +0000
commitf536d7f0bc58da13c15afc9facaf9be6de238e7e (patch)
tree03e1c9fdcf2efe49b6337f27668dc1ea0d8f5375 /org.eclipse.mylyn.bugzilla.core
parent32c15aa3f27438f813f3ce451d0a6c5778f1c380 (diff)
downloadorg.eclipse.mylyn.tasks-f536d7f0bc58da13c15afc9facaf9be6de238e7e.tar.gz
org.eclipse.mylyn.tasks-f536d7f0bc58da13c15afc9facaf9be6de238e7e.tar.xz
org.eclipse.mylyn.tasks-f536d7f0bc58da13c15afc9facaf9be6de238e7e.zip
applied patch from ken fo Bug# 102673 task editor dirty state
Diffstat (limited to 'org.eclipse.mylyn.bugzilla.core')
-rw-r--r--org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/bugzilla/core/offline/OfflineReportsFile.java8
1 files changed, 5 insertions, 3 deletions
diff --git a/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/bugzilla/core/offline/OfflineReportsFile.java b/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/bugzilla/core/offline/OfflineReportsFile.java
index 7a1ae526b..3dd92b7c8 100644
--- a/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/bugzilla/core/offline/OfflineReportsFile.java
+++ b/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/bugzilla/core/offline/OfflineReportsFile.java
@@ -303,10 +303,12 @@ public class OfflineReportsFile
}
// If this bug has not been saved offline before, add it to the file.
else {
+ int index = -1;
// If there is already an offline report with the same id, don't save this report.
- if (file.find(bug.getId()) >= 0) {
- MessageDialog.openInformation(null, "Bug's Id is already used.", "There is already a bug saved offline with an identical id.");
- return;
+ if ((index = file.find(bug.getId())) >= 0) {
+ removeReport(getOfflineBugs().get(index));
+// MessageDialog.openInformation(null, "Bug's Id is already used.", "There is already a bug saved offline with an identical id.");
+// return;
}
file.add(bug);
bug.setOfflineState(true);

Back to the top