Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormkersten2006-07-24 19:44:44 -0400
committermkersten2006-07-24 19:44:44 -0400
commit867985fb4cce74cd8b832ef1d7203384c3b0859b (patch)
treeeb442aa78f6bd3f5d5b00508efa5c9025e3c37d0
parentf8711baf8b5d4050b855cc110712f68566a63601 (diff)
downloadorg.eclipse.mylyn.tasks-867985fb4cce74cd8b832ef1d7203384c3b0859b.tar.gz
org.eclipse.mylyn.tasks-867985fb4cce74cd8b832ef1d7203384c3b0859b.tar.xz
org.eclipse.mylyn.tasks-867985fb4cce74cd8b832ef1d7203384c3b0859b.zip
Progress on: 112593: Problems found by FindBugs
https://bugs.eclipse.org/bugs/show_bug.cgi?id=112593
-rw-r--r--org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/BugzillaAttributeFactory.java4
-rw-r--r--org.eclipse.mylyn.help.ui/doc/new.html1
-rw-r--r--org.eclipse.mylyn.tasks.core/.cvsignore1
-rw-r--r--org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/internal/tasks/core/HtmlStreamTokenizer.java256
-rw-r--r--org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/internal/tasks/core/HtmlTag.java150
-rw-r--r--org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/internal/tasks/core/TaskRepositoriesExternalizer.java2
-rw-r--r--org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/.AbstractRepositoryTask.java17
-rw-r--r--org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/AbstractRepositoryTask.java17
-rw-r--r--org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/DelegatingTaskExternalizer.java10
-rw-r--r--org.eclipse.mylyn.tasks.ui/.cvsignore1
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/TaskListBackupManager.java2
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/TaskListColorsAndFonts.java2
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/TaskListNotificationPopup.java21
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/TaskListSynchronizationManager.java2
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/actions/SynchronizeSelectedAction.java16
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/AbstractRepositoryTaskEditor.java2
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/ExistingBugEditorInput.java37
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/RepositoryTaskOutlinePage.java2
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/RepositoryTextViewer.java2
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/TaskEditorInput.java32
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/TaskEditorUrlHyperlinkDetector.java2
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/planner/DateSelectionDialog.java6
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/planner/TaskActivityContentProvider.java27
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/views/TaskListView.java11
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/views/TaskRepositoriesView.java2
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/wizards/AbstractRepositorySettingsPage.java2
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/wizards/SelectRepositoryClientPage.java2
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/wizards/TaskDataImportWizardPage.java13
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/AbstractRepositoryConnector.java10
29 files changed, 313 insertions, 339 deletions
diff --git a/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/BugzillaAttributeFactory.java b/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/BugzillaAttributeFactory.java
index 687527ca2..8c14f66de 100644
--- a/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/BugzillaAttributeFactory.java
+++ b/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/BugzillaAttributeFactory.java
@@ -14,6 +14,10 @@ package org.eclipse.mylar.internal.bugzilla.core;
import org.eclipse.mylar.tasks.core.AbstractAttributeFactory;
import org.eclipse.mylar.tasks.core.RepositoryTaskAttribute;
+/**
+ * @author Rob Elves
+ * @author Mik Kersten
+ */
public class BugzillaAttributeFactory extends AbstractAttributeFactory {
private static final long serialVersionUID = 5087501781682994759L;
diff --git a/org.eclipse.mylyn.help.ui/doc/new.html b/org.eclipse.mylyn.help.ui/doc/new.html
index 8be42aa84..ed29199e1 100644
--- a/org.eclipse.mylyn.help.ui/doc/new.html
+++ b/org.eclipse.mylyn.help.ui/doc/new.html
@@ -51,6 +51,7 @@ Mylar 0.3.x</a></b></li>
<ul>
<li>Drag and drop of contexts and tasks</li>
<li>Report bugs directly from Error Log view</li>
+ <li>Hyperlinks in task editor box</li>
</ul>
<h2>Task List</h2>
diff --git a/org.eclipse.mylyn.tasks.core/.cvsignore b/org.eclipse.mylyn.tasks.core/.cvsignore
index ba077a403..4a98758e6 100644
--- a/org.eclipse.mylyn.tasks.core/.cvsignore
+++ b/org.eclipse.mylyn.tasks.core/.cvsignore
@@ -1 +1,2 @@
bin
+.fbwarnings
diff --git a/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/internal/tasks/core/HtmlStreamTokenizer.java b/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/internal/tasks/core/HtmlStreamTokenizer.java
index 91c6d8439..4b2b2e111 100644
--- a/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/internal/tasks/core/HtmlStreamTokenizer.java
+++ b/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/internal/tasks/core/HtmlStreamTokenizer.java
@@ -522,36 +522,36 @@ public class HtmlStreamTokenizer {
*/
static {
entities = new HashMap<String, Character>();
- entities.put(new String("nbsp"), new Character('\240')); // no-break
+ entities.put("nbsp", new Character('\240')); // no-break
// space =
// non-breaking
// space
- entities.put(new String("iexcl"), new Character('\241')); // inverted
+ entities.put("iexcl", new Character('\241')); // inverted
// exclamation
// mark
- entities.put(new String("cent"), new Character('\242')); // cent sign
- entities.put(new String("pound"), new Character('\243')); // pound
+ entities.put("cent", new Character('\242')); // cent sign
+ entities.put("pound", new Character('\243')); // pound
// sign
- entities.put(new String("curren"), new Character('\244')); // currency
+ entities.put("curren", new Character('\244')); // currency
// sign
- entities.put(new String("yen"), new Character('\245')); // yen sign =
+ entities.put("yen", new Character('\245')); // yen sign =
// yuan sign
- entities.put(new String("brvbar"), new Character('\246')); // broken
+ entities.put("brvbar", new Character('\246')); // broken
// bar =
// broken
// vertical
// bar
- entities.put(new String("sect"), new Character('\247')); // section
+ entities.put("sect", new Character('\247')); // section
// sign
- entities.put(new String("uml"), new Character('\250')); // diaeresis =
+ entities.put("uml", new Character('\250')); // diaeresis =
// spacing
// diaeresis
- entities.put(new String("copy"), new Character('\251')); // copyright
+ entities.put("copy", new Character('\251')); // copyright
// sign
- entities.put(new String("ordf"), new Character('\252')); // feminine
+ entities.put("ordf", new Character('\252')); // feminine
// ordinal
// indicator
- entities.put(new String("laquo"), new Character('\253')); // left-pointing
+ entities.put("laquo", new Character('\253')); // left-pointing
// double
// angle
// quotation
@@ -559,65 +559,65 @@ public class HtmlStreamTokenizer {
// left
// pointing
// guillemet
- entities.put(new String("not"), new Character('\254')); // not sign
- entities.put(new String("shy"), new Character('\255')); // soft hyphen =
+ entities.put("not", new Character('\254')); // not sign
+ entities.put("shy", new Character('\255')); // soft hyphen =
// discretionary
// hyphen
- entities.put(new String("reg"), new Character('\256')); // registered
+ entities.put("reg", new Character('\256')); // registered
// sign =
// registered
// trade mark
// sign
- entities.put(new String("macr"), new Character('\257')); // macron =
+ entities.put("macr", new Character('\257')); // macron =
// spacing
// macron =
// overline
// = APL
// overbar
- entities.put(new String("deg"), new Character('\260')); // degree sign
- entities.put(new String("plusmn"), new Character('\261')); // plus-minus
+ entities.put("deg", new Character('\260')); // degree sign
+ entities.put("plusmn", new Character('\261')); // plus-minus
// sign =
// plus-or-minus
// sign
- entities.put(new String("sup2"), new Character('\262')); // superscript
+ entities.put("sup2", new Character('\262')); // superscript
// two =
// superscript
// digit two
// = squared
- entities.put(new String("sup3"), new Character('\263')); // superscript
+ entities.put("sup3", new Character('\263')); // superscript
// three =
// superscript
// digit
// three =
// cubed
- entities.put(new String("acute"), new Character('\264')); // acute
+ entities.put("acute", new Character('\264')); // acute
// accent =
// spacing
// acute
- entities.put(new String("micro"), new Character('\265')); // micro
+ entities.put("micro", new Character('\265')); // micro
// sign
- entities.put(new String("para"), new Character('\266')); // pilcrow
+ entities.put("para", new Character('\266')); // pilcrow
// sign =
// paragraph
// sign
- entities.put(new String("middot"), new Character('\267')); // middle
+ entities.put("middot", new Character('\267')); // middle
// dot =
// Georgian
// comma =
// Greek
// middle
// dot
- entities.put(new String("cedil"), new Character('\270')); // cedilla =
+ entities.put("cedil", new Character('\270')); // cedilla =
// spacing
// cedilla
- entities.put(new String("sup1"), new Character('\271')); // superscript
+ entities.put("sup1", new Character('\271')); // superscript
// one =
// superscript
// digit one
- entities.put(new String("ordm"), new Character('\272')); // masculine
+ entities.put("ordm", new Character('\272')); // masculine
// ordinal
// indicator
- entities.put(new String("raquo"), new Character('\273')); // right-pointing
+ entities.put("raquo", new Character('\273')); // right-pointing
// double
// angle
// quotation
@@ -625,20 +625,20 @@ public class HtmlStreamTokenizer {
// right
// pointing
// guillemet
- entities.put(new String("frac14"), new Character('\274')); // vulgar
+ entities.put("frac14", new Character('\274')); // vulgar
// fraction
// one
// quarter =
// fraction
// one
// quarter
- entities.put(new String("frac12"), new Character('\275')); // vulgar
+ entities.put("frac12", new Character('\275')); // vulgar
// fraction
// one half
// =
// fraction
// one half
- entities.put(new String("frac34"), new Character('\276')); // vulgar
+ entities.put("frac34", new Character('\276')); // vulgar
// fraction
// three
// quarters
@@ -646,13 +646,13 @@ public class HtmlStreamTokenizer {
// fraction
// three
// quarters
- entities.put(new String("iquest"), new Character('\277')); // inverted
+ entities.put("iquest", new Character('\277')); // inverted
// question
// mark =
// turned
// question
// mark
- entities.put(new String("Agrave"), new Character('\300')); // latin
+ entities.put("Agrave", new Character('\300')); // latin
// capital
// letter A
// with
@@ -661,27 +661,27 @@ public class HtmlStreamTokenizer {
// capital
// letter A
// grave
- entities.put(new String("Aacute"), new Character('\301')); // latin
+ entities.put("Aacute", new Character('\301')); // latin
// capital
// letter A
// with
// acute
- entities.put(new String("Acirc"), new Character('\302')); // latin
+ entities.put("Acirc", new Character('\302')); // latin
// capital
// letter A
// with
// circumflex
- entities.put(new String("Atilde"), new Character('\303')); // latin
+ entities.put("Atilde", new Character('\303')); // latin
// capital
// letter A
// with
// tilde
- entities.put(new String("Auml"), new Character('\304')); // latin
+ entities.put("Auml", new Character('\304')); // latin
// capital
// letter A
// with
// diaeresis
- entities.put(new String("Aring"), new Character('\305')); // latin
+ entities.put("Aring", new Character('\305')); // latin
// capital
// letter A
// with ring
@@ -690,93 +690,93 @@ public class HtmlStreamTokenizer {
// capital
// letter A
// ring
- entities.put(new String("AElig"), new Character('\306')); // latin
+ entities.put("AElig", new Character('\306')); // latin
// capital
// letter AE
// = latin
// capital
// ligature
// AE
- entities.put(new String("Ccedil"), new Character('\307')); // latin
+ entities.put("Ccedil", new Character('\307')); // latin
// capital
// letter C
// with
// cedilla
- entities.put(new String("Egrave"), new Character('\310')); // latin
+ entities.put("Egrave", new Character('\310')); // latin
// capital
// letter E
// with
// grave
- entities.put(new String("Eacute"), new Character('\311')); // latin
+ entities.put("Eacute", new Character('\311')); // latin
// capital
// letter E
// with
// acute
- entities.put(new String("Ecirc"), new Character('\312')); // latin
+ entities.put("Ecirc", new Character('\312')); // latin
// capital
// letter E
// with
// circumflex
- entities.put(new String("Euml"), new Character('\313')); // latin
+ entities.put("Euml", new Character('\313')); // latin
// capital
// letter E
// with
// diaeresis
- entities.put(new String("Igrave"), new Character('\314')); // latin
+ entities.put("Igrave", new Character('\314')); // latin
// capital
// letter I
// with
// grave
- entities.put(new String("Iacute"), new Character('\315')); // latin
+ entities.put("Iacute", new Character('\315')); // latin
// capital
// letter I
// with
// acute
- entities.put(new String("Icirc"), new Character('\316')); // latin
+ entities.put("Icirc", new Character('\316')); // latin
// capital
// letter I
// with
// circumflex
- entities.put(new String("Iuml"), new Character('\317')); // latin
+ entities.put("Iuml", new Character('\317')); // latin
// capital
// letter I
// with
// diaeresis
- entities.put(new String("ETH"), new Character('\320')); // latin capital
+ entities.put("ETH", new Character('\320')); // latin capital
// letter ETH
- entities.put(new String("Ntilde"), new Character('\321')); // latin
+ entities.put("Ntilde", new Character('\321')); // latin
// capital
// letter N
// with
// tilde
- entities.put(new String("Ograve"), new Character('\322')); // latin
+ entities.put("Ograve", new Character('\322')); // latin
// capital
// letter O
// with
// grave
- entities.put(new String("Oacute"), new Character('\323')); // latin
+ entities.put("Oacute", new Character('\323')); // latin
// capital
// letter O
// with
// acute
- entities.put(new String("Ocirc"), new Character('\324')); // latin
+ entities.put("Ocirc", new Character('\324')); // latin
// capital
// letter O
// with
// circumflex
- entities.put(new String("Otilde"), new Character('\325')); // latin
+ entities.put("Otilde", new Character('\325')); // latin
// capital
// letter O
// with
// tilde
- entities.put(new String("Ouml"), new Character('\326')); // latin
+ entities.put("Ouml", new Character('\326')); // latin
// capital
// letter O
// with
// diaeresis
- entities.put(new String("times"), new Character('\327')); // multiplication
+ entities.put("times", new Character('\327')); // multiplication
// sign
- entities.put(new String("Oslash"), new Character('\330')); // latin
+ entities.put("Oslash", new Character('\330')); // latin
// capital
// letter O
// with
@@ -785,41 +785,41 @@ public class HtmlStreamTokenizer {
// capital
// letter O
// slash
- entities.put(new String("Ugrave"), new Character('\331')); // latin
+ entities.put("Ugrave", new Character('\331')); // latin
// capital
// letter U
// with
// grave
- entities.put(new String("Uacute"), new Character('\332')); // latin
+ entities.put("Uacute", new Character('\332')); // latin
// capital
// letter U
// with
// acute
- entities.put(new String("Ucirc"), new Character('\333')); // latin
+ entities.put("Ucirc", new Character('\333')); // latin
// capital
// letter U
// with
// circumflex
- entities.put(new String("Uuml"), new Character('\334')); // latin
+ entities.put("Uuml", new Character('\334')); // latin
// capital
// letter U
// with
// diaeresis
- entities.put(new String("Yacute"), new Character('\335')); // latin
+ entities.put("Yacute", new Character('\335')); // latin
// capital
// letter Y
// with
// acute
- entities.put(new String("THORN"), new Character('\336')); // latin
+ entities.put("THORN", new Character('\336')); // latin
// capital
// letter
// THORN
- entities.put(new String("szlig"), new Character('\337')); // latin
+ entities.put("szlig", new Character('\337')); // latin
// small
// letter
// sharp s =
// ess-zed
- entities.put(new String("agrave"), new Character('\340')); // latin
+ entities.put("agrave", new Character('\340')); // latin
// small
// letter a
// with
@@ -828,27 +828,27 @@ public class HtmlStreamTokenizer {
// small
// letter a
// grave
- entities.put(new String("aacute"), new Character('\341')); // latin
+ entities.put("aacute", new Character('\341')); // latin
// small
// letter a
// with
// acute
- entities.put(new String("acirc"), new Character('\342')); // latin
+ entities.put("acirc", new Character('\342')); // latin
// small
// letter a
// with
// circumflex
- entities.put(new String("atilde"), new Character('\343')); // latin
+ entities.put("atilde", new Character('\343')); // latin
// small
// letter a
// with
// tilde
- entities.put(new String("auml"), new Character('\344')); // latin
+ entities.put("auml", new Character('\344')); // latin
// small
// letter a
// with
// diaeresis
- entities.put(new String("aring"), new Character('\345')); // latin
+ entities.put("aring", new Character('\345')); // latin
// small
// letter a
// with ring
@@ -857,93 +857,93 @@ public class HtmlStreamTokenizer {
// small
// letter a
// ring
- entities.put(new String("aelig"), new Character('\346')); // latin
+ entities.put("aelig", new Character('\346')); // latin
// small
// letter ae
// = latin
// small
// ligature
// ae
- entities.put(new String("ccedil"), new Character('\347')); // latin
+ entities.put("ccedil", new Character('\347')); // latin
// small
// letter c
// with
// cedilla
- entities.put(new String("egrave"), new Character('\350')); // latin
+ entities.put("egrave", new Character('\350')); // latin
// small
// letter e
// with
// grave
- entities.put(new String("eacute"), new Character('\351')); // latin
+ entities.put("eacute", new Character('\351')); // latin
// small
// letter e
// with
// acute
- entities.put(new String("ecirc"), new Character('\352')); // latin
+ entities.put("ecirc", new Character('\352')); // latin
// small
// letter e
// with
// circumflex
- entities.put(new String("euml"), new Character('\353')); // latin
+ entities.put("euml", new Character('\353')); // latin
// small
// letter e
// with
// diaeresis
- entities.put(new String("igrave"), new Character('\354')); // latin
+ entities.put("igrave", new Character('\354')); // latin
// small
// letter i
// with
// grave
- entities.put(new String("iacute"), new Character('\355')); // latin
+ entities.put("iacute", new Character('\355')); // latin
// small
// letter i
// with
// acute
- entities.put(new String("icirc"), new Character('\356')); // latin
+ entities.put("icirc", new Character('\356')); // latin
// small
// letter i
// with
// circumflex
- entities.put(new String("iuml"), new Character('\357')); // latin
+ entities.put("iuml", new Character('\357')); // latin
// small
// letter i
// with
// diaeresis
- entities.put(new String("eth"), new Character('\360')); // latin small
+ entities.put("eth", new Character('\360')); // latin small
// letter eth
- entities.put(new String("ntilde"), new Character('\361')); // latin
+ entities.put("ntilde", new Character('\361')); // latin
// small
// letter n
// with
// tilde
- entities.put(new String("ograve"), new Character('\362')); // latin
+ entities.put("ograve", new Character('\362')); // latin
// small
// letter o
// with
// grave
- entities.put(new String("oacute"), new Character('\363')); // latin
+ entities.put("oacute", new Character('\363')); // latin
// small
// letter o
// with
// acute
- entities.put(new String("ocirc"), new Character('\364')); // latin
+ entities.put("ocirc", new Character('\364')); // latin
// small
// letter o
// with
// circumflex
- entities.put(new String("otilde"), new Character('\365')); // latin
+ entities.put("otilde", new Character('\365')); // latin
// small
// letter o
// with
// tilde
- entities.put(new String("ouml"), new Character('\366')); // latin
+ entities.put("ouml", new Character('\366')); // latin
// small
// letter o
// with
// diaeresis
- entities.put(new String("divide"), new Character('\367')); // division
+ entities.put("divide", new Character('\367')); // division
// sign
- entities.put(new String("oslash"), new Character('\370')); // latin
+ entities.put("oslash", new Character('\370')); // latin
// small
// letter o
// with
@@ -952,56 +952,56 @@ public class HtmlStreamTokenizer {
// small
// letter o
// slash
- entities.put(new String("ugrave"), new Character('\371')); // latin
+ entities.put("ugrave", new Character('\371')); // latin
// small
// letter u
// with
// grave
- entities.put(new String("uacute"), new Character('\372')); // latin
+ entities.put("uacute", new Character('\372')); // latin
// small
// letter u
// with
// acute
- entities.put(new String("ucirc"), new Character('\373')); // latin
+ entities.put("ucirc", new Character('\373')); // latin
// small
// letter u
// with
// circumflex
- entities.put(new String("uuml"), new Character('\374')); // latin
+ entities.put("uuml", new Character('\374')); // latin
// small
// letter u
// with
// diaeresis
- entities.put(new String("yacute"), new Character('\375')); // latin
+ entities.put("yacute", new Character('\375')); // latin
// small
// letter y
// with
// acute
- entities.put(new String("thorn"), new Character('\376')); // latin
+ entities.put("thorn", new Character('\376')); // latin
// small
// letter
// thorn
- entities.put(new String("yuml"), new Character('\377')); // latin
+ entities.put("yuml", new Character('\377')); // latin
// small
// letter y
// with
// diaeresis
// Special characters
- entities.put(new String("quot"), new Character('\42')); // quotation
+ entities.put("quot", new Character('\42')); // quotation
// mark = APL
// quote
- entities.put(new String("amp"), new Character('\46')); // ampersand
- entities.put(new String("lt"), new Character('\74')); // less-than
+ entities.put("amp", new Character('\46')); // ampersand
+ entities.put("lt", new Character('\74')); // less-than
// sign
- entities.put(new String("gt"), new Character('\76')); // greater-than
+ entities.put("gt", new Character('\76')); // greater-than
// sign
// Latin Extended-A
- entities.put(new String("OElig"), new Character('\u0152')); // latin
+ entities.put("OElig", new Character('\u0152')); // latin
// capital
// ligature
// OE
- entities.put(new String("oelig"), new Character('\u0153')); // latin
+ entities.put("oelig", new Character('\u0153')); // latin
// small
// ligature
// oe,
@@ -1013,78 +1013,78 @@ public class HtmlStreamTokenizer {
// character
// in some
// languages
- entities.put(new String("Scaron"), new Character('\u0160')); // latin
+ entities.put("Scaron", new Character('\u0160')); // latin
// capital
// letter
// S
// with
// caron
- entities.put(new String("scaron"), new Character('\u0161')); // latin
+ entities.put("scaron", new Character('\u0161')); // latin
// small
// letter
// s
// with
// caron
- entities.put(new String("Yuml"), new Character('\u0178')); // latin
+ entities.put("Yuml", new Character('\u0178')); // latin
// capital
// letter Y
// with
// diaeresis
// Spacing Modifier Letters
- entities.put(new String("circ"), new Character('\u02c6')); // modifier
+ entities.put("circ", new Character('\u02c6')); // modifier
// letter
// circumflex
// accent
- entities.put(new String("tilde"), new Character('\u02dc')); // small
+ entities.put("tilde", new Character('\u02dc')); // small
// tilde
// General punctuation
- entities.put(new String("ensp"), new Character('\u2002')); // en space
- entities.put(new String("emsp"), new Character('\u2003')); // em space
- entities.put(new String("thinsp"), new Character('\u2009')); // thin
+ entities.put("ensp", new Character('\u2002')); // en space
+ entities.put("emsp", new Character('\u2003')); // em space
+ entities.put("thinsp", new Character('\u2009')); // thin
// space
- entities.put(new String("zwnj"), new Character('\u200c')); // zero
+ entities.put("zwnj", new Character('\u200c')); // zero
// width
// non-joiner
- entities.put(new String("zwj"), new Character('\u200d')); // zero
+ entities.put("zwj", new Character('\u200d')); // zero
// width
// joiner
- entities.put(new String("lrm"), new Character('\u200e')); // left-to-right
+ entities.put("lrm", new Character('\u200e')); // left-to-right
// mark
- entities.put(new String("rlm"), new Character('\u200f')); // right-to-left
+ entities.put("rlm", new Character('\u200f')); // right-to-left
// mark
- entities.put(new String("ndash"), new Character('\u2013')); // en dash
- entities.put(new String("mdash"), new Character('\u2014')); // em dash
- entities.put(new String("lsquo"), new Character('\u2018')); // left
+ entities.put("ndash", new Character('\u2013')); // en dash
+ entities.put("mdash", new Character('\u2014')); // em dash
+ entities.put("lsquo", new Character('\u2018')); // left
// single
// quotation
// mark
- entities.put(new String("rsquo"), new Character('\u2019')); // right
+ entities.put("rsquo", new Character('\u2019')); // right
// single
// quotation
// mark
- entities.put(new String("sbquo"), new Character('\u201a')); // single
+ entities.put("sbquo", new Character('\u201a')); // single
// low-9
// quotation
// mark
- entities.put(new String("ldquo"), new Character('\u201c')); // left
+ entities.put("ldquo", new Character('\u201c')); // left
// double
// quotation
// mark
- entities.put(new String("rdquo"), new Character('\u201d')); // right
+ entities.put("rdquo", new Character('\u201d')); // right
// double
// quotation
// mark
- entities.put(new String("bdquo"), new Character('\u201e')); // double
+ entities.put("bdquo", new Character('\u201e')); // double
// low-9
// quotation
// mark
- entities.put(new String("dagger"), new Character('\u2020')); // dagger
- entities.put(new String("Dagger"), new Character('\u2021')); // double
+ entities.put("dagger", new Character('\u2020')); // dagger
+ entities.put("Dagger", new Character('\u2021')); // double
// dagger
- entities.put(new String("permil"), new Character('\u2030')); // per
+ entities.put("permil", new Character('\u2030')); // per
// mille
// sign
- entities.put(new String("lsaquo"), new Character('\u2039')); // single
+ entities.put("lsaquo", new Character('\u2039')); // single
// left-pointing
// angle
// quotation
@@ -1092,7 +1092,7 @@ public class HtmlStreamTokenizer {
// not
// yet
// standardized
- entities.put(new String("rsaquo"), new Character('\u203a')); // single
+ entities.put("rsaquo", new Character('\u203a')); // single
// right-pointing
// angle
// quotation
@@ -1100,6 +1100,6 @@ public class HtmlStreamTokenizer {
// not
// yet
// standardized
- entities.put(new String("euro"), new Character('\u20ac')); // euro sign
+ entities.put("euro", new Character('\u20ac')); // euro sign
}
}
diff --git a/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/internal/tasks/core/HtmlTag.java b/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/internal/tasks/core/HtmlTag.java
index fc789480c..53cd3b427 100644
--- a/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/internal/tasks/core/HtmlTag.java
+++ b/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/internal/tasks/core/HtmlTag.java
@@ -59,7 +59,7 @@ public class HtmlTag {
tagType = Type.UNKNOWN;
isEndTag = false;
attributes = new HashMap<String, String>();
- tagName = new String(htmltag.tagName);
+ tagName = htmltag.tagName;
baseUrl = htmltag.baseUrl;
tagType = htmltag.tagType;
isEndTag = htmltag.isEndTag;
@@ -275,80 +275,80 @@ public class HtmlTag {
private static HashMap<String, Tag> tags;
static {
tags = new HashMap<String, Tag>();
- tags.put(new String("A"), Tag.A);
- tags.put(new String("ADDRESS"), Tag.ADDRESS);
- tags.put(new String("APPLET"), Tag.APPLET);
- tags.put(new String("AREA"), Tag.AREA);
- tags.put(new String("B"), Tag.B);
- tags.put(new String("BASE"), Tag.BASE);
- tags.put(new String("BASEFONT"), Tag.BASEFONT);
- tags.put(new String("BIG"), Tag.BIG);
- tags.put(new String("BLOCKQUOTE"), Tag.BLOCKQUOTE);
- tags.put(new String("BODY"), Tag.BODY);
- tags.put(new String("BR"), Tag.BR);
- tags.put(new String("CAPTION"), Tag.CAPTION);
- tags.put(new String("CENTER"), Tag.CENTER);
- tags.put(new String("CITE"), Tag.CITE);
- tags.put(new String("CODE"), Tag.CODE);
- tags.put(new String("DD"), Tag.DD);
- tags.put(new String("DFN"), Tag.DFN);
- tags.put(new String("DIR"), Tag.DIR);
- tags.put(new String("DIV"), Tag.DIV);
- tags.put(new String("DL"), Tag.DL);
- tags.put(new String("!DOCTYPE"), Type.DOCTYPE);
- tags.put(new String("DT"), Tag.DT);
- tags.put(new String("EM"), Tag.EM);
- tags.put(new String("FONT"), Tag.FONT);
- tags.put(new String("FORM"), Tag.FORM);
- tags.put(new String("FRAME"), Tag.FRAME);
- tags.put(new String("FRAMESET"), Tag.FRAMESET);
- tags.put(new String("H1"), Tag.H1);
- tags.put(new String("H2"), Tag.H2);
- tags.put(new String("H3"), Tag.H3);
- tags.put(new String("H4"), Tag.H4);
- tags.put(new String("H5"), Tag.H5);
- tags.put(new String("H6"), Tag.H6);
- tags.put(new String("HEAD"), Tag.HEAD);
- tags.put(new String("HTML"), Tag.HTML);
- tags.put(new String("HR"), Tag.HR);
- tags.put(new String("I"), Tag.I);
- tags.put(new String("IMG"), Tag.IMG);
- tags.put(new String("INPUT"), Tag.INPUT);
- tags.put(new String("ISINDEX"), Tag.ISINDEX);
- tags.put(new String("KBD"), Tag.KBD);
- tags.put(new String("LI"), Tag.LI);
- tags.put(new String("LABEL"), Type.LABEL);
- tags.put(new String("LINK"), Tag.LINK);
- tags.put(new String("MAP"), Tag.MAP);
- tags.put(new String("MENU"), Tag.MENU);
- tags.put(new String("META"), Tag.META);
- tags.put(new String("NOFRAMES"), Tag.NOFRAMES);
- tags.put(new String("OBJECT"), Tag.OBJECT);
- tags.put(new String("OL"), Tag.OL);
- tags.put(new String("OPTION"), Tag.OPTION);
- tags.put(new String("P"), Tag.P);
- tags.put(new String("PARAM"), Tag.PARAM);
- tags.put(new String("PRE"), Tag.PRE);
- tags.put(new String("S"), Tag.S);
- tags.put(new String("SAMP"), Tag.SAMP);
- tags.put(new String("SCRIPT"), Tag.SCRIPT);
- tags.put(new String("SELECT"), Tag.SELECT);
- tags.put(new String("SMALL"), Tag.SMALL);
- tags.put(new String("STRONG"), Tag.STRONG);
- tags.put(new String("STYLE"), Tag.STYLE);
- tags.put(new String("SUB"), Tag.SUB);
- tags.put(new String("SUP"), Tag.SUP);
- tags.put(new String("TABLE"), Tag.TABLE);
- tags.put(new String("TD"), Tag.TD);
- tags.put(new String("TEXTAREA"), Tag.TEXTAREA);
- tags.put(new String("TH"), Tag.TH);
- tags.put(new String("THEAD"), Type.THEAD);
- tags.put(new String("TITLE"), Tag.TITLE);
- tags.put(new String("TR"), Tag.TR);
- tags.put(new String("TT"), Tag.TT);
- tags.put(new String("U"), Tag.U);
- tags.put(new String("UL"), Tag.UL);
- tags.put(new String("VAR"), Tag.VAR);
+ tags.put("A", Tag.A);
+ tags.put("ADDRESS", Tag.ADDRESS);
+ tags.put("APPLET", Tag.APPLET);
+ tags.put("AREA", Tag.AREA);
+ tags.put("B", Tag.B);
+ tags.put("BASE", Tag.BASE);
+ tags.put("BASEFONT", Tag.BASEFONT);
+ tags.put("BIG", Tag.BIG);
+ tags.put("BLOCKQUOTE", Tag.BLOCKQUOTE);
+ tags.put("BODY", Tag.BODY);
+ tags.put("BR", Tag.BR);
+ tags.put("CAPTION", Tag.CAPTION);
+ tags.put("CENTER", Tag.CENTER);
+ tags.put("CITE", Tag.CITE);
+ tags.put("CODE", Tag.CODE);
+ tags.put("DD", Tag.DD);
+ tags.put("DFN", Tag.DFN);
+ tags.put("DIR", Tag.DIR);
+ tags.put("DIV", Tag.DIV);
+ tags.put("DL", Tag.DL);
+ tags.put("!DOCTYPE", Type.DOCTYPE);
+ tags.put("DT", Tag.DT);
+ tags.put("EM", Tag.EM);
+ tags.put("FONT", Tag.FONT);
+ tags.put("FORM", Tag.FORM);
+ tags.put("FRAME", Tag.FRAME);
+ tags.put("FRAMESET", Tag.FRAMESET);
+ tags.put("H1", Tag.H1);
+ tags.put("H2", Tag.H2);
+ tags.put("H3", Tag.H3);
+ tags.put("H4", Tag.H4);
+ tags.put("H5", Tag.H5);
+ tags.put("H6", Tag.H6);
+ tags.put("HEAD", Tag.HEAD);
+ tags.put("HTML", Tag.HTML);
+ tags.put("HR", Tag.HR);
+ tags.put("I", Tag.I);
+ tags.put("IMG", Tag.IMG);
+ tags.put("INPUT", Tag.INPUT);
+ tags.put("ISINDEX", Tag.ISINDEX);
+ tags.put("KBD", Tag.KBD);
+ tags.put("LI", Tag.LI);
+ tags.put("LABEL", Type.LABEL);
+ tags.put("LINK", Tag.LINK);
+ tags.put("MAP", Tag.MAP);
+ tags.put("MENU", Tag.MENU);
+ tags.put("META", Tag.META);
+ tags.put("NOFRAMES", Tag.NOFRAMES);
+ tags.put("OBJECT", Tag.OBJECT);
+ tags.put("OL", Tag.OL);
+ tags.put("OPTION", Tag.OPTION);
+ tags.put("P", Tag.P);
+ tags.put("PARAM", Tag.PARAM);
+ tags.put("PRE", Tag.PRE);
+ tags.put("S", Tag.S);
+ tags.put("SAMP", Tag.SAMP);
+ tags.put("SCRIPT", Tag.SCRIPT);
+ tags.put("SELECT", Tag.SELECT);
+ tags.put("SMALL", Tag.SMALL);
+ tags.put("STRONG", Tag.STRONG);
+ tags.put("STYLE", Tag.STYLE);
+ tags.put("SUB", Tag.SUB);
+ tags.put("SUP", Tag.SUP);
+ tags.put("TABLE", Tag.TABLE);
+ tags.put("TD", Tag.TD);
+ tags.put("TEXTAREA", Tag.TEXTAREA);
+ tags.put("TH", Tag.TH);
+ tags.put("THEAD", Type.THEAD);
+ tags.put("TITLE", Tag.TITLE);
+ tags.put("TR", Tag.TR);
+ tags.put("TT", Tag.TT);
+ tags.put("U", Tag.U);
+ tags.put("UL", Tag.UL);
+ tags.put("VAR", Tag.VAR);
}
public void setSelfTerminating(boolean terminating) {
diff --git a/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/internal/tasks/core/TaskRepositoriesExternalizer.java b/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/internal/tasks/core/TaskRepositoriesExternalizer.java
index b679c9e39..c22e2c2ed 100644
--- a/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/internal/tasks/core/TaskRepositoriesExternalizer.java
+++ b/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/internal/tasks/core/TaskRepositoriesExternalizer.java
@@ -65,7 +65,7 @@ public class TaskRepositoriesExternalizer {
reader.setContentHandler(contentHandler);
reader.parse(new InputSource(new FileInputStream(file)));
return contentHandler.getRepositories();
- } catch (Exception e) {
+ } catch (Throwable e) {
file.renameTo(new File(file.getAbsolutePath() + "-save"));
return null;
}
diff --git a/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/.AbstractRepositoryTask.java b/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/.AbstractRepositoryTask.java
index fa22a31c6..1556be9d5 100644
--- a/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/.AbstractRepositoryTask.java
+++ b/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/.AbstractRepositoryTask.java
@@ -114,28 +114,12 @@ public abstract class AbstractRepositoryTask extends Task {
return null;
}
-// public static int getTaskIdAsInt(String taskHandle) {
-// String idString = getTaskId(taskHandle);
-// if (idString != null) {
-// return Integer.parseInt(idString);
-// } else {
-// return -1;
-// }
-// }
-
public static String getRepositoryUrl(String taskHandle) {
int index = taskHandle.lastIndexOf(AbstractRepositoryTask.HANDLE_DELIM);
String url = null;
if (index != -1) {
url = taskHandle.substring(0, index);
}
-// if (url != null && url.equals(TaskRepositoryManager.PREFIX_REPOSITORY_OLD)) {
-// String repositoryKind = TaskRepositoryManager.PREFIX_REPOSITORY_OLD.toLowerCase();
-// TaskRepository repository = MylarTaskListPlugin.getRepositoryManager().getDefaultRepository(repositoryKind);
-// if (repository != null) {
-// url = repository.getUrl();
-// }
-// }
return url;
}
@@ -145,7 +129,6 @@ public abstract class AbstractRepositoryTask extends Task {
} else if (taskId.contains(CONTEXT_HANDLE_DELIM)) {
throw new RuntimeException("invalid handle for task, can not contain: " + CONTEXT_HANDLE_DELIM + ", was: " + taskId);
} else {
- // MylarContextManager.CONTEXT_HANDLE_DELIM + taskId);
return repositoryUrl + CONTEXT_HANDLE_DELIM + taskId;
}
}
diff --git a/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/AbstractRepositoryTask.java b/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/AbstractRepositoryTask.java
index fa22a31c6..1556be9d5 100644
--- a/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/AbstractRepositoryTask.java
+++ b/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/AbstractRepositoryTask.java
@@ -114,28 +114,12 @@ public abstract class AbstractRepositoryTask extends Task {
return null;
}
-// public static int getTaskIdAsInt(String taskHandle) {
-// String idString = getTaskId(taskHandle);
-// if (idString != null) {
-// return Integer.parseInt(idString);
-// } else {
-// return -1;
-// }
-// }
-
public static String getRepositoryUrl(String taskHandle) {
int index = taskHandle.lastIndexOf(AbstractRepositoryTask.HANDLE_DELIM);
String url = null;
if (index != -1) {
url = taskHandle.substring(0, index);
}
-// if (url != null && url.equals(TaskRepositoryManager.PREFIX_REPOSITORY_OLD)) {
-// String repositoryKind = TaskRepositoryManager.PREFIX_REPOSITORY_OLD.toLowerCase();
-// TaskRepository repository = MylarTaskListPlugin.getRepositoryManager().getDefaultRepository(repositoryKind);
-// if (repository != null) {
-// url = repository.getUrl();
-// }
-// }
return url;
}
@@ -145,7 +129,6 @@ public abstract class AbstractRepositoryTask extends Task {
} else if (taskId.contains(CONTEXT_HANDLE_DELIM)) {
throw new RuntimeException("invalid handle for task, can not contain: " + CONTEXT_HANDLE_DELIM + ", was: " + taskId);
} else {
- // MylarContextManager.CONTEXT_HANDLE_DELIM + taskId);
return repositoryUrl + CONTEXT_HANDLE_DELIM + taskId;
}
}
diff --git a/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/DelegatingTaskExternalizer.java b/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/DelegatingTaskExternalizer.java
index c1c3fdb11..cb68431bf 100644
--- a/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/DelegatingTaskExternalizer.java
+++ b/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/tasks/core/DelegatingTaskExternalizer.java
@@ -262,11 +262,11 @@ public class DelegatingTaskExternalizer implements ITaskListExternalizer {
}
if (category != null) {
- if (category.equals(VAL_ROOT)) {
- taskList.internalAddRootTask(task);
- } else {
- taskList.internalAddTask(task, category);
- }
+// if (category.equals(VAL_ROOT)) {
+// taskList.internalAddRootTask(task);
+// } else {
+ taskList.internalAddTask(task, category);
+// }
} else if (parent == null) {
taskList.internalAddRootTask(task);
}
diff --git a/org.eclipse.mylyn.tasks.ui/.cvsignore b/org.eclipse.mylyn.tasks.ui/.cvsignore
index ba077a403..4a98758e6 100644
--- a/org.eclipse.mylyn.tasks.ui/.cvsignore
+++ b/org.eclipse.mylyn.tasks.ui/.cvsignore
@@ -1 +1,2 @@
bin
+.fbwarnings
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/TaskListBackupManager.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/TaskListBackupManager.java
index 38a070662..ba09feff7 100644
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/TaskListBackupManager.java
+++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/TaskListBackupManager.java
@@ -180,7 +180,7 @@ public class TaskListBackupManager implements IPropertyChangeListener {
}
}
- class ExportJob extends Job {
+ static class ExportJob extends Job {
final TaskDataExportJob backupJob;
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/TaskListColorsAndFonts.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/TaskListColorsAndFonts.java
index 025ae1288..33f8eb595 100644
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/TaskListColorsAndFonts.java
+++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/TaskListColorsAndFonts.java
@@ -67,7 +67,7 @@ public class TaskListColorsAndFonts {
Field strikeOutFiled = clazz.getDeclaredField("lfStrikeOut");
strikeOutFiled.set(dataObject, (byte) 1);
STRIKETHROUGH = new Font(Display.getCurrent(), data);
- } catch (Exception e) {
+ } catch (Throwable t) {
// Linux or other platform
STRIKETHROUGH = defaultFont;
}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/TaskListNotificationPopup.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/TaskListNotificationPopup.java
index e194f6b93..8bb686e7c 100644
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/TaskListNotificationPopup.java
+++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/TaskListNotificationPopup.java
@@ -38,20 +38,7 @@ import org.eclipse.ui.forms.widgets.Section;
*/
public class TaskListNotificationPopup extends PopupDialog {
-
- static boolean takeFocusOnOpen = false;
-
- static boolean persistBounds = false;
-
- static boolean showDialogMenu =false;
-
- static boolean showPersistAction = false;
-
- static String titleText;
-
- static final String MYLAR_NOTIFICATION_LABEL = "Mylar Notification";
-
- static String infoText = null;
+ private static final String MYLAR_NOTIFICATION_LABEL = "Mylar Notification";
private FormToolkit toolkit;
@@ -59,13 +46,13 @@ public class TaskListNotificationPopup extends PopupDialog {
private Rectangle bounds;
- List<ITaskListNotification> notifications;
+ private List<ITaskListNotification> notifications;
private Composite sectionClient;
public TaskListNotificationPopup(Shell parent) {
- super(parent, PopupDialog.INFOPOPUP_SHELLSTYLE | SWT.ON_TOP, takeFocusOnOpen, persistBounds, showDialogMenu,
- showPersistAction, titleText, infoText);
+ super(parent, PopupDialog.INFOPOPUP_SHELLSTYLE | SWT.ON_TOP, false, false, false,
+ false, null, null);
}
public void setContents(List<ITaskListNotification> notifications) {
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/TaskListSynchronizationManager.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/TaskListSynchronizationManager.java
index 2e80cb701..7f92d5d65 100644
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/TaskListSynchronizationManager.java
+++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/TaskListSynchronizationManager.java
@@ -124,7 +124,7 @@ public class TaskListSynchronizationManager implements IPropertyChangeListener {
}
}
- class MutexRule implements ISchedulingRule {
+ static class MutexRule implements ISchedulingRule {
public boolean isConflicting(ISchedulingRule rule) {
return rule == this;
}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/actions/SynchronizeSelectedAction.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/actions/SynchronizeSelectedAction.java
index c724ba28b..06677ac17 100644
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/actions/SynchronizeSelectedAction.java
+++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/actions/SynchronizeSelectedAction.java
@@ -34,12 +34,10 @@ import org.eclipse.ui.actions.ActionDelegate;
import org.eclipse.ui.actions.ActionFactory;
/**
- * @author Ken Sueda and Mik Kersten
+ * @author Mik Kersten
*/
public class SynchronizeSelectedAction extends ActionDelegate implements IViewActionDelegate {
- private AbstractRepositoryQuery query = null;
-
private void checkSyncResult(final IJobChangeEvent event, final AbstractRepositoryQuery problemQuery) {
if (event.getResult().getException() != null) {
PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable() {
@@ -52,17 +50,7 @@ public class SynchronizeSelectedAction extends ActionDelegate implements IViewAc
}
public void run(IAction action) {
- if (query != null) {
- AbstractRepositoryConnector connector = TasksUiPlugin.getRepositoryManager().getRepositoryConnector(
- query.getRepositoryKind());
- if (connector != null)
- connector.synchronize(query, new JobChangeAdapter() {
- public void done(IJobChangeEvent event) {
- checkSyncResult(event, query);
- }
- });
-
- } else if (TaskListView.getFromActivePerspective() != null) {
+ if (TaskListView.getFromActivePerspective() != null) {
ISelection selection = TaskListView.getFromActivePerspective().getViewer().getSelection();
for (Object obj : ((IStructuredSelection) selection).toList()) {
if (obj instanceof AbstractRepositoryQuery) {
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/AbstractRepositoryTaskEditor.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/AbstractRepositoryTaskEditor.java
index 4d096665d..22ce345ad 100644
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/AbstractRepositoryTaskEditor.java
+++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/AbstractRepositoryTaskEditor.java
@@ -334,7 +334,7 @@ public abstract class AbstractRepositoryTaskEditor extends EditorPart {
}
- private final class AttachmentTableLabelProvider extends DecoratingLabelProvider implements ITableColorProvider,
+ private static final class AttachmentTableLabelProvider extends DecoratingLabelProvider implements ITableColorProvider,
ITableLabelProvider {
public AttachmentTableLabelProvider(ILabelProvider provider, ILabelDecorator decorator) {
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/ExistingBugEditorInput.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/ExistingBugEditorInput.java
index 0847582be..3d5b1af5e 100644
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/ExistingBugEditorInput.java
+++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/ExistingBugEditorInput.java
@@ -89,18 +89,33 @@ public class ExistingBugEditorInput extends AbstractBugEditorInput {
return id;
}
- /**
- * @return <code>true</code> if the argument is a bug report editor input
- * on the same bug id.
- */
+
@Override
- public boolean equals(Object o) {
- // XXX: will equate two tasks with identical ids from different repositories
- if (o instanceof ExistingBugEditorInput) {
- ExistingBugEditorInput input = (ExistingBugEditorInput) o;
- return getId().equals(input.getId());
- }
- return false;
+ public int hashCode() {
+ final int PRIME = 31;
+ int result = 1;
+ result = PRIME * result + ((repositoryTask == null) ? 0 : repositoryTask.hashCode());
+ return result;
+ }
+
+
+ @Override
+ public boolean equals(Object obj) {
+ if (this == obj)
+ return true;
+ if (obj == null)
+ return false;
+ if (getClass() != obj.getClass())
+ return false;
+ final ExistingBugEditorInput other = (ExistingBugEditorInput) obj;
+ if (repositoryTask == null) {
+ if (other.repositoryTask != null)
+ return false;
+ } else if (!repositoryTask.equals(other.repositoryTask))
+ return false;
+ return true;
}
+
+
}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/RepositoryTaskOutlinePage.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/RepositoryTaskOutlinePage.java
index a49e1e82d..177634047 100644
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/RepositoryTaskOutlinePage.java
+++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/RepositoryTaskOutlinePage.java
@@ -131,7 +131,7 @@ public class RepositoryTaskOutlinePage extends ContentOutlinePage {
*
* @see ITreeContentProvider
*/
- protected class BugTaskOutlineContentProvider implements ITreeContentProvider {
+ protected static class BugTaskOutlineContentProvider implements ITreeContentProvider {
public Object[] getChildren(Object parentElement) {
if (parentElement instanceof RepositoryTaskOutlineNode) {
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/RepositoryTextViewer.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/RepositoryTextViewer.java
index bebab78e4..db4a1cafd 100644
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/RepositoryTextViewer.java
+++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/RepositoryTextViewer.java
@@ -98,7 +98,7 @@ public class RepositoryTextViewer extends SourceViewer {
}
}
- class RepositoryTextScanner extends RuleBasedScanner {
+ static class RepositoryTextScanner extends RuleBasedScanner {
private Color URL_COLOR = new Color(Display.getCurrent(), new RGB(0, 0, 200));
public RepositoryTextScanner() {
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/TaskEditorInput.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/TaskEditorInput.java
index 0e094b3aa..fc645fddc 100644
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/TaskEditorInput.java
+++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/TaskEditorInput.java
@@ -119,17 +119,29 @@ public class TaskEditorInput implements IEditorInput {
return label;
}
- /**
- * Returns true if the argument is a bug report editor input on the same bug
- * id.
- */
@Override
- public boolean equals(Object o) {
- if (o instanceof TaskEditorInput) {
- TaskEditorInput input = (TaskEditorInput) o;
- return getId() != null && getId().equals(input.getId());
- }
- return false;
+ public int hashCode() {
+ final int PRIME = 31;
+ int result = 1;
+ result = PRIME * result + ((task == null) ? 0 : task.hashCode());
+ return result;
+ }
+
+ @Override
+ public boolean equals(Object obj) {
+ if (this == obj)
+ return true;
+ if (obj == null)
+ return false;
+ if (getClass() != obj.getClass())
+ return false;
+ final TaskEditorInput other = (TaskEditorInput) obj;
+ if (task == null) {
+ if (other.task != null)
+ return false;
+ } else if (!task.equals(other.task))
+ return false;
+ return true;
}
public boolean isNewTask() {
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/TaskEditorUrlHyperlinkDetector.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/TaskEditorUrlHyperlinkDetector.java
index cd9a37f3d..acd01d3c7 100644
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/TaskEditorUrlHyperlinkDetector.java
+++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/TaskEditorUrlHyperlinkDetector.java
@@ -96,7 +96,7 @@ public class TaskEditorUrlHyperlinkDetector implements IHyperlinkDetector {
return new TaskEditorUrlHyperlink(sregion, m.group());
}
- class TaskEditorUrlHyperlink extends URLHyperlink {
+ static class TaskEditorUrlHyperlink extends URLHyperlink {
public TaskEditorUrlHyperlink(IRegion region, String urlString) {
super(region, urlString);
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/planner/DateSelectionDialog.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/planner/DateSelectionDialog.java
index ec3dbcf1e..dde756e45 100644
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/planner/DateSelectionDialog.java
+++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/planner/DateSelectionDialog.java
@@ -33,7 +33,9 @@ import org.eclipse.swt.widgets.Shell;
public class DateSelectionDialog extends Dialog {
private Date reminderDate = null;
+
private String title = "Date Selection";
+
private Calendar initialCalendar = GregorianCalendar.getInstance();
public DateSelectionDialog(Shell parentShell, String title) {
@@ -42,10 +44,10 @@ public class DateSelectionDialog extends Dialog {
public DateSelectionDialog(Shell parentShell, Calendar initialDate, String title) {
super(parentShell);
- if(title != null) {
+ if (title != null) {
this.title = title;
}
- if(initialDate != null) {
+ if (initialDate != null) {
this.initialCalendar.setTime(initialDate.getTime());
}
reminderDate = initialCalendar.getTime();
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/planner/TaskActivityContentProvider.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/planner/TaskActivityContentProvider.java
index b356f6fca..3be045f08 100644
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/planner/TaskActivityContentProvider.java
+++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/planner/TaskActivityContentProvider.java
@@ -18,41 +18,40 @@ import org.eclipse.jface.viewers.IStructuredContentProvider;
import org.eclipse.jface.viewers.Viewer;
import org.eclipse.mylar.tasks.core.ITask;
+/**
+ * @author Rob Elves
+ */
public class TaskActivityContentProvider implements IStructuredContentProvider, ITaskPlannerContentProvider {
- TaskActivityEditorInput editorInput;
- Viewer viewer;
-
+ private TaskActivityEditorInput editorInput;
+
public TaskActivityContentProvider(TaskActivityEditorInput editorInput) {
this.editorInput = editorInput;
}
-
-
- public Object[] getElements(Object inputElement) {
+
+ public Object[] getElements(Object inputElement) {
List<ITask> allTasks = new ArrayList<ITask>();
allTasks.addAll(editorInput.getCompletedTasks());
- allTasks.addAll(editorInput.getInProgressTasks());
+ allTasks.addAll(editorInput.getInProgressTasks());
return allTasks.toArray();
}
public void dispose() {
// ignore
-
+
}
public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
- this.viewer = viewer;
+ // ignore
}
-
public void removeTask(ITask task) {
editorInput.removeCompletedTask(task);
- editorInput.removeInProgressTask(task);
+ editorInput.removeInProgressTask(task);
}
-
public void addTask(ITask task) {
- // ignore
+ // ignore
}
-
+
}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/views/TaskListView.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/views/TaskListView.java
index 77e39852d..76c44be4b 100644
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/views/TaskListView.java
+++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/views/TaskListView.java
@@ -150,7 +150,7 @@ public class TaskListView extends ViewPart {
private static final String LABEL_NO_TASKS = "no task active";
- public static final String[] PRIORITY_LEVELS = { Task.PriorityLevel.P1.toString(),
+ static final String[] PRIORITY_LEVELS = { Task.PriorityLevel.P1.toString(),
Task.PriorityLevel.P2.toString(), Task.PriorityLevel.P3.toString(), Task.PriorityLevel.P4.toString(),
Task.PriorityLevel.P5.toString() };
@@ -616,7 +616,7 @@ public class TaskListView extends ViewPart {
if (task == null) {
return Boolean.TRUE;
} else {
- return new Boolean(task.isCompleted());
+ return Boolean.valueOf(task.isCompleted());
}
case 1:
return "";
@@ -633,7 +633,7 @@ public class TaskListView extends ViewPart {
AbstractTaskContainer cat = (AbstractTaskContainer) element;
switch (columnIndex) {
case 0:
- return new Boolean(false);
+ return Boolean.FALSE;
case 1:
return "";
case 2:
@@ -645,7 +645,7 @@ public class TaskListView extends ViewPart {
AbstractRepositoryQuery cat = (AbstractRepositoryQuery) element;
switch (columnIndex) {
case 0:
- return new Boolean(false);
+ return Boolean.FALSE;
case 1:
return "";
case 2:
@@ -1060,8 +1060,7 @@ public class TaskListView extends ViewPart {
task = (ITask) element;
}
addAction(openWithBrowser, manager, element);
- if (!(element instanceof AbstractRepositoryTask) || element instanceof AbstractTaskContainer
- || element instanceof AbstractRepositoryQuery) {
+ if (!(element instanceof AbstractRepositoryTask) || element instanceof AbstractTaskContainer) {
addAction(renameAction, manager, element);
}
addAction(copyDetailsAction, manager, element);
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/views/TaskRepositoriesView.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/views/TaskRepositoriesView.java
index 8782fea34..d180d6f34 100644
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/views/TaskRepositoriesView.java
+++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/views/TaskRepositoriesView.java
@@ -72,7 +72,7 @@ public class TaskRepositoriesView extends ViewPart {
}
};
- class ViewContentProvider implements IStructuredContentProvider {
+ static class ViewContentProvider implements IStructuredContentProvider {
public void inputChanged(Viewer v, Object oldInput, Object newInput) {
}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/wizards/AbstractRepositorySettingsPage.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/wizards/AbstractRepositorySettingsPage.java
index d4cb2c1fe..33848684b 100644
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/wizards/AbstractRepositorySettingsPage.java
+++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/wizards/AbstractRepositorySettingsPage.java
@@ -254,7 +254,7 @@ public abstract class AbstractRepositorySettingsPage extends WizardPage {
if (repository != null) {
try {
String repositoryEncoding = repository.getCharacterEncoding();
- if (repositoryEncoding != null && !repositoryEncoding.equals(defaultEncoding)) {
+ if (repositoryEncoding != null) {// && !repositoryEncoding.equals(defaultEncoding)) {
if (otherEncodingCombo.getItemCount() > 0
&& otherEncodingCombo.indexOf(repositoryEncoding) > -1) {
otherEncodingCombo.setEnabled(true);
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/wizards/SelectRepositoryClientPage.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/wizards/SelectRepositoryClientPage.java
index d0a10fc6b..148789303 100644
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/wizards/SelectRepositoryClientPage.java
+++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/wizards/SelectRepositoryClientPage.java
@@ -39,7 +39,7 @@ public class SelectRepositoryClientPage extends WizardPage {
private AbstractRepositoryClientWizard wizard;
- class RepositoryContentProvider implements IStructuredContentProvider {
+ static class RepositoryContentProvider implements IStructuredContentProvider {
public void inputChanged(Viewer v, Object oldInput, Object newInput) {
}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/wizards/TaskDataImportWizardPage.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/wizards/TaskDataImportWizardPage.java
index 3942b3ac6..64db4b08f 100644
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/wizards/TaskDataImportWizardPage.java
+++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/wizards/TaskDataImportWizardPage.java
@@ -286,13 +286,12 @@ public class TaskDataImportWizardPage extends WizardPage {
}
});
- }
-
- for (File file : backupFileArray) {
- TableItem item = new TableItem(backupFilesTable, SWT.NONE);
- item.setData(file.getAbsolutePath());
- Date fileModified = new Date(file.lastModified());
- item.setText(new String[] { DateUtil.formatDate(fileModified, DateUtil.PATTERN_RFC1123) });
+ for (File file : backupFileArray) {
+ TableItem item = new TableItem(backupFilesTable, SWT.NONE);
+ item.setData(file.getAbsolutePath());
+ Date fileModified = new Date(file.lastModified());
+ item.setText(new String[] { DateUtil.formatDate(fileModified, DateUtil.PATTERN_RFC1123) });
+ }
}
backupFilesTable.addSelectionListener(new SelectionAdapter() {
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/AbstractRepositoryConnector.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/AbstractRepositoryConnector.java
index 5c7c9908c..f2e9c1ade 100644
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/AbstractRepositoryConnector.java
+++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/AbstractRepositoryConnector.java
@@ -291,12 +291,12 @@ public abstract class AbstractRepositoryConnector {
updateLocalCopy = MessageDialog
.openQuestion(
null,
- "Update Local Copy",
- "Local copy of Report "
+ "Local Task Conflicts with Repository",
+ "Local copy of: "
+ repositoryTask.getDescription()
- + " on "
+ + "\n\n on: "
+ repositoryTask.getRepositoryUrl()
- + " has changes.\nWould you like to override local changes? \n\nNote: if you select No, only the new comment will be saved with the updated bug, all other changes will be lost.");
+ + "\n\n has changes, override local? \n\nNOTE: if you select No, only the new comment will be saved with the updated bug, all other changes will be lost.");
}
});
} else {
@@ -602,7 +602,7 @@ public abstract class AbstractRepositoryConnector {
TasksUiPlugin.TITLE_DIALOG, "Not supported by connector: " + getLabel());
}
- private class MutexRule implements ISchedulingRule {
+ private static class MutexRule implements ISchedulingRule {
public boolean isConflicting(ISchedulingRule rule) {
return rule == this;
}

Back to the top