Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorcvs2git2005-06-30 19:43:22 +0000
committercvs2git2005-06-30 19:43:22 +0000
commitededde775f59c5b7365f3d67a8ecf8d02dc45941 (patch)
tree008459f45e35998f80f7addb51856f4cc68476f4
parentc323392d4d4ddd8c7b5e790d6e8597e1ab7a66a9 (diff)
downloadorg.eclipse.mylyn.tasks-R_1_7_5.tar.gz
org.eclipse.mylyn.tasks-R_1_7_5.tar.xz
org.eclipse.mylyn.tasks-R_1_7_5.zip
This commit was manufactured by cvs2svn to create tag 'R_1_7_5'.R_1_7_5
Sprout from master 2005-06-30 19:43:21 UTC sminto 'bugzilla 1.7.5 release' Delete: org.eclipse.mylyn-feature/.project org.eclipse.mylyn-feature/build.properties org.eclipse.mylyn-feature/epl-v10.html org.eclipse.mylyn-feature/feature.xml org.eclipse.mylyn-feature/license.html org.eclipse.mylyn.bugzilla.tests/.classpath org.eclipse.mylyn.bugzilla.tests/.cvsignore org.eclipse.mylyn.bugzilla.tests/.project org.eclipse.mylyn.bugzilla.tests/.settings/org.eclipse.jdt.core.prefs org.eclipse.mylyn.bugzilla.tests/META-INF/MANIFEST.MF org.eclipse.mylyn.bugzilla.tests/TestPages/bug-1-full.html org.eclipse.mylyn.bugzilla.tests/TestPages/bug-not-found-eclipse.html org.eclipse.mylyn.bugzilla.tests/TestPages/bug-not-found-hipikat.html org.eclipse.mylyn.bugzilla.tests/TestPages/cdt-page.html org.eclipse.mylyn.bugzilla.tests/TestPages/equinox-page.html org.eclipse.mylyn.bugzilla.tests/TestPages/gmt-page.html org.eclipse.mylyn.bugzilla.tests/TestPages/hipikat-copy-bug-1-full.html org.eclipse.mylyn.bugzilla.tests/TestPages/platform-page.html org.eclipse.mylyn.bugzilla.tests/TestPages/product-page-1-product-hipikat.html org.eclipse.mylyn.bugzilla.tests/TestPages/product-page.html org.eclipse.mylyn.bugzilla.tests/TestPages/ve-page.html org.eclipse.mylyn.bugzilla.tests/about.html org.eclipse.mylyn.bugzilla.tests/build.properties org.eclipse.mylyn.bugzilla.tests/plugin.xml org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/AllTests.java org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaNewBugParserTestCDT.java org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaNewBugParserTestEquinox.java org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaNewBugParserTestGMT.java org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaNewBugParserTestPlatform.java org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaNewBugParserTestVE.java org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaParserTest.java org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaParserTestNoBug.java org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaProductParser1ProductHipikatTest.java org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaProductParserTest.java org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaTestPlugin.java org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/FileTool.java org.eclipse.mylyn.help.ui/.classpath org.eclipse.mylyn.help.ui/.cvsignore org.eclipse.mylyn.help.ui/.project org.eclipse.mylyn.help.ui/.settings/org.eclipse.jdt.core.prefs org.eclipse.mylyn.help.ui/META-INF/MANIFEST.MF org.eclipse.mylyn.help.ui/about.html org.eclipse.mylyn.help.ui/build.properties org.eclipse.mylyn.help.ui/plugin.xml org.eclipse.mylyn.help.ui/src/org/eclipse/mylyn/doc/MylarDocPlugin.java org.eclipse.mylyn.help.ui/toc.xml org.eclipse.mylyn.tasks.tests/.classpath org.eclipse.mylyn.tasks.tests/.cvsignore org.eclipse.mylyn.tasks.tests/.project org.eclipse.mylyn.tasks.tests/.settings/org.eclipse.jdt.core.prefs org.eclipse.mylyn.tasks.tests/META-INF/MANIFEST.MF org.eclipse.mylyn.tasks.tests/about.html org.eclipse.mylyn.tasks.tests/build.properties org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/bugzilla/tests/BugzillaSearchPluginTest.java org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/bugzilla/tests/BugzillaStackTraceTest.java org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/bugzilla/tests/MylarBugzillaTestsPlugin.java org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/Job.java org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/MylarTasksTestsPlugin.java org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/People.java org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/Person.java org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/TaskListManagerTest.java org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/TaskListUiTest.java org.eclipse.mylyn.tasks.ui/.classpath org.eclipse.mylyn.tasks.ui/.cvsignore org.eclipse.mylyn.tasks.ui/.project org.eclipse.mylyn.tasks.ui/.settings/org.eclipse.jdt.core.prefs org.eclipse.mylyn.tasks.ui/META-INF/MANIFEST.MF org.eclipse.mylyn.tasks.ui/about.html org.eclipse.mylyn.tasks.ui/build.properties org.eclipse.mylyn.tasks.ui/icons/elcl16/delete.gif org.eclipse.mylyn.tasks.ui/icons/elcl16/refresh.gif org.eclipse.mylyn.tasks.ui/icons/elcl16/remove.gif org.eclipse.mylyn.tasks.ui/icons/eview16/task-bug.gif org.eclipse.mylyn.tasks.ui/icons/eview16/task-list.gif org.eclipse.mylyn.tasks.ui/icons/eview16/task.gif org.eclipse.mylyn.tasks.ui/plugin.xml org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/AbstractCategory.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/BugzillaHit.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/BugzillaQueryCategory.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/BugzillaTask.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ITask.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ITaskActivityListener.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ITaskInfo.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ITaskListElement.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/MylarTasksPlugin.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/RelatedLinks.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/Task.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/TaskCategory.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/TaskList.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/TaskListManager.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaCacheFile.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaContentProvider.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaEditingMonitor.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaMylarBridge.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaReferencesProvider.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaReportNode.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaStructureBridge.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/StackTrace.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/Util.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/search/BugzillaCategorySearchOperation.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/search/BugzillaMylarSearch.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/search/BugzillaMylarSearchJob.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/search/BugzillaMylarSearchOperation.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/search/BugzillaResultCollector.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/ui/BugzillaNodeLabelProvider.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/ui/BugzillaUiBridge.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/BugzillaTaskEditor.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/BugzillaTaskEditorInput.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/TaskEditor.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/TaskEditorCopyAction.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/TaskEditorInput.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/TaskSummaryEditor.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/ClearContextAction.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/CreateBugzillaQueryCategoryAction.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/CreateBugzillaTaskAction.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/CreateCategoryAction.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/CreateTaskAction.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/DeleteAction.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/FilterCompletedTasksAction.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/MarkTaskCompleteAction.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/MarkTaskIncompleteAction.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/MoveTaskToRootAction.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/OpenTaskEditorAction.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/RefreshBugzillaReportsAction.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/TaskActivateAction.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/TaskDeactivateAction.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/ToggleIntersectionModeAction.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/views/BugzillaQueryDialog.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/views/TaskListLabelProvider.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/views/TaskListView.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/views/ToolTipHandler.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/util/RelativePathUtil.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/util/TaskTest.java org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/util/XmlUtil.java
-rw-r--r--org.eclipse.mylyn-feature/.project17
-rw-r--r--org.eclipse.mylyn-feature/build.properties12
-rw-r--r--org.eclipse.mylyn-feature/epl-v10.html328
-rw-r--r--org.eclipse.mylyn-feature/feature.xml279
-rw-r--r--org.eclipse.mylyn-feature/license.html73
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/.classpath7
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/.cvsignore1
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/.project28
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/.settings/org.eclipse.jdt.core.prefs12
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/META-INF/MANIFEST.MF19
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/TestPages/bug-1-full.html719
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/TestPages/bug-not-found-eclipse.html158
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/TestPages/bug-not-found-hipikat.html142
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/TestPages/cdt-page.html184
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/TestPages/equinox-page.html177
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/TestPages/gmt-page.html175
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/TestPages/hipikat-copy-bug-1-full.html157
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/TestPages/platform-page.html299
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/TestPages/product-page-1-product-hipikat.html256
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/TestPages/product-page.html237
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/TestPages/ve-page.html178
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/about.html22
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/build.properties23
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/plugin.xml6
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/AllTests.java42
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaNewBugParserTestCDT.java231
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaNewBugParserTestEquinox.java216
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaNewBugParserTestGMT.java217
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaNewBugParserTestPlatform.java243
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaNewBugParserTestVE.java223
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaParserTest.java215
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaParserTestNoBug.java46
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaProductParser1ProductHipikatTest.java68
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaProductParserTest.java80
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaTestPlugin.java96
-rw-r--r--org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/FileTool.java256
-rw-r--r--org.eclipse.mylyn.help.ui/.classpath7
-rw-r--r--org.eclipse.mylyn.help.ui/.cvsignore1
-rw-r--r--org.eclipse.mylyn.help.ui/.project28
-rw-r--r--org.eclipse.mylyn.help.ui/.settings/org.eclipse.jdt.core.prefs12
-rw-r--r--org.eclipse.mylyn.help.ui/META-INF/MANIFEST.MF14
-rw-r--r--org.eclipse.mylyn.help.ui/about.html22
-rw-r--r--org.eclipse.mylyn.help.ui/build.properties22
-rw-r--r--org.eclipse.mylyn.help.ui/plugin.xml15
-rw-r--r--org.eclipse.mylyn.help.ui/src/org/eclipse/mylyn/doc/MylarDocPlugin.java66
-rw-r--r--org.eclipse.mylyn.help.ui/toc.xml5
-rw-r--r--org.eclipse.mylyn.tasks.tests/.classpath11
-rw-r--r--org.eclipse.mylyn.tasks.tests/.cvsignore1
-rw-r--r--org.eclipse.mylyn.tasks.tests/.project28
-rw-r--r--org.eclipse.mylyn.tasks.tests/.settings/org.eclipse.jdt.core.prefs12
-rw-r--r--org.eclipse.mylyn.tasks.tests/META-INF/MANIFEST.MF21
-rw-r--r--org.eclipse.mylyn.tasks.tests/about.html22
-rw-r--r--org.eclipse.mylyn.tasks.tests/build.properties15
-rw-r--r--org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/bugzilla/tests/BugzillaSearchPluginTest.java328
-rw-r--r--org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/bugzilla/tests/BugzillaStackTraceTest.java170
-rw-r--r--org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/bugzilla/tests/MylarBugzillaTestsPlugin.java49
-rw-r--r--org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/Job.java87
-rw-r--r--org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/MylarTasksTestsPlugin.java49
-rw-r--r--org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/People.java67
-rw-r--r--org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/Person.java106
-rw-r--r--org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/TaskListManagerTest.java93
-rw-r--r--org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/TaskListUiTest.java263
-rw-r--r--org.eclipse.mylyn.tasks.ui/.classpath11
-rw-r--r--org.eclipse.mylyn.tasks.ui/.cvsignore1
-rw-r--r--org.eclipse.mylyn.tasks.ui/.project30
-rw-r--r--org.eclipse.mylyn.tasks.ui/.settings/org.eclipse.jdt.core.prefs12
-rw-r--r--org.eclipse.mylyn.tasks.ui/META-INF/MANIFEST.MF33
-rw-r--r--org.eclipse.mylyn.tasks.ui/about.html22
-rw-r--r--org.eclipse.mylyn.tasks.ui/build.properties24
-rw-r--r--org.eclipse.mylyn.tasks.ui/icons/elcl16/delete.gifbin351 -> 0 bytes
-rw-r--r--org.eclipse.mylyn.tasks.ui/icons/elcl16/refresh.gifbin216 -> 0 bytes
-rw-r--r--org.eclipse.mylyn.tasks.ui/icons/elcl16/remove.gifbin163 -> 0 bytes
-rw-r--r--org.eclipse.mylyn.tasks.ui/icons/eview16/task-bug.gifbin341 -> 0 bytes
-rw-r--r--org.eclipse.mylyn.tasks.ui/icons/eview16/task-list.gifbin345 -> 0 bytes
-rw-r--r--org.eclipse.mylyn.tasks.ui/icons/eview16/task.gifbin218 -> 0 bytes
-rw-r--r--org.eclipse.mylyn.tasks.ui/plugin.xml34
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/AbstractCategory.java60
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/BugzillaHit.java91
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/BugzillaQueryCategory.java155
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/BugzillaTask.java471
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ITask.java97
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ITaskActivityListener.java30
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ITaskInfo.java23
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ITaskListElement.java29
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/MylarTasksPlugin.java356
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/RelatedLinks.java37
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/Task.java298
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/TaskCategory.java72
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/TaskList.java194
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/TaskListManager.java163
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaCacheFile.java131
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaContentProvider.java59
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaEditingMonitor.java46
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaMylarBridge.java142
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaReferencesProvider.java142
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaReportNode.java184
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaStructureBridge.java278
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/StackTrace.java375
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/Util.java226
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/search/BugzillaCategorySearchOperation.java138
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/search/BugzillaMylarSearch.java148
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/search/BugzillaMylarSearchJob.java109
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/search/BugzillaMylarSearchOperation.java526
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/search/BugzillaResultCollector.java182
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/ui/BugzillaNodeLabelProvider.java67
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/ui/BugzillaUiBridge.java141
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/BugzillaTaskEditor.java291
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/BugzillaTaskEditorInput.java135
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/TaskEditor.java161
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/TaskEditorCopyAction.java33
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/TaskEditorInput.java113
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/TaskSummaryEditor.java1261
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/ClearContextAction.java55
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/CreateBugzillaQueryCategoryAction.java71
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/CreateBugzillaTaskAction.java77
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/CreateCategoryAction.java47
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/CreateTaskAction.java66
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/DeleteAction.java89
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/FilterCompletedTasksAction.java50
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/MarkTaskCompleteAction.java47
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/MarkTaskIncompleteAction.java46
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/MoveTaskToRootAction.java57
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/OpenTaskEditorAction.java80
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/RefreshBugzillaReportsAction.java127
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/TaskActivateAction.java37
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/TaskDeactivateAction.java37
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/ToggleIntersectionModeAction.java42
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/views/BugzillaQueryDialog.java225
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/views/TaskListLabelProvider.java235
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/views/TaskListView.java1307
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/views/ToolTipHandler.java240
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/util/RelativePathUtil.java41
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/util/TaskTest.java146
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/util/XmlUtil.java693
134 files changed, 0 insertions, 17902 deletions
diff --git a/org.eclipse.mylyn-feature/.project b/org.eclipse.mylyn-feature/.project
deleted file mode 100644
index 11fcd6a03..000000000
--- a/org.eclipse.mylyn-feature/.project
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.mylar-feature</name>
- <comment></comment>
- <projects>
- </projects>
- <buildSpec>
- <buildCommand>
- <name>org.eclipse.pde.FeatureBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- </buildSpec>
- <natures>
- <nature>org.eclipse.pde.FeatureNature</nature>
- </natures>
-</projectDescription>
diff --git a/org.eclipse.mylyn-feature/build.properties b/org.eclipse.mylyn-feature/build.properties
deleted file mode 100644
index e2a3d457d..000000000
--- a/org.eclipse.mylyn-feature/build.properties
+++ /dev/null
@@ -1,12 +0,0 @@
-###############################################################################
-# Copyright (c) 2004 - 2005 University Of British Columbia and others.
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Eclipse Public License v1.0
-# which accompanies this distribution, and is available at
-# http://www.eclipse.org/legal/epl-v10.html
-#
-# Contributors:
-# University Of British Columbia - initial API and implementation
-###############################################################################
-bin.includes = feature.xml
-src.includes = feature.xml
diff --git a/org.eclipse.mylyn-feature/epl-v10.html b/org.eclipse.mylyn-feature/epl-v10.html
deleted file mode 100644
index ed4b19665..000000000
--- a/org.eclipse.mylyn-feature/epl-v10.html
+++ /dev/null
@@ -1,328 +0,0 @@
-<html xmlns:o="urn:schemas-microsoft-com:office:office"
-xmlns:w="urn:schemas-microsoft-com:office:word"
-xmlns="http://www.w3.org/TR/REC-html40">
-
-<head>
-<meta http-equiv=Content-Type content="text/html; charset=windows-1252">
-<meta name=ProgId content=Word.Document>
-<meta name=Generator content="Microsoft Word 9">
-<meta name=Originator content="Microsoft Word 9">
-<link rel=File-List
-href="./Eclipse%20EPL%202003_11_10%20Final_files/filelist.xml">
-<title>Eclipse Public License - Version 1.0</title>
-<!--[if gte mso 9]><xml>
- <o:DocumentProperties>
- <o:Revision>2</o:Revision>
- <o:TotalTime>3</o:TotalTime>
- <o:Created>2004-03-05T23:03:00Z</o:Created>
- <o:LastSaved>2004-03-05T23:03:00Z</o:LastSaved>
- <o:Pages>4</o:Pages>
- <o:Words>1626</o:Words>
- <o:Characters>9270</o:Characters>
- <o:Lines>77</o:Lines>
- <o:Paragraphs>18</o:Paragraphs>
- <o:CharactersWithSpaces>11384</o:CharactersWithSpaces>
- <o:Version>9.4402</o:Version>
- </o:DocumentProperties>
-</xml><![endif]--><!--[if gte mso 9]><xml>
- <w:WordDocument>
- <w:TrackRevisions/>
- </w:WordDocument>
-</xml><![endif]-->
-<style>
-<!--
- /* Font Definitions */
-@font-face
- {font-family:Tahoma;
- panose-1:2 11 6 4 3 5 4 4 2 4;
- mso-font-charset:0;
- mso-generic-font-family:swiss;
- mso-font-pitch:variable;
- mso-font-signature:553679495 -2147483648 8 0 66047 0;}
- /* Style Definitions */
-p.MsoNormal, li.MsoNormal, div.MsoNormal
- {mso-style-parent:"";
- margin:0in;
- margin-bottom:.0001pt;
- mso-pagination:widow-orphan;
- font-size:12.0pt;
- font-family:"Times New Roman";
- mso-fareast-font-family:"Times New Roman";}
-p
- {margin-right:0in;
- mso-margin-top-alt:auto;
- mso-margin-bottom-alt:auto;
- margin-left:0in;
- mso-pagination:widow-orphan;
- font-size:12.0pt;
- font-family:"Times New Roman";
- mso-fareast-font-family:"Times New Roman";}
-p.BalloonText, li.BalloonText, div.BalloonText
- {mso-style-name:"Balloon Text";
- margin:0in;
- margin-bottom:.0001pt;
- mso-pagination:widow-orphan;
- font-size:8.0pt;
- font-family:Tahoma;
- mso-fareast-font-family:"Times New Roman";}
-@page Section1
- {size:8.5in 11.0in;
- margin:1.0in 1.25in 1.0in 1.25in;
- mso-header-margin:.5in;
- mso-footer-margin:.5in;
- mso-paper-source:0;}
-div.Section1
- {page:Section1;}
--->
-</style>
-</head>
-
-<body lang=EN-US style='tab-interval:.5in'>
-
-<div class=Section1>
-
-<p align=center style='text-align:center'><b>Eclipse Public License - v 1.0</b>
-</p>
-
-<p><span style='font-size:10.0pt'>THE ACCOMPANYING PROGRAM IS PROVIDED UNDER
-THE TERMS OF THIS ECLIPSE PUBLIC LICENSE (&quot;AGREEMENT&quot;). ANY USE,
-REPRODUCTION OR DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE
-OF THIS AGREEMENT.</span> </p>
-
-<p><b><span style='font-size:10.0pt'>1. DEFINITIONS</span></b> </p>
-
-<p><span style='font-size:10.0pt'>&quot;Contribution&quot; means:</span> </p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>a)
-in the case of the initial Contributor, the initial code and documentation
-distributed under this Agreement, and<br clear=left>
-b) in the case of each subsequent Contributor:</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>i)
-changes to the Program, and</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>ii)
-additions to the Program;</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>where
-such changes and/or additions to the Program originate from and are distributed
-by that particular Contributor. A Contribution 'originates' from a Contributor
-if it was added to the Program by such Contributor itself or anyone acting on
-such Contributor's behalf. Contributions do not include additions to the
-Program which: (i) are separate modules of software distributed in conjunction
-with the Program under their own license agreement, and (ii) are not derivative
-works of the Program. </span></p>
-
-<p><span style='font-size:10.0pt'>&quot;Contributor&quot; means any person or
-entity that distributes the Program.</span> </p>
-
-<p><span style='font-size:10.0pt'>&quot;Licensed Patents &quot; mean patent
-claims licensable by a Contributor which are necessarily infringed by the use
-or sale of its Contribution alone or when combined with the Program. </span></p>
-
-<p><span style='font-size:10.0pt'>&quot;Program&quot; means the Contributions
-distributed in accordance with this Agreement.</span> </p>
-
-<p><span style='font-size:10.0pt'>&quot;Recipient&quot; means anyone who
-receives the Program under this Agreement, including all Contributors.</span> </p>
-
-<p><b><span style='font-size:10.0pt'>2. GRANT OF RIGHTS</span></b> </p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>a)
-Subject to the terms of this Agreement, each Contributor hereby grants Recipient
-a non-exclusive, worldwide, royalty-free copyright license to<span
-style='color:red'> </span>reproduce, prepare derivative works of, publicly
-display, publicly perform, distribute and sublicense the Contribution of such
-Contributor, if any, and such derivative works, in source code and object code
-form.</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>b)
-Subject to the terms of this Agreement, each Contributor hereby grants
-Recipient a non-exclusive, worldwide,<span style='color:green'> </span>royalty-free
-patent license under Licensed Patents to make, use, sell, offer to sell, import
-and otherwise transfer the Contribution of such Contributor, if any, in source
-code and object code form. This patent license shall apply to the combination
-of the Contribution and the Program if, at the time the Contribution is added
-by the Contributor, such addition of the Contribution causes such combination
-to be covered by the Licensed Patents. The patent license shall not apply to
-any other combinations which include the Contribution. No hardware per se is
-licensed hereunder. </span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>c)
-Recipient understands that although each Contributor grants the licenses to its
-Contributions set forth herein, no assurances are provided by any Contributor
-that the Program does not infringe the patent or other intellectual property
-rights of any other entity. Each Contributor disclaims any liability to Recipient
-for claims brought by any other entity based on infringement of intellectual
-property rights or otherwise. As a condition to exercising the rights and
-licenses granted hereunder, each Recipient hereby assumes sole responsibility
-to secure any other intellectual property rights needed, if any. For example,
-if a third party patent license is required to allow Recipient to distribute
-the Program, it is Recipient's responsibility to acquire that license before
-distributing the Program.</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>d)
-Each Contributor represents that to its knowledge it has sufficient copyright
-rights in its Contribution, if any, to grant the copyright license set forth in
-this Agreement. </span></p>
-
-<p><b><span style='font-size:10.0pt'>3. REQUIREMENTS</span></b> </p>
-
-<p><span style='font-size:10.0pt'>A Contributor may choose to distribute the
-Program in object code form under its own license agreement, provided that:</span>
-</p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>a)
-it complies with the terms and conditions of this Agreement; and</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>b)
-its license agreement:</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>i)
-effectively disclaims on behalf of all Contributors all warranties and
-conditions, express and implied, including warranties or conditions of title
-and non-infringement, and implied warranties or conditions of merchantability
-and fitness for a particular purpose; </span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>ii)
-effectively excludes on behalf of all Contributors all liability for damages,
-including direct, indirect, special, incidental and consequential damages, such
-as lost profits; </span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>iii)
-states that any provisions which differ from this Agreement are offered by that
-Contributor alone and not by any other party; and</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>iv)
-states that source code for the Program is available from such Contributor, and
-informs licensees how to obtain it in a reasonable manner on or through a
-medium customarily used for software exchange.<span style='color:blue'> </span></span></p>
-
-<p><span style='font-size:10.0pt'>When the Program is made available in source
-code form:</span> </p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>a)
-it must be made available under this Agreement; and </span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>b) a
-copy of this Agreement must be included with each copy of the Program. </span></p>
-
-<p><span style='font-size:10.0pt'>Contributors may not remove or alter any
-copyright notices contained within the Program. </span></p>
-
-<p><span style='font-size:10.0pt'>Each Contributor must identify itself as the
-originator of its Contribution, if any, in a manner that reasonably allows
-subsequent Recipients to identify the originator of the Contribution. </span></p>
-
-<p><b><span style='font-size:10.0pt'>4. COMMERCIAL DISTRIBUTION</span></b> </p>
-
-<p><span style='font-size:10.0pt'>Commercial distributors of software may
-accept certain responsibilities with respect to end users, business partners
-and the like. While this license is intended to facilitate the commercial use
-of the Program, the Contributor who includes the Program in a commercial
-product offering should do so in a manner which does not create potential
-liability for other Contributors. Therefore, if a Contributor includes the
-Program in a commercial product offering, such Contributor (&quot;Commercial
-Contributor&quot;) hereby agrees to defend and indemnify every other
-Contributor (&quot;Indemnified Contributor&quot;) against any losses, damages and
-costs (collectively &quot;Losses&quot;) arising from claims, lawsuits and other
-legal actions brought by a third party against the Indemnified Contributor to
-the extent caused by the acts or omissions of such Commercial Contributor in
-connection with its distribution of the Program in a commercial product
-offering. The obligations in this section do not apply to any claims or Losses
-relating to any actual or alleged intellectual property infringement. In order
-to qualify, an Indemnified Contributor must: a) promptly notify the Commercial
-Contributor in writing of such claim, and b) allow the Commercial Contributor
-to control, and cooperate with the Commercial Contributor in, the defense and
-any related settlement negotiations. The Indemnified Contributor may participate
-in any such claim at its own expense.</span> </p>
-
-<p><span style='font-size:10.0pt'>For example, a Contributor might include the
-Program in a commercial product offering, Product X. That Contributor is then a
-Commercial Contributor. If that Commercial Contributor then makes performance
-claims, or offers warranties related to Product X, those performance claims and
-warranties are such Commercial Contributor's responsibility alone. Under this
-section, the Commercial Contributor would have to defend claims against the
-other Contributors related to those performance claims and warranties, and if a
-court requires any other Contributor to pay any damages as a result, the
-Commercial Contributor must pay those damages.</span> </p>
-
-<p><b><span style='font-size:10.0pt'>5. NO WARRANTY</span></b> </p>
-
-<p><span style='font-size:10.0pt'>EXCEPT AS EXPRESSLY SET FORTH IN THIS
-AGREEMENT, THE PROGRAM IS PROVIDED ON AN &quot;AS IS&quot; BASIS, WITHOUT
-WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING,
-WITHOUT LIMITATION, ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT,
-MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely
-responsible for determining the appropriateness of using and distributing the
-Program and assumes all risks associated with its exercise of rights under this
-Agreement , including but not limited to the risks and costs of program errors,
-compliance with applicable laws, damage to or loss of data, programs or
-equipment, and unavailability or interruption of operations. </span></p>
-
-<p><b><span style='font-size:10.0pt'>6. DISCLAIMER OF LIABILITY</span></b> </p>
-
-<p><span style='font-size:10.0pt'>EXCEPT AS EXPRESSLY SET FORTH IN THIS
-AGREEMENT, NEITHER RECIPIENT NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR
-ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
-(INCLUDING WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND ON ANY THEORY
-OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
-NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OR DISTRIBUTION OF
-THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED HEREUNDER, EVEN IF ADVISED OF
-THE POSSIBILITY OF SUCH DAMAGES.</span> </p>
-
-<p><b><span style='font-size:10.0pt'>7. GENERAL</span></b> </p>
-
-<p><span style='font-size:10.0pt'>If any provision of this Agreement is invalid
-or unenforceable under applicable law, it shall not affect the validity or
-enforceability of the remainder of the terms of this Agreement, and without
-further action by the parties hereto, such provision shall be reformed to the
-minimum extent necessary to make such provision valid and enforceable.</span> </p>
-
-<p><span style='font-size:10.0pt'>If Recipient institutes patent litigation
-against any entity (including a cross-claim or counterclaim in a lawsuit)
-alleging that the Program itself (excluding combinations of the Program with
-other software or hardware) infringes such Recipient's patent(s), then such
-Recipient's rights granted under Section 2(b) shall terminate as of the date
-such litigation is filed. </span></p>
-
-<p><span style='font-size:10.0pt'>All Recipient's rights under this Agreement
-shall terminate if it fails to comply with any of the material terms or
-conditions of this Agreement and does not cure such failure in a reasonable
-period of time after becoming aware of such noncompliance. If all Recipient's
-rights under this Agreement terminate, Recipient agrees to cease use and
-distribution of the Program as soon as reasonably practicable. However,
-Recipient's obligations under this Agreement and any licenses granted by
-Recipient relating to the Program shall continue and survive. </span></p>
-
-<p><span style='font-size:10.0pt'>Everyone is permitted to copy and distribute
-copies of this Agreement, but in order to avoid inconsistency the Agreement is
-copyrighted and may only be modified in the following manner. The Agreement
-Steward reserves the right to publish new versions (including revisions) of
-this Agreement from time to time. No one other than the Agreement Steward has
-the right to modify this Agreement. The Eclipse Foundation is the initial
-Agreement Steward. The Eclipse Foundation may assign the responsibility to
-serve as the Agreement Steward to a suitable separate entity. Each new version
-of the Agreement will be given a distinguishing version number. The Program
-(including Contributions) may always be distributed subject to the version of
-the Agreement under which it was received. In addition, after a new version of
-the Agreement is published, Contributor may elect to distribute the Program
-(including its Contributions) under the new version. Except as expressly stated
-in Sections 2(a) and 2(b) above, Recipient receives no rights or licenses to
-the intellectual property of any Contributor under this Agreement, whether
-expressly, by implication, estoppel or otherwise. All rights in the Program not
-expressly granted under this Agreement are reserved.</span> </p>
-
-<p><span style='font-size:10.0pt'>This Agreement is governed by the laws of the
-State of New York and the intellectual property laws of the United States of
-America. No party to this Agreement will bring a legal action under this
-Agreement more than one year after the cause of action arose. Each party waives
-its rights to a jury trial in any resulting litigation.</span> </p>
-
-<p class=MsoNormal><![if !supportEmptyParas]>&nbsp;<![endif]><o:p></o:p></p>
-
-</div>
-
-</body>
-
-</html> \ No newline at end of file
diff --git a/org.eclipse.mylyn-feature/feature.xml b/org.eclipse.mylyn-feature/feature.xml
deleted file mode 100644
index 68e98acb6..000000000
--- a/org.eclipse.mylyn-feature/feature.xml
+++ /dev/null
@@ -1,279 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<feature
- id="org.eclipse.mylar_feature"
- label="org.eclipse.mylar-feature"
- version="0.2.4"
- provider-name="University of British Columbia">
-
- <description url="http://www.cs.ubc.ca/~mylar">
- Mylar Plugin
- </description>
-
- <license url="http://www.eclipse.org/legal/epl-v10.html">
- Eclipse Public License - v 1.0
-THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS
-ECLIPSE PUBLIC LICENSE (&quot;AGREEMENT&quot;). ANY USE, REPRODUCTION OR
-DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT&apos;S ACCEPTANCE
-OF THIS AGREEMENT.
-1. DEFINITIONS
-&quot;Contribution&quot; means:
-a) in the case of the initial Contributor, the initial code and
-documentation distributed under this Agreement, and
-b) in the case of each subsequent Contributor:
-i) changes to the Program, and
-ii) additions to the Program;
-where such changes and/or additions to the Program originate
-from and are distributed by that particular Contributor. A Contribution
-&apos;originates&apos; from a Contributor if it was added to the Program
-by such Contributor itself or anyone acting on such Contributor&apos;s
-behalf. Contributions do not include additions to the Program
-which: (i) are separate modules of software distributed in conjunction
-with the Program under their own license agreement, and (ii)
-are not derivative works of the Program.
-&quot;Contributor&quot; means any person or entity that distributes the
-Program.
-&quot;Licensed Patents &quot; mean patent claims licensable by a Contributor
-which are necessarily infringed by the use or sale of its Contribution
-alone or when combined with the Program.
-&quot;Program&quot; means the Contributions distributed in accordance with
-this Agreement.
-&quot;Recipient&quot; means anyone who receives the Program under this
-Agreement, including all Contributors.
-2. GRANT OF RIGHTS
-a) Subject to the terms of this Agreement, each Contributor hereby
-grants Recipient a non-exclusive, worldwide, royalty-free copyright
-license to reproduce, prepare derivative works of, publicly display,
-publicly perform, distribute and sublicense the Contribution
-of such Contributor, if any, and such derivative works, in source
-code and object code form.
-b) Subject to the terms of this Agreement, each Contributor hereby
-grants Recipient a non-exclusive, worldwide, royalty-free patent
-license under Licensed Patents to make, use, sell, offer to sell,
-import and otherwise transfer the Contribution of such Contributor,
-if any, in source code and object code form. This patent license
-shall apply to the combination of the Contribution and the Program
-if, at the time the Contribution is added by the Contributor,
-such addition of the Contribution causes such combination to
-be covered by the Licensed Patents. The patent license shall
-not apply to any other combinations which include the Contribution.
-No hardware per se is licensed hereunder.
-c) Recipient understands that although each Contributor grants
-the licenses to its Contributions set forth herein, no assurances
-are provided by any Contributor that the Program does not infringe
-the patent or other intellectual property rights of any other
-entity. Each Contributor disclaims any liability to Recipient
-for claims brought by any other entity based on infringement
-of intellectual property rights or otherwise. As a condition
-to exercising the rights and licenses granted hereunder, each
-Recipient hereby assumes sole responsibility to secure any other
-intellectual property rights needed, if any. For example, if
-a third party patent license is required to allow Recipient to
-distribute the Program, it is Recipient&apos;s responsibility to acquire
-that license before distributing the Program.
-d) Each Contributor represents that to its knowledge it has sufficient
-copyright rights in its Contribution, if any, to grant the copyright
-license set forth in this Agreement.
-3. REQUIREMENTS
-A Contributor may choose to distribute the Program in object
-code form under its own license agreement, provided that:
-a) it complies with the terms and conditions of this Agreement;
-and
-b) its license agreement:
-i) effectively disclaims on behalf of all Contributors all warranties
-and conditions, express and implied, including warranties or
-conditions of title and non-infringement, and implied warranties
-or conditions of merchantability and fitness for a particular
-purpose;
-ii) effectively excludes on behalf of all Contributors all liability
-for damages, including direct, indirect, special, incidental
-and consequential damages, such as lost profits;
-iii) states that any provisions which differ from this Agreement
-are offered by that Contributor alone and not by any other party;
-and
-iv) states that source code for the Program is available from
-such Contributor, and informs licensees how to obtain it in a
-reasonable manner on or through a medium customarily used for
-software exchange.
-When the Program is made available in source code form:
-a) it must be made available under this Agreement; and
-b) a copy of this Agreement must be included with each copy of
-the Program.
-Contributors may not remove or alter any copyright notices contained
-within the Program.
-Each Contributor must identify itself as the originator of its
-Contribution, if any, in a manner that reasonably allows subsequent
-Recipients to identify the originator of the Contribution.
-4. COMMERCIAL DISTRIBUTION
-Commercial distributors of software may accept certain responsibilities
-with respect to end users, business partners and the like. While
-this license is intended to facilitate the commercial use of
-the Program, the Contributor who includes the Program in a commercial
-product offering should do so in a manner which does not create
-potential liability for other Contributors. Therefore, if a Contributor
-includes the Program in a commercial product offering, such Contributor
-(&quot;Commercial Contributor&quot;) hereby agrees to defend and indemnify
-every other Contributor (&quot;Indemnified Contributor&quot;) against any
-losses, damages and costs (collectively &quot;Losses&quot;) arising from
-claims, lawsuits and other legal actions brought by a third party
-against the Indemnified Contributor to the extent caused by the
-acts or omissions of such Commercial Contributor in connection
-with its distribution of the Program in a commercial product
-offering. The obligations in this section do not apply to any
-claims or Losses relating to any actual or alleged intellectual
-property infringement. In order to qualify, an Indemnified Contributor
-must: a) promptly notify the Commercial Contributor in writing
-of such claim, and b) allow the Commercial Contributor to control,
-and cooperate with the Commercial Contributor in, the defense
-and any related settlement negotiations. The Indemnified Contributor
-may participate in any such claim at its own expense.
-For example, a Contributor might include the Program in a commercial
-product offering, Product X. That Contributor is then a Commercial
-Contributor. If that Commercial Contributor then makes performance
-claims, or offers warranties related to Product X, those performance
-claims and warranties are such Commercial Contributor&apos;s responsibility
-alone. Under this section, the Commercial Contributor would have
-to defend claims against the other Contributors related to those
-performance claims and warranties, and if a court requires any
-other Contributor to pay any damages as a result, the Commercial
-Contributor must pay those damages.
-5. NO WARRANTY
-EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM
-IS PROVIDED ON AN &quot;AS IS&quot; BASIS, WITHOUT WARRANTIES OR CONDITIONS
-OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION,
-ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY
-OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely
-responsible for determining the appropriateness of using and
-distributing the Program and assumes all risks associated with
-its exercise of rights under this Agreement , including but not
-limited to the risks and costs of program errors, compliance
-with applicable laws, damage to or loss of data, programs or
-equipment, and unavailability or interruption of operations.
-6. DISCLAIMER OF LIABILITY
-EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT
-NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT,
-INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
-(INCLUDING WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND
-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
-OUT OF THE USE OR DISTRIBUTION OF THE PROGRAM OR THE EXERCISE
-OF ANY RIGHTS GRANTED HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY
-OF SUCH DAMAGES.
-7. GENERAL
-If any provision of this Agreement is invalid or unenforceable
-under applicable law, it shall not affect the validity or enforceability
-of the remainder of the terms of this Agreement, and without
-further action by the parties hereto, such provision shall be
-reformed to the minimum extent necessary to make such provision
-valid and enforceable.
-If Recipient institutes patent litigation against any entity
-(including a cross-claim or counterclaim in a lawsuit) alleging
-that the Program itself (excluding combinations of the Program
-with other software or hardware) infringes such Recipient&apos;s patent(s),
-then such Recipient&apos;s rights granted under Section 2(b) shall
-terminate as of the date such litigation is filed.
-All Recipient&apos;s rights under this Agreement shall terminate if
-it fails to comply with any of the material terms or conditions
-of this Agreement and does not cure such failure in a reasonable
-period of time after becoming aware of such noncompliance. If
-all Recipient&apos;s rights under this Agreement terminate, Recipient
-agrees to cease use and distribution of the Program as soon as
-reasonably practicable. However, Recipient&apos;s obligations under
-this Agreement and any licenses granted by Recipient relating
-to the Program shall continue and survive.
-Everyone is permitted to copy and distribute copies of this Agreement,
-but in order to avoid inconsistency the Agreement is copyrighted
-and may only be modified in the following manner. The Agreement
-Steward reserves the right to publish new versions (including
-revisions) of this Agreement from time to time. No one other
-than the Agreement Steward has the right to modify this Agreement.
-The Eclipse Foundation is the initial Agreement Steward. The
-Eclipse Foundation may assign the responsibility to serve as
-the Agreement Steward to a suitable separate entity. Each new
-version of the Agreement will be given a distinguishing version
-number. The Program (including Contributions) may always be distributed
-subject to the version of the Agreement under which it was received.
-In addition, after a new version of the Agreement is published,
-Contributor may elect to distribute the Program (including its
-Contributions) under the new version. Except as expressly stated
-in Sections 2(a) and 2(b) above, Recipient receives no rights
-or licenses to the intellectual property of any Contributor under
-this Agreement, whether expressly, by implication, estoppel or
-otherwise. All rights in the Program not expressly granted under
-this Agreement are reserved.
-This Agreement is governed by the laws of the State of New York
-and the intellectual property laws of the United States of America.
-No party to this Agreement will bring a legal action under this
-Agreement more than one year after the cause of action arose.
-Each party waives its rights to a jury trial in any resulting
-litigation.
- </license>
-
- <includes
- id="org.eclipse.mylar.bugzilla_feature"
- version="1.7.2"/>
-
- <includes
- id="org.eclipse.mylar.monitor_feature"
- version="0.2.4"/>
-
- <requires>
- <import plugin="org.eclipse.ui" version="0.0.0" match="greaterOrEqual"/>
- <import plugin="org.eclipse.core.runtime" version="0.0.0" match="greaterOrEqual"/>
- <import plugin="org.eclipse.core.resources" version="0.0.0" match="greaterOrEqual"/>
- <import plugin="org.eclipse.jdt" version="0.0.0" match="greaterOrEqual"/>
- <import plugin="org.eclipse.jdt.core" version="0.0.0" match="greaterOrEqual"/>
- <import plugin="org.eclipse.jdt.ui" version="0.0.0" match="greaterOrEqual"/>
- <import plugin="org.eclipse.ui.editors" version="0.0.0" match="greaterOrEqual"/>
- <import plugin="org.eclipse.jface.text" version="0.0.0" match="greaterOrEqual"/>
- <import plugin="org.eclipse.ui.workbench.texteditor" version="0.0.0" match="greaterOrEqual"/>
- <import plugin="org.eclipse.search" version="0.0.0" match="greaterOrEqual"/>
- <import plugin="org.eclipse.ui.views" version="0.0.0" match="greaterOrEqual"/>
- <import plugin="org.eclipse.ui.ide" version="0.0.0" match="greaterOrEqual"/>
- <import plugin="org.eclipse.ui.console" version="0.0.0" match="greaterOrEqual"/>
- <import plugin="org.eclipse.ui.forms" version="0.0.0" match="greaterOrEqual"/>
- <import plugin="org.eclipse.osgi.util" version="0.0.0" match="greaterOrEqual"/>
- <import plugin="org.eclipse.osgi.services" version="0.0.0" match="greaterOrEqual"/>
- <import plugin="org.eclipse.pde.ui" version="0.0.0" match="greaterOrEqual"/>
- <import plugin="org.eclipse.ant.ui" version="0.0.0" match="greaterOrEqual"/>
- <import plugin="org.eclipse.ant.core" version="0.0.0" match="greaterOrEqual"/>
- <import plugin="org.eclipse.pde.core" version="0.0.0" match="greaterOrEqual"/>
- <import plugin="org.eclipse.mylar.core"/>
- <import plugin="org.eclipse.mylar.bugzilla"/>
- </requires>
-
- <plugin
- id="org.eclipse.mylar.doc"
- download-size="0"
- install-size="0"
- version="0.2.4"
- unpack="false"/>
-
- <plugin
- id="org.eclipse.mylar.java"
- download-size="0"
- install-size="0"
- version="0.2.4"
- unpack="false"/>
-
- <plugin
- id="org.eclipse.mylar.ui"
- download-size="0"
- install-size="0"
- version="0.2.4"
- unpack="false"/>
-
- <plugin
- id="org.eclipse.mylar.xml"
- download-size="0"
- install-size="0"
- version="0.2.4"
- unpack="false"/>
-
- <plugin
- id="org.eclipse.mylar.tasks"
- download-size="0"
- install-size="0"
- version="0.2.4"
- unpack="false"/>
-
-</feature>
diff --git a/org.eclipse.mylyn-feature/license.html b/org.eclipse.mylyn-feature/license.html
deleted file mode 100644
index 3259fb996..000000000
--- a/org.eclipse.mylyn-feature/license.html
+++ /dev/null
@@ -1,73 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
-<html>
-<head>
-<meta http-equiv=Content-Type content="text/html; charset=iso-8859-1">
-<title>Eclipse.org Software User Agreement</title>
-</head>
-
-<body lang="EN-US" link=blue vlink=purple>
-<h2>Eclipse Foundation Software User Agreement</h2>
-<p>January 28, 2005</p>
-
-<h3>Usage Of Content</h3>
-
-<p>THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR OTHER MATERIALS FOR OPEN SOURCE PROJECTS
- (COLLECTIVELY &quot;CONTENT&quot;). USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS AGREEMENT AND/OR THE TERMS AND
- CONDITIONS OF LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU AGREE THAT YOUR USE
- OF THE CONTENT IS GOVERNED BY THIS AGREEMENT AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR
- NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND
- CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW, THEN YOU MAY NOT USE THE CONTENT.</p>
-
-<h3>Applicable Licenses</h3>
-
-<p>Unless otherwise indicated, all Content made available by the Eclipse Foundation is provided to you under the terms and conditions of the Eclipse Public License Version 1.0
- (&quot;EPL&quot;). A copy of the EPL is provided with this Content and is also available at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
- For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
-
-<p>Content includes, but is not limited to, source code, object code, documentation and other files maintained in the Eclipse.org CVS repository (&quot;Repository&quot;) in CVS
- modules (&quot;Modules&quot;) and made available as downloadable archives (&quot;Downloads&quot;).</p>
-
-<p>Content may be apportioned into plug-ins (&quot;Plug-ins&quot;), plug-in fragments (&quot;Fragments&quot;), and features (&quot;Features&quot;). A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material. Files named &quot;feature.xml&quot; may contain a list of the names and version numbers of the Plug-ins and/or Fragments associated with a Feature. Plug-ins and Fragments are located in directories
- named &quot;plugins&quot; and Features are located in directories named &quot;features&quot;.</p>
-
-<p>Features may also include other Features (&quot;Included Features&quot;). Files named &quot;feature.xml&quot; may contain a list of the names and version numbers of Included Features.</p>
-
-<p>The terms and conditions governing Plug-ins and Fragments should be contained in files named &quot;about.html&quot; (&quot;Abouts&quot;). The terms and conditions governing Features and
-Included Features should be contained in files named &quot;license.html&quot; (&quot;Feature Licenses&quot;). Abouts and Feature Licenses may be located in any directory of a Download or Module
-including, but not limited to the following locations:</p>
-
-<ul>
- <li>The top-level (root) directory</li>
- <li>Plug-in and Fragment directories</li>
- <li>Subdirectories of the directory named &quot;src&quot; of certain Plug-ins</li>
- <li>Feature directories</li>
-</ul>
-
-<p>Note: if a Feature made available by the Eclipse Foundation is installed using the Eclipse Update Manager, you must agree to a license (&quot;Feature Update License&quot;) during the
-installation process. If the Feature contains Included Features, the Feature Update License should either provide you with the terms and conditions governing the Included Features or
-inform you where you can locate them. Feature Update Licenses may be found in the &quot;license&quot; property of files named &quot;feature.properties&quot;.
-Such Abouts, Feature Licenses and Feature Update Licenses contain the terms and conditions (or references to such terms and conditions) that govern your use of the associated Content in
-that directory.</p>
-
-<p>THE ABOUTS, FEATURE LICENSES AND FEATURE UPDATE LICENSES MAY REFER TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS. SOME OF THESE
-OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):</p>
-
-<ul>
- <li>Common Public License Version 1.0 (available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>)</li>
- <li>Apache Software License 1.1 (available at <a href="http://www.apache.org/licenses/LICENSE">http://www.apache.org/licenses/LICENSE</a>)</li>
- <li>Apache Software License 2.0 (available at <a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a>)</li>
- <li>IBM Public License 1.0 (available at <a href="http://oss.software.ibm.com/developerworks/opensource/license10.html">http://oss.software.ibm.com/developerworks/opensource/license10.html</a>)</li>
- <li>Metro Link Public License 1.00 (available at <a href="http://www.opengroup.org/openmotif/supporters/metrolink/license.html">http://www.opengroup.org/openmotif/supporters/metrolink/license.html</a>)</li>
- <li>Mozilla Public License Version 1.1 (available at <a href="http://www.mozilla.org/MPL/MPL-1.1.html">http://www.mozilla.org/MPL/MPL-1.1.html</a>)</li>
-</ul>
-
-<p>IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR TO USE OF THE CONTENT. If no About, Feature License or Feature Update License is provided, please
-contact the Eclipse Foundation to determine what terms and conditions govern that particular Content.</p>
-
-<h3>Cryptography</h3>
-
-<p>Content may contain encryption software. The country in which you are currently may have restrictions on the import, possession, and use, and/or re-export to
- another country, of encryption software. BEFORE using any encryption software, please check the country's laws, regulations and policies concerning the import,
- possession, or use, and re-export of encryption software, to see if this is permitted.</p>
-</body>
-</html>
diff --git a/org.eclipse.mylyn.bugzilla.tests/.classpath b/org.eclipse.mylyn.bugzilla.tests/.classpath
deleted file mode 100644
index 065ac06e1..000000000
--- a/org.eclipse.mylyn.bugzilla.tests/.classpath
+++ /dev/null
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
- <classpathentry kind="src" path="src"/>
- <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
- <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
- <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/org.eclipse.mylyn.bugzilla.tests/.cvsignore b/org.eclipse.mylyn.bugzilla.tests/.cvsignore
deleted file mode 100644
index ba077a403..000000000
--- a/org.eclipse.mylyn.bugzilla.tests/.cvsignore
+++ /dev/null
@@ -1 +0,0 @@
-bin
diff --git a/org.eclipse.mylyn.bugzilla.tests/.project b/org.eclipse.mylyn.bugzilla.tests/.project
deleted file mode 100644
index 9187a2826..000000000
--- a/org.eclipse.mylyn.bugzilla.tests/.project
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.mylar.bugzilla.test</name>
- <comment></comment>
- <projects>
- </projects>
- <buildSpec>
- <buildCommand>
- <name>org.eclipse.jdt.core.javabuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.pde.ManifestBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.pde.SchemaBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- </buildSpec>
- <natures>
- <nature>org.eclipse.pde.PluginNature</nature>
- <nature>org.eclipse.jdt.core.javanature</nature>
- </natures>
-</projectDescription>
diff --git a/org.eclipse.mylyn.bugzilla.tests/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.mylyn.bugzilla.tests/.settings/org.eclipse.jdt.core.prefs
deleted file mode 100644
index 4600f7389..000000000
--- a/org.eclipse.mylyn.bugzilla.tests/.settings/org.eclipse.jdt.core.prefs
+++ /dev/null
@@ -1,12 +0,0 @@
-#Thu Jun 30 08:32:16 PDT 2005
-eclipse.preferences.version=1
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5
-org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.5
-org.eclipse.jdt.core.compiler.debug.lineNumber=generate
-org.eclipse.jdt.core.compiler.debug.localVariable=generate
-org.eclipse.jdt.core.compiler.debug.sourceFile=generate
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
-org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
-org.eclipse.jdt.core.compiler.source=1.5
diff --git a/org.eclipse.mylyn.bugzilla.tests/META-INF/MANIFEST.MF b/org.eclipse.mylyn.bugzilla.tests/META-INF/MANIFEST.MF
deleted file mode 100644
index 8f68efb90..000000000
--- a/org.eclipse.mylyn.bugzilla.tests/META-INF/MANIFEST.MF
+++ /dev/null
@@ -1,19 +0,0 @@
-Manifest-Version: 1.0
-Bundle-ManifestVersion: 2
-Bundle-Name: Bugzilla Tests Plug-in
-Bundle-SymbolicName: org.eclipse.mylar.bugzilla.test
-Bundle-Version: 1.7.2
-Bundle-Activator: org.eclipse.mylar.bugzilla.test.BugzillaTestPlugin
-Bundle-Localization: plugin
-Require-Bundle: org.eclipse.ui,
- org.eclipse.core.runtime,
- org.junit,
- org.eclipse.ui.ide,
- org.eclipse.ui.views,
- org.eclipse.ui.editors,
- org.eclipse.ui.workbench.texteditor,
- org.eclipse.mylar.bugzilla
-Eclipse-AutoStart: true
-Bundle-Vendor: University of British Columbia
-Export-Package: org.eclipse.mylar.bugzilla.test
-Bundle-ClassPath: bugzilla-test.jar
diff --git a/org.eclipse.mylyn.bugzilla.tests/TestPages/bug-1-full.html b/org.eclipse.mylyn.bugzilla.tests/TestPages/bug-1-full.html
deleted file mode 100644
index 00fd1bcb7..000000000
--- a/org.eclipse.mylyn.bugzilla.tests/TestPages/bug-1-full.html
+++ /dev/null
@@ -1,719 +0,0 @@
-<!-- 1.0@bugzilla.org -->
-
-<!-- 1.0@bugzilla.org -->
-
-
-
-
-<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
-<html>
- <head>
- <title>Bug 1 - Usability issue with external editors (1GE6IRL)</title>
-
-
-
-
-
-
-
- </head>
-
-
-
- <body bgcolor="#FFFFFF" onload="">
-
-
-<!-- 1.0@bugzilla.org -->
-
-
-
-
-<BODY BGCOLOR="#FFFFFF" TEXT="#000000" LINK="#0000EE" VLINK="#551A8B" ALINK="#FF0000" >
-<table BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH="100%" ><tr><td
-WIDTH="100%"><table BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH="100%"
-BGCOLOR="#006699" ><tr><td BGCOLOR="#000000" width="116" ><img
-src="images/EclipseBannerPic.jpg" width="115" height="50"></td><td
-WIDTH="637"><a href=http://www.eclipse.org><img SRC="images/gradient.jpg" BORDER=0 height=50
-width=282></a></td><td WIDTH="250"><img src="images/eproject-simple.gif"
-width="250" height="48"></td></tr></table></td></tr></table>
-
- <table border="0" cellspacing="0">
- <tr>
- <td valign="top" align="left">
- <table border="0" cellpadding="0" cellspacing="2">
- <tr>
- <td valign="top" align="left" nowrap="nowrap">
- <font size="+1"><b>Bugzilla Bug 1</b></font>
- </td>
- </tr>
- </table>
- </td>
- <td valign="middle">&nbsp;</td>
- <td valign="middle" align="left">Usability issue with external editors (1GE6IRL)</td>
- </tr>
- </table>
-<!-- 1.0@bugzilla.org -->
-
-
-
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="query.cgi">Query page</a>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="enter_bug.cgi">Enter new bug</a>
-
-<hr>
-
-<form name="changeform" method="post" action="process_bug.cgi">
-
- <input type="hidden" name="delta_ts" value="20011025104050">
- <input type="hidden" name="longdesclength" value="5">
- <input type="hidden" name="id" value="1">
-
-
-
- <table cellspacing="1" cellpadding="1" border="0">
- <tr>
- <td align="right">
- <b>Bug#:</b>
- </td>
- <td>
- <a href="http://bugs.eclipse.org/bugs/show_bug.cgi?id=1">1</a>
- </td>
-
- <td>&nbsp;</td>
-
- <td align="right">
- <b>Platform:</b>
- </td><td>
- <select name="rep_platform">
- <option value="All" selected>All
- </option>
- <option value="Macintosh">Macintosh
- </option>
- <option value="PC">PC
- </option>
- <option value="Power PC">Power PC
- </option>
- <option value="Sun">Sun
- </option>
- <option value="Other">Other
- </option>
- </select>
- </td>
- <td>&nbsp;</td>
-
- <td align="right">
- <b>Reporter:</b>
- </td>
- <td>andre_weinand@ch.ibm.com (Andre Weinand)
- </td>
- </tr>
-
- <tr>
- <td align="right">
- <b>Product:</b>
- </td><td>
- <select name="product">
- <option value="AJDT">AJDT
- </option>
- <option value="AspectJ">AspectJ
- </option>
- <option value="CDT">CDT
- </option>
- <option value="EMF">EMF
- </option>
- <option value="Equinox">Equinox
- </option>
- <option value="GEF">GEF
- </option>
- <option value="JDT">JDT
- </option>
- <option value="PDE">PDE
- </option>
- <option value="Platform" selected>Platform
- </option>
- <option value="Stellation">Stellation
- </option>
- <option value="XSD">XSD
- </option>
- </select>
- </td>
- <td>&nbsp;</td>
-
- <td align="right">
- <b>OS:</b>
- </td><td>
- <select name="op_sys">
- <option value="All" selected>All
- </option>
- <option value="AIX Motif">AIX Motif
- </option>
- <option value="Windows 95">Windows 95
- </option>
- <option value="Windows 98">Windows 98
- </option>
- <option value="Windows CE">Windows CE
- </option>
- <option value="Windows ME">Windows ME
- </option>
- <option value="Windows 2000">Windows 2000
- </option>
- <option value="Windows NT">Windows NT
- </option>
- <option value="Windows XP">Windows XP
- </option>
- <option value="Windows All">Windows All
- </option>
- <option value="MacOS X">MacOS X
- </option>
- <option value="Linux">Linux
- </option>
- <option value="Linux-GTK">Linux-GTK
- </option>
- <option value="Linux-Motif">Linux-Motif
- </option>
- <option value="HP-UX">HP-UX
- </option>
- <option value="Neutrino">Neutrino
- </option>
- <option value="QNX-Photon">QNX-Photon
- </option>
- <option value="Solaris">Solaris
- </option>
- <option value="Unix All">Unix All
- </option>
- <option value="other">other
- </option>
- </select>
- </td>
- <td>&nbsp;</td>
-
- <td align="right">
- <b>Add&nbsp;CC:</b>
- </td>
- <td>
- <input name="newcc" size="30" value="">
- </td>
- </tr>
-
-
-
- <tr>
- <td align="right">
- <b>
- <a href="describecomponents.cgi?product=Platform">
- Component</a>:
- </b>
- </td>
- <td>
- <select name="component">
- <option value="Ant">Ant
- </option>
- <option value="Compare">Compare
- </option>
- <option value="Core">Core
- </option>
- <option value="Debug">Debug
- </option>
- <option value="Doc">Doc
- </option>
- <option value="Help">Help
- </option>
- <option value="Releng">Releng
- </option>
- <option value="Scripting">Scripting
- </option>
- <option value="Search">Search
- </option>
- <option value="SWT">SWT
- </option>
- <option value="Text">Text
- </option>
- <option value="UI">UI
- </option>
- <option value="Update">Update
- </option>
- <option value="VCM" selected>VCM
- </option>
- <option value="WebDAV">WebDAV
- </option>
- </select>
- </td>
-
- <td>&nbsp;</td>
-
- <td align="right">
- <b>Version:</b>
- </td><td>
- <select name="version">
- <option value="1.0">1.0
- </option>
- <option value="2.0" selected>2.0
- </option>
- <option value="2.0.1">2.0.1
- </option>
- <option value="2.0.2">2.0.2
- </option>
- <option value="2.1">2.1
- </option>
- </select>
- </td>
- <td>&nbsp;</td>
-
- <td rowspan="4" align="right" valign="top">
- <b>CC:</b>
- </td>
- <td rowspan="4" valign="top">
- <select name="cc" multiple="multiple" size="5">
- <option value="Kevin_McGuire@oti.com">Kevin_McGuire@oti.com</option>
- </select>
- <br>
- <input type="checkbox" name="removecc">Remove selected CCs
- <br>
- </td>
- </tr>
-
- <tr>
- <td align="right">
- <b>
- <a href="bug_status.html">Status</a>:
- </b>
- </td>
- <td>VERIFIED</td>
- <td>&nbsp;</td>
-
- <td align="right">
- <b><a href="bug_status.html#priority">Priority</a>:</b>
- </td><td>
- <select name="priority">
- <option value="P1">P1
- </option>
- <option value="P2">P2
- </option>
- <option value="P3" selected>P3
- </option>
- <option value="P4">P4
- </option>
- <option value="P5">P5
- </option>
- </select>
- </td>
- <td>&nbsp;</td>
- </tr>
-
- <tr>
- <td align="right">
- <b>
- <a href="bug_status.html">Resolution</a>:
- </b>
- </td>
- <td>FIXED</td>
- <td>&nbsp;</td>
-
- <td align="right">
- <b><a href="bug_status.html#severity">Severity</a>:</b>
- </td><td>
- <select name="bug_severity">
- <option value="blocker">blocker
- </option>
- <option value="critical">critical
- </option>
- <option value="major">major
- </option>
- <option value="normal" selected>normal
- </option>
- <option value="minor">minor
- </option>
- <option value="trivial">trivial
- </option>
- <option value="enhancement">enhancement
- </option>
- </select>
- </td>
- <td>&nbsp;</td>
-
- </tr>
-
- <tr>
- <td align="right">
- <b>
- <a href="bug_status.html#assigned_to">Assigned&nbsp;To</a>:
- </b>
- </td>
- <td>James_Moody@ca.ibm.com (James Moody)</td>
- <td>&nbsp;</td>
-
- <td align="right">
- <b>
- <a href="notargetmilestone.html">Target Milestone</a>:
- </b>
- </td><td>
- <select name="target_milestone">
- <option value="2.0 M1">2.0 M1
- </option>
- <option value="2.0 M2">2.0 M2
- </option>
- <option value="2.0 M3">2.0 M3
- </option>
- <option value="2.0 M4">2.0 M4
- </option>
- <option value="2.0 M5">2.0 M5
- </option>
- <option value="2.0 M6">2.0 M6
- </option>
- <option value="2.0 F1">2.0 F1
- </option>
- <option value="2.0 F2">2.0 F2
- </option>
- <option value="2.0 F3">2.0 F3
- </option>
- <option value="2.0 F4">2.0 F4
- </option>
- <option value="2.0.1">2.0.1
- </option>
- <option value="2.0.2">2.0.2
- </option>
- <option value="2.1">2.1
- </option>
- <option value="2.1 M1">2.1 M1
- </option>
- <option value="2.1 M2">2.1 M2
- </option>
- <option value="2.1 M3">2.1 M3
- </option>
- <option value="2.1 M4">2.1 M4
- </option>
- <option value="2.1 M5">2.1 M5
- </option>
- <option value="2.1 RC1">2.1 RC1
- </option>
- <option value="2.1 RC2">2.1 RC2
- </option>
- <option value="2.1 RC3">2.1 RC3
- </option>
- <option value="2.1 RC4">2.1 RC4
- </option>
- <option value="2.1.1">2.1.1
- </option>
- <option value="2.2">2.2
- </option>
- <option value="---" selected>---
- </option>
- </select>
- </td>
- <td>&nbsp;</td>
- </tr>
-
-
-
-
- <tr>
- <td align="right">
- <b>
- URL:
- </b>
- </td>
- <td colspan="7">
- <input name="bug_file_loc"
- value="" size="60">
- </td>
- </tr>
-
- <tr>
- <td align="right">
- <b>Summary:</b>
- </td>
- <td colspan="7">
- <input name="short_desc"
- value="Usability issue with external editors (1GE6IRL)" size="60">
- </td>
- </tr>
-
-
- <tr>
- <td align="right">
- <b>
- <a href="describekeywords.cgi">Keywords</a>:
- </b>
- <td colspan="7">
- <input name="keywords"
- value="" size="60">
- </td>
- </tr>
- </table>
-
-
-<!-- 1.0@bugzilla.org -->
-
-
-<br>
-<table cellspacing="0" cellpadding="4" border="1">
- <tr>
- <th bgcolor="#cccccc" align="left">Attachment</th>
- <th bgcolor="#cccccc" align="left">Type</th>
- <th bgcolor="#cccccc" align="left">Modified</th>
- <th bgcolor="#cccccc" align="left">Status</th>
- <th bgcolor="#cccccc" align="left">Actions</th>
- </tr>
-
-
- <tr>
- <td colspan="4">
- <a href="attachment.cgi?bugid=1&amp;action=enter">Create a New Attachment</a> (proposed patch, testcase, etc.)
- </td>
- <td colspan="1">
- <a href="attachment.cgi?bugid=1&amp;action=viewall">View All</a>
- </td>
- </tr>
-</table>
-<br>
-
-
-
- <table>
- <tr><th align="right">Bug 1 depends on:</th>
- <td>
- </td>
- <td>
- <input name="dependson"
- value="">
- </td>
- <td rowspan="2">
- <a href="showdependencytree.cgi?id=1">Show
- dependency tree</a>
-
- </td>
- </tr>
-
- <tr><th align="right">Bug 1 blocks:</th>
- <td>
- </td>
- <td>
- <input name="blocked"
- value="">
- </td>
- </tr>
- </table>
-
- <table>
- <tr>
- <th>
- <a href="votehelp.html">Votes</a>:
- </th>
- <td>0&nbsp;&nbsp;&nbsp;
- <a href="votes.cgi?action=show_bug&amp;bug_id=1">Show
- votes for this bug</a>&nbsp;&nbsp;&nbsp;
- <a href="votes.cgi?action=show_user&amp;bug_id=1">Vote
- for this bug</a>
- </td>
- </tr>
- </table>
-
-
-
- <br>
- <b>Additional Comments:</b>
- <br>
- <textarea wrap="hard" name="comment" rows="10" cols="80"
- accesskey="c"></textarea>
- <br>
-
-
-
-
- <br>
- <input type="radio" name="knob" value="none" checked="checked">
- Leave as <b>VERIFIED&nbsp;FIXED</b>
- <br>
-
-
-
- <input type="radio" name="knob" value="reopen"> Reopen bug
- <br>
- <input type="radio" name="knob" value="close">
- Mark bug as <b>CLOSED</b><br>
-
- <input type="submit" value="Commit">
- <input type="hidden" name="form_name" value="process_bug">
- <p>
- <font size="+1">
- <b>
- <a href="show_activity.cgi?id=1">View Bug Activity</a>
- &nbsp; | &nbsp;
- <a href="long_list.cgi?buglist=1">Format For Printing</a>
- </b>
- </font>
-
- </p>
-</form>
-
-
-
-<table>
- <tr>
- <td align="left">
- <b>
- <a name="c0" href="#c0">Description</a>:
- </b>
- </td>
- <td align="right" width="100%">
- Opened: 2001-10-10 21:34
- </td>
- </tr>
-</table>
-<hr>
-<!-- 1.0@bugzilla.org -->
-
-<pre>- Setup a project that contains a *.gif resource
- - release project to CVS
- - edit the *.gif resource with an external editor, e.g. PaintShop
- - save and close external editor
- - in Navigator open the icon resource and verify that your changes are there
- - release project
- -&gt; nothing to release!
- - in Navigator open the icon resource and verify that your changes are still there
-
- Problem: because I never &quot;Refreshed from local&quot;, the workspace hasn't changed so &quot;Release&quot; didn't find anything.
- However opening the resource with an external editor found the modified file on disk and showed the changes.
-
- The real problem occurs if &quot;Release&quot; actually finds something to release but you don't spot that some resources are missing.
- This is extremely error prone: one of my changes didn't made it into build 110 because of this!
-
-NOTES:
-EG (5/23/01 3:00:33 PM)
- Release should do a refresh from local before doing the release.
- Moving to VCM
-
-
-KM (05/27/01 5:10:19 PM)
- Comments from JM in related email:
-
- Should not do this for free. Could have a setting which made it optoinal but should nt be mandatory. Default setting could be to have it on.
- Consider the SWT team who keep their workspaces on network drives. This will be slow.
-
- Side effects will be that a build runs when the refresh is completed unless you somehow do it in a workspace runnable and don't end the
- runnable until after the release. This would be less than optimal as some builders may be responsible for maintaining some invariants and deriving resources which are releasable. If you don't run the builders before releasing, the invariants will not be maintained and you will release inconsistent state.
-
- Summary: Offer to &quot;ensure local consistency&quot; before releasing.
-
-KM (5/31/01 1:30:35 PM)
- See also 1GEAG1A: ITPVCM:WINNT - Internal error comparing with a document
- which failed with an error. Never got log from Tod though.</pre>
- <br>
- <i>------- Additional Comment
- <a name="c1" href="#c1">#1</a> From
- <a href="mailto:James_Moody@ca.ibm.com">James Moody</a>
- 2001-10-19 10:32 -------
- </i>
-
-
-<pre>*** <strike><a href="show_bug.cgi?id=183" title="RESOLVED DUPLICATE - readme: must refresh from local if using external editors (1GFBQNI)">Bug 183</a></strike> has been marked as a duplicate of this bug. ***</pre>
- <br>
- <i>------- Additional Comment
- <a name="c2" href="#c2">#2</a> From
- <a href="mailto:James_Moody@ca.ibm.com">James Moody</a>
- 2001-10-19 16:36 -------
- </i>
-
-
-<pre>Implemented 'auto refresh' option. Default value is off.</pre>
- <br>
- <i>------- Additional Comment
- <a name="c3" href="#c3">#3</a> From
- <a href="mailto:dj_houghton@ca.ibm.com">DJ Houghton</a>
- 2001-10-23 23:39 -------
- </i>
-
-
-<pre>PRODUCT VERSION:
- 109
-
-</pre>
- <br>
- <i>------- Additional Comment
- <a name="c4" href="#c4">#4</a> From
- <a href="mailto:James_Moody@ca.ibm.com">James Moody</a>
- 2001-10-25 10:19 -------
- </i>
-
-
-<pre>Fixed in v206</pre>
-
-<hr>
-<!-- 1.0@bugzilla.org -->
-
-
-
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="query.cgi">Query page</a>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="enter_bug.cgi">Enter new bug</a>
-
-<br>
-<!-- 1.0@bugzilla.org -->
-
-
-
-
-
-
-<table border="0">
- <tr>
- <td bgcolor="#000000" valign="top">
- <table border="0" cellpadding="10" cellspacing="0" width="100%"
- bgcolor="lightyellow">
- <tr>
- <td>
-
-
-
- This is <b>Bugzilla</b>: the Mozilla bug system. For more
- information about what Bugzilla is and what it can do, see
- <a href="http://www.bugzilla.org/">bugzilla.org</a>.
-
-
-
- <br>
-
-
-<!-- 1.0@bugzilla.org -->
-
-
-
-
-
-
-<form method="get" action="show_bug.cgi">
- <table width="100%">
- <tr>
- <td>
- Actions:
- </td>
-
- <td valign="middle" nowrap>
- <a href="enter_bug.cgi">New</a> |
- <a href="query.cgi">Query</a> |
-
- <input type="submit" value="Find"> bug #
- <input name="id" size="6"> |
-
- <a href="reports.cgi">Reports</a>
-
- </td>
-
- <td>&nbsp;</td>
-
- <td valign="middle" align="right">
- <a href="createaccount.cgi">New&nbsp;Account</a> |
- <a href="query.cgi?GoAheadAndLogIn=1">Log&nbsp;In</a>
- </td>
- </tr>
-
- </table>
-</form>
-
- </td>
- </tr>
- </table>
- </td>
- </tr>
-</table>
-
-</body>
-</html> \ No newline at end of file
diff --git a/org.eclipse.mylyn.bugzilla.tests/TestPages/bug-not-found-eclipse.html b/org.eclipse.mylyn.bugzilla.tests/TestPages/bug-not-found-eclipse.html
deleted file mode 100644
index 156212e5e..000000000
--- a/org.eclipse.mylyn.bugzilla.tests/TestPages/bug-not-found-eclipse.html
+++ /dev/null
@@ -1,158 +0,0 @@
-<!-- 1.0@bugzilla.org -->
-
-
-
-<!-- 1.0@bugzilla.org -->
-
-
-
-
-<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
-<html>
- <head>
- <title>Error</title>
-
-
-
-
-
-
-
- </head>
-
-
-
- <body bgcolor="#FFFFFF" onload="">
-
-
-<!-- 1.0@bugzilla.org -->
-
-
-
-
-<BODY BGCOLOR="#FFFFFF" TEXT="#000000" LINK="#0000EE" VLINK="#551A8B" ALINK="#FF0000" >
-<table BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH="100%" ><tr><td
-WIDTH="100%"><table BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH="100%"
-BGCOLOR="#006699" ><tr><td BGCOLOR="#000000" width="116" ><img
-src="images/EclipseBannerPic.jpg" width="115" height="50"></td><td
-WIDTH="637"><a href=http://www.eclipse.org><img SRC="images/gradient.jpg" BORDER=0 height=50
-width=282></a></td><td WIDTH="250"><img src="images/eproject-simple.gif"
-width="250" height="48"></td></tr></table></td></tr></table>
-
- <table border="0" cellspacing="0">
- <tr>
- <td valign="top" align="left">
- <table border="0" cellpadding="0" cellspacing="2">
- <tr>
- <td valign="top" align="left" nowrap="nowrap">
- <font size="+1"><b>Error</b></font>
- </td>
- </tr>
- </table>
- </td>
- <td valign="middle">&nbsp;</td>
- <td valign="middle" align="left"></td>
- </tr>
- </table>
-
-<table cellpadding="20">
- <tr>
- <td bgcolor="#ff0000">
- <font size="+2">Bug #666 does not exist.
- </font>
- </td>
- </tr>
-</table>
-
-<p>
- Please press <b>Back</b> and try again.
-</p>
-<!-- 1.0@bugzilla.org -->
-
-
-
-
-
-
-<table border="0">
- <tr>
- <td bgcolor="#000000" valign="top">
- <table border="0" cellpadding="10" cellspacing="0" width="100%"
- bgcolor="lightyellow">
- <tr>
- <td>
-
-
-
- This is <b>Bugzilla</b>: the Mozilla bug system. For more
- information about what Bugzilla is and what it can do, see
- <a href="http://www.bugzilla.org/">bugzilla.org</a>.
-
-
-
- <br>
-
-
-<!-- 1.0@bugzilla.org -->
-
-
-
-
-
-
-<form method="get" action="show_bug.cgi">
- <table width="100%">
- <tr>
- <td>
- Actions:
- </td>
-
- <td valign="middle" nowrap>
- <a href="enter_bug.cgi">New</a> |
- <a href="query.cgi">Query</a> |
-
- <input type="submit" value="Find"> bug #
- <input name="id" size="6"> |
-
- <a href="reports.cgi">Reports</a>
-
- | <a href="votes.cgi?action=show_user">My Votes</a>
- </td>
-
- <td>&nbsp;</td>
-
-
- <td valign="middle">
- Edit <a href="userprefs.cgi">prefs</a>
-
- | <a href="relogin.cgi">Log&nbsp;out</a>&nbsp;cubranic@cs.ubc.ca
- </td>
- </tr>
-
-
-
-
- <tr>
- <td>
- Preset&nbsp;Queries:
- </td>
-
- <td colspan="3">
- <a href="buglist.cgi?bug_status=NEW&bug_status=ASSIGNED&bug_status=REOPENED&email1=cubranic%40cs.ubc.ca&emailtype1=exact&emailassigned_to1=1&emailreporter1=1">My&nbsp;Bugs</a>
-
- </td>
- </tr>
-
-
- </table>
-</form>
-
- </td>
- </tr>
- </table>
- </td>
- </tr>
-</table>
-
-</body>
-</html> \ No newline at end of file
diff --git a/org.eclipse.mylyn.bugzilla.tests/TestPages/bug-not-found-hipikat.html b/org.eclipse.mylyn.bugzilla.tests/TestPages/bug-not-found-hipikat.html
deleted file mode 100644
index e6261be5d..000000000
--- a/org.eclipse.mylyn.bugzilla.tests/TestPages/bug-not-found-hipikat.html
+++ /dev/null
@@ -1,142 +0,0 @@
-<!-- 1.0@bugzilla.org -->
-
-
-
-<!-- 1.0@bugzilla.org -->
-
-
-
-
-<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
-<html>
- <head>
- <title>Error</title>
-
-
-
-
-
-
-
- </head>
-
-
-
- <body bgcolor="#FFFFFF" onload="">
-
-
-<!-- 1.0@bugzilla.org -->
-
-
-
-
- <table bgcolor="#000000" width="100%" border="0" cellpadding="0"
- cellspacing="0">
- <tr>
- <td>
- <font color="#FFFFFF" size="8"><center>
- Bugzilla Version 2.16.3
- </center></font>
- </td>
- </tr>
- </table>
-
- <table border="0" cellspacing="0">
- <tr>
- <td valign="top" align="left">
- <table border="0" cellpadding="0" cellspacing="2">
- <tr>
- <td valign="top" align="left" nowrap="nowrap">
- <font size="+1"><b>Error</b></font>
- </td>
- </tr>
- </table>
- </td>
- <td valign="middle">&nbsp;</td>
- <td valign="middle" align="left"></td>
- </tr>
- </table>
-
-<table cellpadding="20">
- <tr>
- <td bgcolor="#ff0000">
- <font size="+2">Bug #666 does not exist.
- </font>
- </td>
- </tr>
-</table>
-
-<p>
- Please press <b>Back</b> and try again.
-</p>
-<!-- 1.0@bugzilla.org -->
-
-
-
-
-
-
-<table border="0">
- <tr>
- <td bgcolor="#000000" valign="top">
- <table border="0" cellpadding="10" cellspacing="0" width="100%"
- bgcolor="lightyellow">
- <tr>
- <td>
-
-
-
- This is <b>Bugzilla</b>: the Mozilla bug system. For more
- information about what Bugzilla is and what it can do, see
- <a href="http://www.bugzilla.org/">bugzilla.org</a>.
-
-
-
- <br>
-
-
-<!-- 1.0@bugzilla.org -->
-
-
-
-
-
-
-<form method="get" action="show_bug.cgi">
- <table width="100%">
- <tr>
- <td>
- Actions:
- </td>
-
- <td valign="middle" nowrap>
- <a href="enter_bug.cgi">New</a> |
- <a href="query.cgi">Query</a> |
-
- <input type="submit" value="Find"> bug #
- <input name="id" size="6"> |
-
- <a href="reports.cgi">Reports</a>
-
- </td>
-
- <td>&nbsp;</td>
-
- <td valign="middle" align="right">
- <a href="createaccount.cgi">New&nbsp;Account</a> |
- <a href="query.cgi?GoAheadAndLogIn=1">Log&nbsp;In</a>
- </td>
- </tr>
-
- </table>
-</form>
-
- </td>
- </tr>
- </table>
- </td>
- </tr>
-</table>
-
-</body>
-</html> \ No newline at end of file
diff --git a/org.eclipse.mylyn.bugzilla.tests/TestPages/cdt-page.html b/org.eclipse.mylyn.bugzilla.tests/TestPages/cdt-page.html
deleted file mode 100644
index 3a1d20fdb..000000000
--- a/org.eclipse.mylyn.bugzilla.tests/TestPages/cdt-page.html
+++ /dev/null
@@ -1,184 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
-<!-- saved from url=(0055)https://bugs.eclipse.org/bugs/enter_bug.cgi?product=CDT -->
-<!-- 1.0@bugzilla.org --><!-- 1.0@bugzilla.org --><HTML><HEAD><TITLE>Enter Bug</TITLE>
-<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
-<META content="MSHTML 6.00.2800.1400" name=GENERATOR></HEAD>
-<BODY text=#000000 vLink=#551a8b aLink=#ff0000 link=#0000ee bgColor=#ffffff
-onload=""><!-- 1.0@bugzilla.org -->
-<TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
- <TBODY>
- <TR>
- <TD width="100%">
- <TABLE cellSpacing=0 cellPadding=0 width="100%" bgColor=#006699
- border=0><TBODY>
- <TR>
- <TD width=116 bgColor=#000000><IMG height=50
- src="Enter Bug_files/EclipseBannerPic.jpg" width=115></TD>
- <TD width=637><A href="http://www.eclipse.org/"><IMG height=50
- src="Enter Bug_files/gradient.jpg" width=282 border=0></A></TD>
- <TD width=250><IMG height=48
- src="Enter Bug_files/eproject-simple.gif"
- width=250></TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE>
-<TABLE cellSpacing=0 border=0>
- <TBODY>
- <TR>
- <TD vAlign=top align=left>
- <TABLE cellSpacing=2 cellPadding=0 border=0>
- <TBODY>
- <TR>
- <TD vAlign=top noWrap align=left><FONT size=+1><B>Enter
- Bug</B></FONT> </TD></TR></TBODY></TABLE></TD>
- <TD vAlign=center>&nbsp;</TD>
- <TD vAlign=center align=left>This page lets you enter a new bug into
- Bugzilla.</TD></TR></TBODY></TABLE>
-<FORM action=post_bug.cgi method=post><INPUT type=hidden value=CDT name=product>
-
-<TABLE cellSpacing=2 cellPadding=0 border=0>
- <TBODY>
- <TR>
- <TD><BR></TD></TR>
- <TR>
- <TD></TD>
- <TD colSpan=3><!-- 1.0@bugzilla.org -->Before reporting a bug, please read
- the <A href="https://bugs.eclipse.org/bugs/bugwritinghelp.html">bug
- writing guidelines</A>, please look at the list of <A
- href="https://bugs.eclipse.org/bugs/duplicates.cgi">most frequently
- reported bugs</A>, and please <A
- href="https://bugs.eclipse.org/bugs/query.cgi">search</A> for the bug.
- </TD></TR>
- <TR>
- <TD><BR></TD></TR>
- <TR>
- <TD vAlign=top align=right><STRONG>Reporter:</STRONG></TD>
- <TD vAlign=top>tanya@cs.ubc.ca</TD>
- <TD vAlign=top align=right><STRONG>Product:</STRONG></TD>
- <TD vAlign=top>CDT</TD></TR>
- <TR>
- <TD vAlign=top align=right><STRONG>Version:</STRONG> </TD>
- <TD><SELECT size=5 name=version> <OPTION value=1.0>1.0</OPTION> <OPTION
- value=1.0.1>1.0.1</OPTION> <OPTION value=1.1>1.1</OPTION> <OPTION
- value=1.2>1.2</OPTION> <OPTION value=2.0 selected>2.0</OPTION></SELECT>
-</TD>
- <TD vAlign=top align=right><STRONG><A
- href="https://bugs.eclipse.org/bugs/describecomponents.cgi?product=CDT">Component</A>:
- </STRONG></TD>
- <TD><SELECT size=5 name=component> <OPTION
- value=CDT-parser>CDT-parser</OPTION> <OPTION value=Core>Core</OPTION>
- <OPTION value=Cpp-Extensions>Cpp-Extensions</OPTION> <OPTION
- value=Debug>Debug</OPTION> <OPTION value=Debug-MI>Debug-MI</OPTION>
- <OPTION value=Doc>Doc</OPTION> <OPTION
- value=Generic-Extensions>Generic-Extensions</OPTION> <OPTION
- value=Launcher>Launcher</OPTION> <OPTION value=UI>UI</OPTION></SELECT>
- </TD></TR>
- <TR>
- <TD>&nbsp;</TD>
- <TD colSpan=3></TD></TR>
- <TR>
- <TD align=right><STRONG><A
- href="https://bugs.eclipse.org/bugs/bug_status.html#rep_platform">Platform</A>:
- </STRONG></TD>
- <TD><SELECT name=rep_platform> <OPTION value=All>All</OPTION> <OPTION
- value=Macintosh>Macintosh</OPTION> <OPTION value=PC selected>PC</OPTION>
- <OPTION value="Power PC">Power PC</OPTION> <OPTION
- value=Sun>Sun</OPTION> <OPTION value=Other>Other</OPTION></SELECT> </TD>
- <TD align=right><STRONG><A
- href="https://bugs.eclipse.org/bugs/bug_status.html#op_sys">OS</A>:
- </STRONG></TD>
- <TD><SELECT name=op_sys> <OPTION value=All>All</OPTION> <OPTION
- value="AIX Motif">AIX Motif</OPTION> <OPTION value="Windows 95">Windows
- 95</OPTION> <OPTION value="Windows 98">Windows 98</OPTION> <OPTION
- value="Windows CE">Windows CE</OPTION> <OPTION
- value="Windows ME">Windows ME</OPTION> <OPTION
- value="Windows 2000">Windows 2000</OPTION> <OPTION
- value="Windows NT">Windows NT</OPTION> <OPTION value="Windows XP"
- selected>Windows XP</OPTION> <OPTION value="Windows All">Windows
- All</OPTION> <OPTION value="MacOS X">MacOS X</OPTION> <OPTION
- value=Linux>Linux</OPTION> <OPTION value=Linux-GTK>Linux-GTK</OPTION>
- <OPTION value=Linux-Motif>Linux-Motif</OPTION> <OPTION
- value=HP-UX>HP-UX</OPTION> <OPTION value=Neutrino>Neutrino</OPTION>
- <OPTION value=QNX-Photon>QNX-Photon</OPTION> <OPTION
- value=Solaris>Solaris</OPTION> <OPTION value="Unix All">Unix
- All</OPTION> <OPTION value=other>other</OPTION></SELECT> </TD></TR>
- <TR><INPUT type=hidden value=P3 name=priority>
- <TD align=right><STRONG><A
- href="https://bugs.eclipse.org/bugs/bug_status.html#bug_severity">Severity</A>:
- </STRONG></TD>
- <TD><SELECT name=bug_severity> <OPTION value=blocker>blocker</OPTION>
- <OPTION value=critical>critical</OPTION> <OPTION
- value=major>major</OPTION> <OPTION value=normal selected>normal</OPTION>
- <OPTION value=minor>minor</OPTION> <OPTION
- value=trivial>trivial</OPTION> <OPTION
- value=enhancement>enhancement</OPTION></SELECT> </TD></TR>
- <TR>
- <TD>&nbsp;</TD>
- <TD colSpan=3></TD></TR><INPUT type=hidden value=NEW name=bug_status>
- <TR>
- <TD align=right><STRONG><A
- href="https://bugs.eclipse.org/bugs/bug_status.html#assigned_to">Assigned
- To</A>: </STRONG></TD>
- <TD colSpan=3><INPUT size=32 name=assigned_to> (Leave blank to assign to
- default component owner) </TD></TR>
- <TR>
- <TD align=right><STRONG>Cc:</STRONG></TD>
- <TD colSpan=3><INPUT size=45 name=cc> </TD></TR>
- <TR>
- <TD>&nbsp;</TD>
- <TD colSpan=3></TD></TR>
- <TR>
- <TD colSpan=3><INPUT type=hidden size=60 name=bug_file_loc input> </TD></TR>
- <TR>
- <TD align=right><STRONG>Summary:</STRONG></TD>
- <TD colSpan=3><INPUT size=60 name=short_desc> </TD></TR>
- <TR>
- <TD vAlign=top align=right><STRONG>Description:</STRONG></TD>
- <TD colSpan=3><TEXTAREA name=comment rows=10 wrap=hard cols=80></TEXTAREA>
- <BR></TD></TR>
- <TR>
- <TD></TD>
- <TD colSpan=3></TD></TR>
- <TR>
- <TD></TD>
- <TD colSpan=3><INPUT onclick="if (this.form.short_desc.value == '') &#10; { alert('Please enter a summary sentence for this bug.'); &#10; return false; } return true;" type=submit value=" Commit ">
- &nbsp;&nbsp;&nbsp;&nbsp; <INPUT type=submit value="Remember values as bookmarkable template" name=maketemplate>
- </TD></TR>
- <TR>
- <TD></TD>
- <TD colSpan=3><BR>We've made a guess at your operating system and
- platform. Please check them and, if we got it wrong, email
- webmaster@eclipse.org. </TD></TR></TBODY></TABLE><INPUT type=hidden
-value=enter_bug name=form_name> </FORM><!-- 1.0@bugzilla.org -->
-<TABLE border=0>
- <TBODY>
- <TR>
- <TD vAlign=top bgColor=#000000>
- <TABLE cellSpacing=0 cellPadding=10 width="100%" bgColor=lightyellow
- border=0>
- <TBODY>
- <TR>
- <TD>This is <B>Bugzilla</B>: the Mozilla bug system. For more
- information about what Bugzilla is and what it can do, see <A
- href="http://www.bugzilla.org/">bugzilla.org</A>. <BR><!-- 1.0@bugzilla.org -->
- <FORM action=show_bug.cgi method=get>
- <TABLE width="100%">
- <TBODY>
- <TR>
- <TD>Actions: </TD>
- <TD vAlign=center noWrap><A
- href="https://bugs.eclipse.org/bugs/enter_bug.cgi">New</A> |
- <A href="https://bugs.eclipse.org/bugs/query.cgi">Query</A> | <INPUT type=submit value=Find> bug # <INPUT size=6 name=id> |
- <A
- href="https://bugs.eclipse.org/bugs/reports.cgi">Reports</A> |
- <A
- href="https://bugs.eclipse.org/bugs/votes.cgi?action=show_user">My
- Votes</A> </TD>
- <TD>&nbsp;</TD>
- <TD vAlign=center>Edit <A
- href="https://bugs.eclipse.org/bugs/userprefs.cgi">prefs</A> |
- <A
- href="https://bugs.eclipse.org/bugs/relogin.cgi">Log&nbsp;out</A>&nbsp;tanya@cs.ubc.ca
- </TD></TR>
- <TR>
- <TD>Preset&nbsp;Queries: </TD>
- <TD colSpan=3><A
- href="https://bugs.eclipse.org/bugs/buglist.cgi?bug_status=NEW&amp;bug_status=ASSIGNED&amp;bug_status=REOPENED&amp;email1=tanya%40cs.ubc.ca&amp;emailtype1=exact&amp;emailassigned_to1=1&amp;emailreporter1=1">My&nbsp;Bugs</A>
- </TD></TR></TBODY></TABLE></FORM></TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE></BODY></HTML>
diff --git a/org.eclipse.mylyn.bugzilla.tests/TestPages/equinox-page.html b/org.eclipse.mylyn.bugzilla.tests/TestPages/equinox-page.html
deleted file mode 100644
index 1c8fdf57d..000000000
--- a/org.eclipse.mylyn.bugzilla.tests/TestPages/equinox-page.html
+++ /dev/null
@@ -1,177 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
-<!-- saved from url=(0059)https://bugs.eclipse.org/bugs/enter_bug.cgi?product=Equinox -->
-<!-- 1.0@bugzilla.org --><!-- 1.0@bugzilla.org --><HTML><HEAD><TITLE>Enter Bug</TITLE>
-<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
-<META content="MSHTML 6.00.2800.1400" name=GENERATOR></HEAD>
-<BODY text=#000000 vLink=#551a8b aLink=#ff0000 link=#0000ee bgColor=#ffffff
-onload=""><!-- 1.0@bugzilla.org -->
-<TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
- <TBODY>
- <TR>
- <TD width="100%">
- <TABLE cellSpacing=0 cellPadding=0 width="100%" bgColor=#006699
- border=0><TBODY>
- <TR>
- <TD width=116 bgColor=#000000><IMG height=50
- src="Equinox_files/EclipseBannerPic.jpg" width=115></TD>
- <TD width=637><A href="http://www.eclipse.org/"><IMG height=50
- src="Equinox_files/gradient.jpg" width=282 border=0></A></TD>
- <TD width=250><IMG height=48 src="Equinox_files/eproject-simple.gif"
- width=250></TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE>
-<TABLE cellSpacing=0 border=0>
- <TBODY>
- <TR>
- <TD vAlign=top align=left>
- <TABLE cellSpacing=2 cellPadding=0 border=0>
- <TBODY>
- <TR>
- <TD vAlign=top noWrap align=left><FONT size=+1><B>Enter
- Bug</B></FONT> </TD></TR></TBODY></TABLE></TD>
- <TD vAlign=center>&nbsp;</TD>
- <TD vAlign=center align=left>This page lets you enter a new bug into
- Bugzilla.</TD></TR></TBODY></TABLE>
-<FORM action=post_bug.cgi method=post><INPUT type=hidden value=Equinox
-name=product>
-<TABLE cellSpacing=2 cellPadding=0 border=0>
- <TBODY>
- <TR>
- <TD><BR></TD></TR>
- <TR>
- <TD></TD>
- <TD colSpan=3><!-- 1.0@bugzilla.org -->Before reporting a bug, please read
- the <A href="https://bugs.eclipse.org/bugs/bugwritinghelp.html">bug
- writing guidelines</A>, please look at the list of <A
- href="https://bugs.eclipse.org/bugs/duplicates.cgi">most frequently
- reported bugs</A>, and please <A
- href="https://bugs.eclipse.org/bugs/query.cgi">search</A> for the bug.
- </TD></TR>
- <TR>
- <TD><BR></TD></TR>
- <TR>
- <TD vAlign=top align=right><STRONG>Reporter:</STRONG></TD>
- <TD vAlign=top>tanya@cs.ubc.ca</TD>
- <TD vAlign=top align=right><STRONG>Product:</STRONG></TD>
- <TD vAlign=top>Equinox</TD></TR>
- <TR>
- <TD vAlign=top align=right><STRONG>Version:</STRONG> </TD>
- <TD><SELECT size=5 name=version> <OPTION value=unspecified
- selected>unspecified</OPTION></SELECT> </TD>
- <TD vAlign=top align=right><STRONG><A
- href="https://bugs.eclipse.org/bugs/describecomponents.cgi?product=Equinox">Component</A>:
- </STRONG></TD>
- <TD><SELECT size=5 name=component> <OPTION
- value="Dynamic Plugins">Dynamic Plugins</OPTION> <OPTION
- value=General>General</OPTION> <OPTION value=OSGi>OSGi</OPTION></SELECT>
- </TD></TR>
- <TR>
- <TD>&nbsp;</TD>
- <TD colSpan=3></TD></TR>
- <TR>
- <TD align=right><STRONG><A
- href="https://bugs.eclipse.org/bugs/bug_status.html#rep_platform">Platform</A>:
- </STRONG></TD>
- <TD><SELECT name=rep_platform> <OPTION value=All>All</OPTION> <OPTION
- value=Macintosh>Macintosh</OPTION> <OPTION value=PC selected>PC</OPTION>
- <OPTION value="Power PC">Power PC</OPTION> <OPTION
- value=Sun>Sun</OPTION> <OPTION value=Other>Other</OPTION></SELECT> </TD>
- <TD align=right><STRONG><A
- href="https://bugs.eclipse.org/bugs/bug_status.html#op_sys">OS</A>:
- </STRONG></TD>
- <TD><SELECT name=op_sys> <OPTION value=All>All</OPTION> <OPTION
- value="AIX Motif">AIX Motif</OPTION> <OPTION value="Windows 95">Windows
- 95</OPTION> <OPTION value="Windows 98">Windows 98</OPTION> <OPTION
- value="Windows CE">Windows CE</OPTION> <OPTION
- value="Windows ME">Windows ME</OPTION> <OPTION
- value="Windows 2000">Windows 2000</OPTION> <OPTION
- value="Windows NT">Windows NT</OPTION> <OPTION value="Windows XP"
- selected>Windows XP</OPTION> <OPTION value="Windows All">Windows
- All</OPTION> <OPTION value="MacOS X">MacOS X</OPTION> <OPTION
- value=Linux>Linux</OPTION> <OPTION value=Linux-GTK>Linux-GTK</OPTION>
- <OPTION value=Linux-Motif>Linux-Motif</OPTION> <OPTION
- value=HP-UX>HP-UX</OPTION> <OPTION value=Neutrino>Neutrino</OPTION>
- <OPTION value=QNX-Photon>QNX-Photon</OPTION> <OPTION
- value=Solaris>Solaris</OPTION> <OPTION value="Unix All">Unix
- All</OPTION> <OPTION value=other>other</OPTION></SELECT> </TD></TR>
- <TR><INPUT type=hidden value=P3 name=priority>
- <TD align=right><STRONG><A
- href="https://bugs.eclipse.org/bugs/bug_status.html#bug_severity">Severity</A>:
- </STRONG></TD>
- <TD><SELECT name=bug_severity> <OPTION value=blocker>blocker</OPTION>
- <OPTION value=critical>critical</OPTION> <OPTION
- value=major>major</OPTION> <OPTION value=normal selected>normal</OPTION>
- <OPTION value=minor>minor</OPTION> <OPTION
- value=trivial>trivial</OPTION> <OPTION
- value=enhancement>enhancement</OPTION></SELECT> </TD></TR>
- <TR>
- <TD>&nbsp;</TD>
- <TD colSpan=3></TD></TR><INPUT type=hidden value=NEW name=bug_status>
- <TR>
- <TD align=right><STRONG><A
- href="https://bugs.eclipse.org/bugs/bug_status.html#assigned_to">Assigned
- To</A>: </STRONG></TD>
- <TD colSpan=3><INPUT size=32 name=assigned_to> (Leave blank to assign to
- default component owner) </TD></TR>
- <TR>
- <TD align=right><STRONG>Cc:</STRONG></TD>
- <TD colSpan=3><INPUT size=45 name=cc> </TD></TR>
- <TR>
- <TD>&nbsp;</TD>
- <TD colSpan=3></TD></TR>
- <TR>
- <TD colSpan=3><INPUT type=hidden size=60 name=bug_file_loc input> </TD></TR>
- <TR>
- <TD align=right><STRONG>Summary:</STRONG></TD>
- <TD colSpan=3><INPUT size=60 name=short_desc> </TD></TR>
- <TR>
- <TD vAlign=top align=right><STRONG>Description:</STRONG></TD>
- <TD colSpan=3><TEXTAREA name=comment rows=10 wrap=hard cols=80></TEXTAREA>
- <BR></TD></TR>
- <TR>
- <TD></TD>
- <TD colSpan=3></TD></TR>
- <TR>
- <TD></TD>
- <TD colSpan=3><INPUT onclick="if (this.form.short_desc.value == '') &#10; { alert('Please enter a summary sentence for this bug.'); &#10; return false; } return true;" type=submit value=" Commit ">
- &nbsp;&nbsp;&nbsp;&nbsp; <INPUT type=submit value="Remember values as bookmarkable template" name=maketemplate>
- </TD></TR>
- <TR>
- <TD></TD>
- <TD colSpan=3><BR>We've made a guess at your operating system and
- platform. Please check them and, if we got it wrong, email
- webmaster@eclipse.org. </TD></TR></TBODY></TABLE><INPUT type=hidden
-value=enter_bug name=form_name> </FORM><!-- 1.0@bugzilla.org -->
-<TABLE border=0>
- <TBODY>
- <TR>
- <TD vAlign=top bgColor=#000000>
- <TABLE cellSpacing=0 cellPadding=10 width="100%" bgColor=lightyellow
- border=0>
- <TBODY>
- <TR>
- <TD>This is <B>Bugzilla</B>: the Mozilla bug system. For more
- information about what Bugzilla is and what it can do, see <A
- href="http://www.bugzilla.org/">bugzilla.org</A>. <BR><!-- 1.0@bugzilla.org -->
- <FORM action=show_bug.cgi method=get>
- <TABLE width="100%">
- <TBODY>
- <TR>
- <TD>Actions: </TD>
- <TD vAlign=center noWrap><A
- href="https://bugs.eclipse.org/bugs/enter_bug.cgi">New</A> |
- <A href="https://bugs.eclipse.org/bugs/query.cgi">Query</A> | <INPUT type=submit value=Find> bug # <INPUT size=6 name=id> |
- <A
- href="https://bugs.eclipse.org/bugs/reports.cgi">Reports</A> |
- <A
- href="https://bugs.eclipse.org/bugs/votes.cgi?action=show_user">My
- Votes</A> </TD>
- <TD>&nbsp;</TD>
- <TD vAlign=center>Edit <A
- href="https://bugs.eclipse.org/bugs/userprefs.cgi">prefs</A> |
- <A
- href="https://bugs.eclipse.org/bugs/relogin.cgi">Log&nbsp;out</A>&nbsp;tanya@cs.ubc.ca
- </TD></TR>
- <TR>
- <TD>Preset&nbsp;Queries: </TD>
- <TD colSpan=3><A
- href="https://bugs.eclipse.org/bugs/buglist.cgi?bug_status=NEW&amp;bug_status=ASSIGNED&amp;bug_status=REOPENED&amp;email1=tanya%40cs.ubc.ca&amp;emailtype1=exact&amp;emailassigned_to1=1&amp;emailreporter1=1">My&nbsp;Bugs</A>
- </TD></TR></TBODY></TABLE></FORM></TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE></BODY></HTML>
diff --git a/org.eclipse.mylyn.bugzilla.tests/TestPages/gmt-page.html b/org.eclipse.mylyn.bugzilla.tests/TestPages/gmt-page.html
deleted file mode 100644
index 951b86ccd..000000000
--- a/org.eclipse.mylyn.bugzilla.tests/TestPages/gmt-page.html
+++ /dev/null
@@ -1,175 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
-<!-- saved from url=(0055)https://bugs.eclipse.org/bugs/enter_bug.cgi?product=GMT -->
-<!-- 1.0@bugzilla.org --><!-- 1.0@bugzilla.org --><HTML><HEAD><TITLE>Enter Bug</TITLE>
-<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
-<META content="MSHTML 6.00.2800.1400" name=GENERATOR></HEAD>
-<BODY text=#000000 vLink=#551a8b aLink=#ff0000 link=#0000ee bgColor=#ffffff
-onload=""><!-- 1.0@bugzilla.org -->
-<TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
- <TBODY>
- <TR>
- <TD width="100%">
- <TABLE cellSpacing=0 cellPadding=0 width="100%" bgColor=#006699
- border=0><TBODY>
- <TR>
- <TD width=116 bgColor=#000000><IMG height=50
- src="GMT_files/EclipseBannerPic.jpg" width=115></TD>
- <TD width=637><A href="http://www.eclipse.org/"><IMG height=50
- src="GMT_files/gradient.jpg" width=282 border=0></A></TD>
- <TD width=250><IMG height=48 src="GMT_files/eproject-simple.gif"
- width=250></TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE>
-<TABLE cellSpacing=0 border=0>
- <TBODY>
- <TR>
- <TD vAlign=top align=left>
- <TABLE cellSpacing=2 cellPadding=0 border=0>
- <TBODY>
- <TR>
- <TD vAlign=top noWrap align=left><FONT size=+1><B>Enter
- Bug</B></FONT> </TD></TR></TBODY></TABLE></TD>
- <TD vAlign=center>&nbsp;</TD>
- <TD vAlign=center align=left>This page lets you enter a new bug into
- Bugzilla.</TD></TR></TBODY></TABLE>
-<FORM action=post_bug.cgi method=post><INPUT type=hidden value=GMT name=product>
-
-<TABLE cellSpacing=2 cellPadding=0 border=0>
- <TBODY>
- <TR>
- <TD><BR></TD></TR>
- <TR>
- <TD></TD>
- <TD colSpan=3><!-- 1.0@bugzilla.org -->Before reporting a bug, please read
- the <A href="https://bugs.eclipse.org/bugs/bugwritinghelp.html">bug
- writing guidelines</A>, please look at the list of <A
- href="https://bugs.eclipse.org/bugs/duplicates.cgi">most frequently
- reported bugs</A>, and please <A
- href="https://bugs.eclipse.org/bugs/query.cgi">search</A> for the bug.
- </TD></TR>
- <TR>
- <TD><BR></TD></TR>
- <TR>
- <TD vAlign=top align=right><STRONG>Reporter:</STRONG></TD>
- <TD vAlign=top>tanya@cs.ubc.ca</TD>
- <TD vAlign=top align=right><STRONG>Product:</STRONG></TD>
- <TD vAlign=top>GMT</TD></TR>
- <TR>
- <TD vAlign=top align=right><STRONG>Version:</STRONG> </TD>
- <TD><SELECT size=5 name=version> <OPTION value=unspecified
- selected>unspecified</OPTION></SELECT> </TD>
- <TD vAlign=top align=right><STRONG><A
- href="https://bugs.eclipse.org/bugs/describecomponents.cgi?product=GMT">Component</A>:
- </STRONG></TD>
- <TD><SELECT size=5 name=component> <OPTION value=Core
- selected>Core</OPTION></SELECT> </TD></TR>
- <TR>
- <TD>&nbsp;</TD>
- <TD colSpan=3></TD></TR>
- <TR>
- <TD align=right><STRONG><A
- href="https://bugs.eclipse.org/bugs/bug_status.html#rep_platform">Platform</A>:
- </STRONG></TD>
- <TD><SELECT name=rep_platform> <OPTION value=All>All</OPTION> <OPTION
- value=Macintosh>Macintosh</OPTION> <OPTION value=PC selected>PC</OPTION>
- <OPTION value="Power PC">Power PC</OPTION> <OPTION
- value=Sun>Sun</OPTION> <OPTION value=Other>Other</OPTION></SELECT> </TD>
- <TD align=right><STRONG><A
- href="https://bugs.eclipse.org/bugs/bug_status.html#op_sys">OS</A>:
- </STRONG></TD>
- <TD><SELECT name=op_sys> <OPTION value=All>All</OPTION> <OPTION
- value="AIX Motif">AIX Motif</OPTION> <OPTION value="Windows 95">Windows
- 95</OPTION> <OPTION value="Windows 98">Windows 98</OPTION> <OPTION
- value="Windows CE">Windows CE</OPTION> <OPTION
- value="Windows ME">Windows ME</OPTION> <OPTION
- value="Windows 2000">Windows 2000</OPTION> <OPTION
- value="Windows NT">Windows NT</OPTION> <OPTION value="Windows XP"
- selected>Windows XP</OPTION> <OPTION value="Windows All">Windows
- All</OPTION> <OPTION value="MacOS X">MacOS X</OPTION> <OPTION
- value=Linux>Linux</OPTION> <OPTION value=Linux-GTK>Linux-GTK</OPTION>
- <OPTION value=Linux-Motif>Linux-Motif</OPTION> <OPTION
- value=HP-UX>HP-UX</OPTION> <OPTION value=Neutrino>Neutrino</OPTION>
- <OPTION value=QNX-Photon>QNX-Photon</OPTION> <OPTION
- value=Solaris>Solaris</OPTION> <OPTION value="Unix All">Unix
- All</OPTION> <OPTION value=other>other</OPTION></SELECT> </TD></TR>
- <TR><INPUT type=hidden value=P3 name=priority>
- <TD align=right><STRONG><A
- href="https://bugs.eclipse.org/bugs/bug_status.html#bug_severity">Severity</A>:
- </STRONG></TD>
- <TD><SELECT name=bug_severity> <OPTION value=blocker>blocker</OPTION>
- <OPTION value=critical>critical</OPTION> <OPTION
- value=major>major</OPTION> <OPTION value=normal selected>normal</OPTION>
- <OPTION value=minor>minor</OPTION> <OPTION
- value=trivial>trivial</OPTION> <OPTION
- value=enhancement>enhancement</OPTION></SELECT> </TD></TR>
- <TR>
- <TD>&nbsp;</TD>
- <TD colSpan=3></TD></TR><INPUT type=hidden value=NEW name=bug_status>
- <TR>
- <TD align=right><STRONG><A
- href="https://bugs.eclipse.org/bugs/bug_status.html#assigned_to">Assigned
- To</A>: </STRONG></TD>
- <TD colSpan=3><INPUT size=32 name=assigned_to> (Leave blank to assign to
- default component owner) </TD></TR>
- <TR>
- <TD align=right><STRONG>Cc:</STRONG></TD>
- <TD colSpan=3><INPUT size=45 name=cc> </TD></TR>
- <TR>
- <TD>&nbsp;</TD>
- <TD colSpan=3></TD></TR>
- <TR>
- <TD colSpan=3><INPUT type=hidden size=60 name=bug_file_loc input> </TD></TR>
- <TR>
- <TD align=right><STRONG>Summary:</STRONG></TD>
- <TD colSpan=3><INPUT size=60 name=short_desc> </TD></TR>
- <TR>
- <TD vAlign=top align=right><STRONG>Description:</STRONG></TD>
- <TD colSpan=3><TEXTAREA name=comment rows=10 wrap=hard cols=80></TEXTAREA>
- <BR></TD></TR>
- <TR>
- <TD></TD>
- <TD colSpan=3></TD></TR>
- <TR>
- <TD></TD>
- <TD colSpan=3><INPUT onclick="if (this.form.short_desc.value == '') &#10; { alert('Please enter a summary sentence for this bug.'); &#10; return false; } return true;" type=submit value=" Commit ">
- &nbsp;&nbsp;&nbsp;&nbsp; <INPUT type=submit value="Remember values as bookmarkable template" name=maketemplate>
- </TD></TR>
- <TR>
- <TD></TD>
- <TD colSpan=3><BR>We've made a guess at your operating system and
- platform. Please check them and, if we got it wrong, email
- webmaster@eclipse.org. </TD></TR></TBODY></TABLE><INPUT type=hidden
-value=enter_bug name=form_name> </FORM><!-- 1.0@bugzilla.org -->
-<TABLE border=0>
- <TBODY>
- <TR>
- <TD vAlign=top bgColor=#000000>
- <TABLE cellSpacing=0 cellPadding=10 width="100%" bgColor=lightyellow
- border=0>
- <TBODY>
- <TR>
- <TD>This is <B>Bugzilla</B>: the Mozilla bug system. For more
- information about what Bugzilla is and what it can do, see <A
- href="http://www.bugzilla.org/">bugzilla.org</A>. <BR><!-- 1.0@bugzilla.org -->
- <FORM action=show_bug.cgi method=get>
- <TABLE width="100%">
- <TBODY>
- <TR>
- <TD>Actions: </TD>
- <TD vAlign=center noWrap><A
- href="https://bugs.eclipse.org/bugs/enter_bug.cgi">New</A> |
- <A href="https://bugs.eclipse.org/bugs/query.cgi">Query</A> | <INPUT type=submit value=Find> bug # <INPUT size=6 name=id> |
- <A
- href="https://bugs.eclipse.org/bugs/reports.cgi">Reports</A> |
- <A
- href="https://bugs.eclipse.org/bugs/votes.cgi?action=show_user">My
- Votes</A> </TD>
- <TD>&nbsp;</TD>
- <TD vAlign=center>Edit <A
- href="https://bugs.eclipse.org/bugs/userprefs.cgi">prefs</A> |
- <A
- href="https://bugs.eclipse.org/bugs/relogin.cgi">Log&nbsp;out</A>&nbsp;tanya@cs.ubc.ca
- </TD></TR>
- <TR>
- <TD>Preset&nbsp;Queries: </TD>
- <TD colSpan=3><A
- href="https://bugs.eclipse.org/bugs/buglist.cgi?bug_status=NEW&amp;bug_status=ASSIGNED&amp;bug_status=REOPENED&amp;email1=tanya%40cs.ubc.ca&amp;emailtype1=exact&amp;emailassigned_to1=1&amp;emailreporter1=1">My&nbsp;Bugs</A>
- </TD></TR></TBODY></TABLE></FORM></TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE></BODY></HTML>
diff --git a/org.eclipse.mylyn.bugzilla.tests/TestPages/hipikat-copy-bug-1-full.html b/org.eclipse.mylyn.bugzilla.tests/TestPages/hipikat-copy-bug-1-full.html
deleted file mode 100644
index 6390fcc9a..000000000
--- a/org.eclipse.mylyn.bugzilla.tests/TestPages/hipikat-copy-bug-1-full.html
+++ /dev/null
@@ -1,157 +0,0 @@
-<HTML><HEAD>
-<TITLE>Bug 1 - Usability issue with external editors (1GE6IRL)</TITLE>
-
-
-</HEAD>
-<BODY BGCOLOR="#FFFFFF" TEXT="#000000" LINK="#0000EE" VLINK="#551A8B" ALINK="#FF0000" >
-<table BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH="100%" ><tr><td
-WIDTH="100%"><table BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH="100%"
-BGCOLOR="#006699" ><tr><td BGCOLOR="#000000" width="116" ><img
-src="http://bugs.eclipse.org/bugs/images/EclipseBannerPic.jpg" width="115" height="50"></td><td
-WIDTH="637"><img SRC="http://bugs.eclipse.org/bugs/images/gradient.jpg" BORDER=0 height=50
-width=282></td><td WIDTH="250"><img src="http://bugs.eclipse.org/bugs/images/eproject-simple.gif"
-width="250" height="48"></td></tr></table></td></tr></table>
-
-<TABLE BORDER=0 CELLSPACING=0 WIDTH="100%">
- <TR>
- <TD WIDTH=10% VALIGN=TOP ALIGN=LEFT>
- <TABLE BORDER=0 CELLPADDING=0 CELLSPACING=2>
- <TR><TD VALIGN=TOP ALIGN=LEFT NOWRAP>
- <FONT SIZE=+1><B>Bugzilla Bug 1</B></FONT> </TD></TR>
- </TABLE>
- </TD>
- <TD VALIGN=CENTER>&nbsp;</TD>
- <TD VALIGN=CENTER ALIGN=LEFT>
-Usability issue with external editors (1GE6IRL)
-</TD></TR></TABLE>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<A HREF=query.cgi>Query page</A>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<A HREF=enter_bug.cgi>Enter new bug</A>
-<HR>
-<FORM NAME="changeform" METHOD="POST" ACTION="process_bug.cgi">
-
-<INPUT TYPE=HIDDEN NAME="delta_ts" VALUE="20020427143827">
-<INPUT TYPE=HIDDEN NAME="longdesclength" VALUE="3022">
-<INPUT TYPE=HIDDEN NAME="id" VALUE=1>
- <TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0><TR>
- <TD ALIGN=RIGHT><B>Bug#:</B></TD><TD><A HREF="http://cvs-mirror.mozilla.org/webtools/bugzilla/show_bug.cgi?id=1">1</A></TD>
- <TD>&nbsp;</TD>
- <TD ALIGN=RIGHT><B><A HREF="bug_status.html#rep_platform">Platform:</A></B></TD>
- <TD><SELECT NAME=rep_platform><OPTION VALUE="All">All<OPTION VALUE="DEC">DEC<OPTION VALUE="HP">HP<OPTION VALUE="Macintosh">Macintosh<OPTION VALUE="PC">PC<OPTION VALUE="SGI">SGI<OPTION VALUE="Sun">Sun<OPTION VALUE="Other">Other</SELECT></TD>
- <TD>&nbsp;</TD>
- <TD ALIGN=RIGHT><B>Reporter:</B></TD><TD>Andre_Weinand@oti.com (Andre Weinand)</TD>
-</TR><TR>
- <TD ALIGN=RIGHT><B>Product:</B></TD>
- <TD><SELECT NAME=product><OPTION VALUE="TestProduct">TestProduct</SELECT></TD>
- <TD>&nbsp;</TD>
- <TD ALIGN=RIGHT><B>OS:</B></TD>
- <TD><SELECT NAME=op_sys><OPTION SELECTED VALUE="All">All<OPTION VALUE="Windows 3.1">Windows 3.1<OPTION VALUE="Windows 95">Windows 95<OPTION VALUE="Windows 98">Windows 98<OPTION VALUE="Windows ME">Windows ME<OPTION VALUE="Windows 2000">Windows 2000<OPTION VALUE="Windows NT">Windows NT<OPTION VALUE="Mac System 7">Mac System 7<OPTION VALUE="Mac System 7.5">Mac System 7.5<OPTION VALUE="Mac System 7.6.1">Mac System 7.6.1<OPTION VALUE="Mac System 8.0">Mac System 8.0<OPTION VALUE="Mac System 8.5">Mac System 8.5<OPTION VALUE="Mac System 8.6">Mac System 8.6<OPTION VALUE="Mac System 9.0">Mac System 9.0<OPTION VALUE="Linux">Linux<OPTION VALUE="BSDI">BSDI<OPTION VALUE="FreeBSD">FreeBSD<OPTION VALUE="NetBSD">NetBSD<OPTION VALUE="OpenBSD">OpenBSD<OPTION VALUE="AIX">AIX<OPTION VALUE="BeOS">BeOS<OPTION VALUE="HP-UX">HP-UX<OPTION VALUE="IRIX">IRIX<OPTION VALUE="Neutrino">Neutrino<OPTION VALUE="OpenVMS">OpenVMS<OPTION VALUE="OS/2">OS/2<OPTION VALUE="OSF/1">OSF/1<OPTION VALUE="Solaris">Solaris<OPTION VALUE="SunOS">SunOS<OPTION VALUE="other">other</SELECT></TD>
- <TD>&nbsp;</TD>
- <TD ALIGN=RIGHT NOWRAP><b>Add CC:</b></TD>
- <TD><INPUT NAME=newcc SIZE=30 VALUE=""></TD>
-</TR><TR>
- <TD ALIGN=RIGHT><B><A HREF="describecomponents.cgi?product=">Component:</A></B></TD>
- <TD><SELECT NAME=component></SELECT></TD>
- <TD>&nbsp;</TD>
- <TD ALIGN=RIGHT><B>Version:</B></TD>
- <TD><SELECT NAME=version></SELECT></TD>
- <TD>&nbsp;</TD>
- <TD ROWSPAN=4 ALIGN=RIGHT VALIGN=TOP><B>Cc:</B></TD>
- <TD ROWSPAN=4 VALIGN=TOP> <SELECT NAME=cc MULTIPLE SIZE=5>
-<OPTION VALUE="Kevin_McGuire@oti.com">Kevin_McGuire@oti.com
-</SELECT><BR>
-<INPUT TYPE=CHECKBOX NAME=removecc>Remove selected CCs<br>
- </TD>
-</TR><TR>
- <TD ALIGN=RIGHT><B><A HREF="bug_status.html">Status:</A></B></TD>
- <TD>VERIFIED</TD>
- <TD>&nbsp;</TD>
- <TD ALIGN=RIGHT><B><A HREF="bug_status.html#priority">Priority:</A></B></TD>
- <TD><SELECT NAME=priority><OPTION VALUE="P1">P1<OPTION VALUE="P2">P2<OPTION SELECTED VALUE="P3">P3<OPTION VALUE="P4">P4<OPTION VALUE="P5">P5</SELECT></TD>
- <TD>&nbsp;</TD>
-</TR><TR>
- <TD ALIGN=RIGHT><B><A HREF="bug_status.html">Resolution:</A></B></TD>
- <TD>FIXED</TD>
- <TD>&nbsp;</TD>
- <TD ALIGN=RIGHT><B><A HREF="bug_status.html#severity">Severity:</A></B></TD>
- <TD><SELECT NAME=bug_severity><OPTION VALUE="blocker">blocker<OPTION VALUE="critical">critical<OPTION VALUE="major">major<OPTION SELECTED VALUE="normal">normal<OPTION VALUE="minor">minor<OPTION VALUE="trivial">trivial<OPTION VALUE="enhancement">enhancement</SELECT></TD>
- <TD>&nbsp;</TD>
-</TR><TR>
- <TD ALIGN=RIGHT><B><A HREF="bug_status.html#assigned_to">Assigned&nbsp;To:
- </A></B></TD>
- <TD>James_Moody@oti.com (James Moody)</TD>
- <TD>&nbsp;</TD><TD></TD><TD></TD><TD>&nbsp;</TD>
-</TR>
- <TR>
- <TD ALIGN="RIGHT"><B>URL:</B>
- <TD COLSPAN=7>
- <INPUT NAME=bug_file_loc VALUE="" SIZE=60></TD>
- </TR><TR>
- <TD ALIGN="RIGHT"><B>Summary:</B>
- <TD COLSPAN=7>
- <INPUT NAME=short_desc VALUE="Usability issue with external editors (1GE6IRL)" SIZE=60></TD>
- </TR><tr><td align=right><B>Attachments:</b></td>
-<td colspan=7><a href="createattachment.cgi?id=1">Create a new attachment</a> (proposed patch, testcase, etc.)</td></tr></table>
-<table><tr>
-<th align=right>Bug 1 depends on:</th><td></td><td><input name=dependson value=""></td>
-
-<td rowspan=2><a href="showdependencytree.cgi?id=1">Show dependency tree</a>
-
-<br><a href="showdependencygraph.cgi?id=1">Show dependency graph</a>
-</td></tr><tr><th align=right>Bug 1 blocks:</th><td></td><td><input name=blocked value=""></td>
-</tr></table>
-
-<br>
-<B>Additional Comments:</B>
-<BR>
-<TEXTAREA WRAP=HARD NAME=comment ROWS=10 COLS=80></TEXTAREA><BR><br>
-<INPUT TYPE=radio NAME=knob VALUE=none CHECKED>
- Leave as <b>VERIFIED FIXED</b><br><INPUT TYPE=radio NAME=knob VALUE=reopen> Reopen bug<br>
-<INPUT TYPE=radio NAME=knob VALUE=close>
- Mark bug as <b>CLOSED</b><br>
-
-<INPUT TYPE="submit" VALUE="Commit">
-<INPUT TYPE="reset" VALUE="Reset">
-<INPUT TYPE="hidden" name="form_name" VALUE="process_bug">
-<P>
-<FONT size="+1"><B>
- <A HREF="show_activity.cgi?id=1">View Bug Activity</A>
- &nbsp; | &nbsp;
- <A HREF="long_list.cgi?buglist=1">Format For Printing</A>
-</B></FONT>
-<BR></FORM>
-<table><tr><td align=left><B>Description:</B></td>
-<td align=right width=100%>Opened: 2001-10-10 17:34</td></tr></table>
-<HR>
-<PRE>- Setup a project that contains a *.gif resource&#013; - release project to CVS&#013; - edit the *.gif resource with an external editor, e.g. PaintShop&#013; - save and close external editor&#013; - in Navigator open the icon resource and verify that your changes are there&#013; - release project&#013; -&gt; nothing to release!&#013; - in Navigator open the icon resource and verify that your changes are still there&#013;&#013; Problem: because I never &quot;Refreshed from local&quot;, the workspace hasn't changed so &quot;Release&quot; didn't find anything.&#013; However opening the resource with an external editor found the modified file on disk and showed the changes.&#013;&#013; The real problem occurs if &quot;Release&quot; actually finds something to release but you don't spot that some resources are missing.&#013; This is extremely error prone: one of my changes didn't made it into build 110 because of this!&#013;&#013;NOTES:&#013;EG (5/23/01 3:00:33 PM)&#013; Release should do a refresh from local before doing the release.&#013; Moving to VCM&#013;&#013;&#013;KM (05/27/01 5:10:19 PM)&#013; Comments from JM in related email:&#013;&#013; Should not do this for free. Could have a setting which made it optoinal but should nt be mandatory. Default setting could be to have it on.&#013; Consider the SWT team who keep their workspaces on network drives. This will be slow. &#013;&#013; Side effects will be that a build runs when the refresh is completed unless you somehow do it in a workspace runnable and don't end the&#013; runnable until after the release. This would be less than optimal as some builders may be responsible for maintaining some invariants and deriving resources which are releasable. If you don't run the builders before releasing, the invariants will not be maintained and you will release inconsistent state.&#013;&#013; Summary: Offer to &quot;ensure local consistency&quot; before releasing.&#013;&#013;KM (5/31/01 1:30:35 PM)&#013; See also 1GEAG1A: ITPVCM:WINNT - Internal error comparing with a document&#013; which failed with an error. Never got log from Tod though.</PRE>
-<BR><BR><I>------- Additional Comments From <A HREF="mailto:James_Moody@oti.com">James Moody</A> 2001-10-19 06:32 -------</I><BR>
-<PRE>*** <strike><a href="show_bug.cgi?id=183" title="RESOLVED DUPLICATE - readme: must refresh from local if using external editors (1GFBQNI)">Bug 183</a></strike> has been marked as a duplicate of this bug. ***</PRE>
-<BR><BR><I>------- Additional Comments From <A HREF="mailto:James_Moody@oti.com">James Moody</A> 2001-10-19 12:36 -------</I><BR>
-<PRE>Implemented 'auto refresh' option. Default value is off.</PRE>
-<BR><BR><I>------- Additional Comments From <A HREF="mailto:DJ_Houghton@oti.com">DJ Houghton</A> 2001-10-23 19:39 -------</I><BR>
-<PRE>PRODUCT VERSION:&#013; 109&#013;&#013;</PRE>
-<BR><BR><I>------- Additional Comments From <A HREF="mailto:James_Moody@oti.com">James Moody</A> 2001-10-25 06:19 -------</I><BR>
-<PRE>Fixed in v206</PRE>
-
-<HR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<A HREF=query.cgi>Query page</A>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<A HREF=enter_bug.cgi>Enter new bug</A>
-<hr>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a HREF=query.cgi>Query page</a>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a HREF=enter_bug.cgi>Enter new bug</a>
-<table BORDER="0"><tr><td BGCOLOR="#000000" VALIGN="TOP">
-<table BORDER="0" CELLPADDING="10" CELLSPACING="0" WIDTH="100%"
-BGCOLOR="lightyellow">
-<tr><td>
-<form METHOD=GET ACTION="show_bug.cgi">
-<table width="100%"><tr><td>
-Actions:
-</td><td VALIGN="middle" NOWRAP>
-<a href='enter_bug.cgi'>New</a> | <a href='query.cgi'>Query</a> |
- <input TYPE=SUBMIT VALUE="Find"> bug # <input NAME=id SIZE=6> | <a
-href='reports.cgi'>Reports</a></td><td>&nbsp;</td><td valign=middle align=right>
-
- <a href="createaccount.cgi"><nobr>New account</nobr></a>
- | <nobr><a href=query.cgi?GoAheadAndLogIn=1>Log in</a></nobr></td></tr></form>
-</table><br>
-<a HREF="index.html">Eclipse Bugs Home</a>
-</td></tr>
diff --git a/org.eclipse.mylyn.bugzilla.tests/TestPages/platform-page.html b/org.eclipse.mylyn.bugzilla.tests/TestPages/platform-page.html
deleted file mode 100644
index d41b5c84d..000000000
--- a/org.eclipse.mylyn.bugzilla.tests/TestPages/platform-page.html
+++ /dev/null
@@ -1,299 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"><html><head><!-- 1.0@bugzilla.org --><!-- 1.0@bugzilla.org --><title>Enter Bug</title></head>
-
-
-
-
-
-
-
-
- <body bgcolor="#ffffff" onload="" text="#000000" link="#0000ee" vlink="#551a8b" alink="#ff0000">
-
-
-<!-- 1.0@bugzilla.org -->
-
-
-
-
-
-<table border="0" cellspacing="0" cellpadding="0" width="100%"><tbody><tr><td width="100%"><table border="0" cellspacing="0" cellpadding="0" width="100%" bgcolor="#006699"><tbody><tr><td bgcolor="#000000" width="116"><img src="main_data/EclipseBannerPic.jpg" width="115" height="50"></td><td width="637"><a href="http://www.eclipse.org/"><img src="main_data/gradient.jpg" border="0" height="50" width="282"></a></td><td width="250"><img src="main_data/eproject-simple.gif" width="250" height="48"></td></tr></tbody></table></td></tr></tbody></table>
-
- <table border="0" cellspacing="0">
- <tbody><tr>
- <td valign="top" align="left">
- <table border="0" cellpadding="0" cellspacing="2">
- <tbody><tr>
- <td valign="top" align="left" nowrap="nowrap">
- <font size="+1"><b>Enter Bug</b></font>
- </td>
- </tr>
- </tbody></table>
- </td>
- <td valign="middle">&nbsp;</td>
- <td valign="middle" align="left">This page lets you enter a new bug into Bugzilla.</td>
- </tr>
- </tbody></table>
-
-<form method="post" action="post_bug.cgi">
-<input type="hidden" name="product" value="Platform">
-
-<input type="hidden" name="priority" value="P3">
-<input type="hidden" name="bug_status" value="NEW">
-
- <table cellspacing="2" cellpadding="0" border="0">
-
- <tbody><tr>
- <td><br></td>
- </tr>
-
- <tr>
- <td></td>
- <td colspan="3">
- <!-- 1.0@bugzilla.org -->
-
-
-
-
-
-
-Before reporting a bug, please read the <a href="https://bugs.eclipse.org/bugs/bugwritinghelp.html">
-bug writing guidelines</a>, please look at the list of
-<a href="https://bugs.eclipse.org/bugs/duplicates.cgi">most frequently reported bugs</a>, and please
-<a href="https://bugs.eclipse.org/bugs/query.cgi">search</a> for the bug.
- </td>
- </tr>
-
- <tr>
- <td><br></td>
- </tr>
-
- <tr>
- <td align="right" valign="top"><strong>Reporter:</strong></td>
- <td valign="top">tanya@cs.ubc.ca</td>
-
- <td align="right" valign="top"><strong>Product:</strong></td>
- <td valign="top">Platform</td>
- </tr>
-
-
- <tr>
- <td align="right" valign="top">
- <strong>Version:</strong>
- </td>
- <td>
- <select name="version" size="5"><option value="1.0">1.0 </option><option value="2.0">2.0 </option><option value="2.0.1">2.0.1 </option><option value="2.0.2">2.0.2 </option><option value="2.1">2.1 </option><option value="2.1.1">2.1.1 </option><option value="2.1.2">2.1.2 </option><option value="3.0" selected="selected">3.0 </option></select>
- </td>
-
- <td align="right" valign="top">
- <strong>
- <a href="https://bugs.eclipse.org/bugs/describecomponents.cgi?product=Platform">
- Component</a>:
- </strong>
- </td>
- <td>
- <select name="component" size="5"><option value="Ant">Ant </option><option value="Compare">Compare </option><option value="Core">Core </option><option value="CVS">CVS </option><option value="Debug">Debug </option><option value="Doc">Doc </option><option value="Help">Help </option><option value="Releng">Releng </option><option value="Scripting">Scripting </option><option value="Search">Search </option><option value="SWT">SWT </option><option value="Team">Team </option><option value="Text">Text </option><option value="UI">UI </option><option value="Update">Update </option><option value="WebDAV">WebDAV </option></select>
- </td>
- </tr>
-
- <tr>
- <td>&nbsp;</td>
- <td colspan="3"></td>
- </tr>
-
- <tr><td align="right">
- <strong>
- <a href="https://bugs.eclipse.org/bugs/bug_status.html#rep_platform">Platform</a>:
- </strong>
- </td>
-
- <td>
- <select name="rep_platform"><option value="All">All </option><option value="Macintosh">Macintosh </option><option value="PC" selected="selected">PC </option><option value="Power PC">Power PC </option><option value="Sun">Sun </option><option value="Other">Other </option></select>
- </td>
- <td align="right">
- <strong>
- <a href="https://bugs.eclipse.org/bugs/bug_status.html#op_sys">OS</a>:
- </strong>
- </td>
-
- <td>
- <select name="op_sys"><option value="All">All </option><option value="AIX Motif">AIX Motif </option><option value="Windows 95">Windows 95 </option><option value="Windows 98">Windows 98 </option><option value="Windows CE">Windows CE </option><option value="Windows ME">Windows ME </option><option value="Windows 2000">Windows 2000 </option><option value="Windows NT">Windows NT </option><option value="Windows XP" selected="selected">Windows XP </option><option value="Windows All">Windows All </option><option value="MacOS X">MacOS X </option><option value="Linux">Linux </option><option value="Linux-GTK">Linux-GTK </option><option value="Linux-Motif">Linux-Motif </option><option value="HP-UX">HP-UX </option><option value="Neutrino">Neutrino </option><option value="QNX-Photon">QNX-Photon </option><option value="Solaris">Solaris </option><option value="Unix All">Unix All </option><option value="other">other </option></select>
- </td>
- </tr>
-
- <tr>
- <td align="right">
- <strong>
- <a href="https://bugs.eclipse.org/bugs/bug_status.html#bug_severity">Severity</a>:
- </strong>
- </td>
-
- <td>
- <select name="bug_severity"><option value="blocker">blocker </option><option value="critical">critical </option><option value="major">major </option><option value="normal" selected="selected">normal </option><option value="minor">minor </option><option value="trivial">trivial </option><option value="enhancement">enhancement </option></select>
- </td>
- </tr>
-
- <tr>
- <td>&nbsp;</td>
- <td colspan="3"></td>
- </tr>
-
- <tr>
- <td align="right">
- <strong>
- <a href="https://bugs.eclipse.org/bugs/bug_status.html#assigned_to">Assigned To</a>:
- </strong>
- </td>
- <td colspan="3">
- <input name="assigned_to" size="32" value="">
- (Leave blank to assign to default component owner)
- </td>
- </tr>
-
- <tr>
- <td align="right"><strong>Cc:</strong></td>
- <td colspan="3">
- <input name="cc" size="45" value="">
- </td>
- </tr>
-
- <tr>
- <td>&nbsp;</td>
- <td colspan="3"></td>
- </tr>
-
- <tr>
- <td colspan="3">
- <input type="hidden" input="" name="bug_file_loc" size="60" value="">
- </td>
- </tr>
-
- <tr>
- <td align="right"><strong>Summary:</strong></td>
- <td colspan="3">
- <input name="short_desc" size="60" value="">
- </td>
- </tr>
-
- <tr><td align="right" valign="top"><strong>Description:</strong></td>
- <td colspan="3">
- <textarea wrap="hard" name="comment" rows="10" cols="80"></textarea>
- <br>
- </td>
- </tr>
-
- <tr>
- <td></td>
- <td colspan="3">
- </td>
- </tr>
-
- <tr>
- <td></td>
- <td colspan="3">
- <input type="submit" value=" Commit " onclick="if (this.form.short_desc.value == '')
- { alert('Please enter a summary sentence for this bug.');
- return false; } return true;">
- &nbsp;&nbsp;&nbsp;&nbsp;
- <input type="submit" name="maketemplate" value="Remember values as bookmarkable template">
- </td>
- </tr>
-
- <tr>
- <td></td>
- <td colspan="3">
- <br>
- We've made a guess at your operating system and platform.
- Please check them and, if we got it wrong, email webmaster@eclipse.org.
- </td>
- </tr>
-
- </tbody></table>
- <input type="hidden" name="form_name" value="enter_bug">
-</form>
-<!-- 1.0@bugzilla.org -->
-
-
-
-
-
-
-<table border="0">
- <tbody><tr>
- <td bgcolor="#000000" valign="top">
- <table border="0" cellpadding="10" cellspacing="0" width="100%" bgcolor="lightyellow">
- <tbody><tr>
- <td>
-
-
-
- This is <b>Bugzilla</b>: the Mozilla bug system. For more
- information about what Bugzilla is and what it can do, see
- <a href="http://www.bugzilla.org/">bugzilla.org</a>.
-
-
-
- <br>
-
-
-<!-- 1.0@bugzilla.org -->
-
-
-
-
-
-
-<form method="get" action="show_bug.cgi">
- <table width="100%">
- <tbody><tr>
- <td>
- Actions:
- </td>
-
- <td valign="middle" nowrap="nowrap">
- <a href="https://bugs.eclipse.org/bugs/enter_bug.cgi">New</a> |
- <a href="https://bugs.eclipse.org/bugs/query.cgi">Query</a> |
-
- <input type="submit" value="Find"> bug #
- <input name="id" size="6"> |
-
- <a href="https://bugs.eclipse.org/bugs/reports.cgi">Reports</a>
-
- | <a href="https://bugs.eclipse.org/bugs/votes.cgi?action=show_user">My Votes</a>
- </td>
-
- <td>&nbsp;</td>
-
-
- <td valign="middle">
- Edit <a href="https://bugs.eclipse.org/bugs/userprefs.cgi">prefs</a>
-
- | <a href="https://bugs.eclipse.org/bugs/relogin.cgi">Log&nbsp;out</a>&nbsp;tanya@cs.ubc.ca
- </td>
- </tr>
-
-
-
-
- <tr>
- <td>
- Preset&nbsp;Queries:
- </td>
-
- <td colspan="3">
- <a href="https://bugs.eclipse.org/bugs/buglist.cgi?bug_status=NEW&amp;bug_status=ASSIGNED&amp;bug_status=REOPENED&amp;email1=tanya%40cs.ubc.ca&amp;emailtype1=exact&amp;emailassigned_to1=1&amp;emailreporter1=1">My&nbsp;Bugs</a>
-
- </td>
- </tr>
-
-
- </tbody></table>
-</form>
-
- </td>
- </tr>
- </tbody></table>
- </td>
- </tr>
-</tbody></table>
-
-</body></html> \ No newline at end of file
diff --git a/org.eclipse.mylyn.bugzilla.tests/TestPages/product-page-1-product-hipikat.html b/org.eclipse.mylyn.bugzilla.tests/TestPages/product-page-1-product-hipikat.html
deleted file mode 100644
index 53805b2d2..000000000
--- a/org.eclipse.mylyn.bugzilla.tests/TestPages/product-page-1-product-hipikat.html
+++ /dev/null
@@ -1,256 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
-<!-- saved from url=(0073)http://hipikat.cs.ubc.ca:8081/bugzilla-test/bugzilla-2.17.6/enter_bug.cgi -->
-<!-- 1.0@bugzilla.org --><!-- 1.0@bugzilla.org --><HTML><HEAD><TITLE>Enter Bug</TITLE>
-<META http-equiv=Content-Type content="text/html; charset=windows-1252"><!-- 1.0@bugzilla.org --><!-- 1.0@bugzilla.org -->
-<SCRIPT
-type=text/javascript>
- <!--
-
- function initHelp() {}
- // -->
- </SCRIPT>
-
-<META content="MSHTML 6.00.2800.1400" name=GENERATOR></HEAD>
-<BODY bgColor=#ffffff onload=set_assign_to();><!-- 1.0@bugzilla.org -->
-<TABLE cellSpacing=0 cellPadding=0 width="100%" bgColor=#000000 border=0>
- <TBODY>
- <TR>
- <TD>
- <CENTER><FONT color=#ffffff size=8>This is Bugzilla
- </FONT></CENTER></TD></TR></TBODY></TABLE>
-<CENTER><FONT size=-1><A href="http://www.bugzilla.org/">Bugzilla</A> Version
-2.17.6 </FONT></CENTER>
-<TABLE cellSpacing=0 width="100%" border=0>
- <TBODY>
- <TR>
- <TD vAlign=top align=left>
- <TABLE cellSpacing=2 cellPadding=0 border=0>
- <TBODY>
- <TR>
- <TD vAlign=top noWrap align=left><FONT size=+1><B>Enter
- Bug</B></FONT> </TD></TR></TBODY></TABLE></TD>
- <TD vAlign=center align=left>&nbsp;</TD>
- <TD vAlign=center align=left>This page lets you enter a new bug into
- Bugzilla.</TD></TR></TBODY></TABLE>
-<SCRIPT language=JavaScript type=text/javascript>
-<!--
-
-var default_owners = new Array(1);
-var components = new Array(1);
- components[0] = "TestComponent";
- default_owners[0] = "cubranic\x40cs.ubc.ca";
-var last_default_owner;
-function set_assign_to() {
- // Based on the selected component, fill the "Assign To:" field
- // with the default component owner.
- var form = document.Create;
- assigned_to = form.assigned_to.value
- var index = -1;
- if (form.component.type == 'select-one') {
- index = form.component.selectedIndex;
- } else if (form.component.type == 'hidden') {
- // Assume there is only one component in the list
- index = 0;
- }
- if (index != -1) {
- var owner = default_owners[index];
- var component = components[index];
- if (assigned_to == last_default_owner
- || assigned_to == owner
- || assigned_to == ''
- || confirm('Would you like to change\n\n' +
- ' "Assign To: ' + assigned_to + '"\n\n' +
- 'to the default "' + component + '" owner:\n\n' +
- ' ' + owner + "?")) {
- form.assigned_to.value = owner;
- last_default_owner = owner;
- }
- }
-}
--->
-</SCRIPT>
-
-<FORM id=Create name=Create action=post_bug.cgi method=post><INPUT type=hidden
-value=TestProduct name=product>
-<TABLE cellSpacing=2 cellPadding=0 border=0>
- <TBODY>
- <TR>
- <TD><BR></TD></TR>
- <TR>
- <TD></TD>
- <TD colSpan=3><!-- 1.0@bugzilla.org -->Before reporting a bug, please read
- the <A
- href="http://hipikat.cs.ubc.ca:8081/bugzilla-test/bugzilla-2.17.6/bugwritinghelp.html">bug
- writing guidelines</A>, please look at the list of <A
- href="http://hipikat.cs.ubc.ca:8081/bugzilla-test/bugzilla-2.17.6/duplicates.cgi">most
- frequently reported bugs</A>, and please <A
- href="http://hipikat.cs.ubc.ca:8081/bugzilla-test/bugzilla-2.17.6/query.cgi">search</A>
- for the bug. </TD></TR>
- <TR>
- <TD><BR></TD></TR>
- <TR>
- <TD vAlign=top align=right><STRONG>Reporter:</STRONG></TD>
- <TD vAlign=top>tanya@cs.ubc.ca</TD>
- <TD vAlign=top align=right><STRONG>Product:</STRONG></TD>
- <TD vAlign=top>TestProduct</TD></TR>
- <TR>
- <TD vAlign=top align=right><STRONG>Version:</STRONG> </TD>
- <TD><SELECT size=5 name=version> <OPTION value=other
- selected>other</OPTION></SELECT> </TD>
- <TD vAlign=top align=right><STRONG><A
- href="http://hipikat.cs.ubc.ca:8081/bugzilla-test/bugzilla-2.17.6/describecomponents.cgi?product=TestProduct">Component</A>:
- </STRONG></TD>
- <TD><SELECT onchange=set_assign_to(); size=5 name=component> <OPTION
- value=TestComponent selected>TestComponent</OPTION></SELECT> </TD></TR>
- <TR>
- <TD>&nbsp;</TD>
- <TD colSpan=3></TD></TR>
- <TR>
- <TD align=right><STRONG><A
- href="http://hipikat.cs.ubc.ca:8081/bugzilla-test/bugzilla-2.17.6/bug_status.html#rep_platform">Platform</A>:
- </STRONG></TD>
- <TD><SELECT name=rep_platform> <OPTION value=All>All</OPTION> <OPTION
- value=DEC>DEC</OPTION> <OPTION value=HP>HP</OPTION> <OPTION
- value=Macintosh>Macintosh</OPTION> <OPTION value=PC selected>PC</OPTION>
- <OPTION value=SGI>SGI</OPTION> <OPTION value=Sun>Sun</OPTION> <OPTION
- value=Other>Other</OPTION></SELECT> </TD>
- <TD align=right><STRONG><A
- href="http://hipikat.cs.ubc.ca:8081/bugzilla-test/bugzilla-2.17.6/bug_status.html#op_sys">OS</A>:
- </STRONG></TD>
- <TD><SELECT name=op_sys> <OPTION value=All>All</OPTION> <OPTION
- value="Windows 3.1">Windows 3.1</OPTION> <OPTION
- value="Windows 95">Windows 95</OPTION> <OPTION
- value="Windows 98">Windows 98</OPTION> <OPTION
- value="Windows ME">Windows ME</OPTION> <OPTION
- value="Windows 2000">Windows 2000</OPTION> <OPTION
- value="Windows NT">Windows NT</OPTION> <OPTION value="Windows XP"
- selected>Windows XP</OPTION> <OPTION value="Windows Server 2003">Windows
- Server 2003</OPTION> <OPTION value="Mac System 7">Mac System 7</OPTION>
- <OPTION value="Mac System 7.5">Mac System 7.5</OPTION> <OPTION
- value="Mac System 7.6.1">Mac System 7.6.1</OPTION> <OPTION
- value="Mac System 8.0">Mac System 8.0</OPTION> <OPTION
- value="Mac System 8.5">Mac System 8.5</OPTION> <OPTION
- value="Mac System 8.6">Mac System 8.6</OPTION> <OPTION
- value="Mac System 9.x">Mac System 9.x</OPTION> <OPTION
- value="Mac OS X 10.0">Mac OS X 10.0</OPTION> <OPTION
- value="Mac OS X 10.1">Mac OS X 10.1</OPTION> <OPTION
- value="Mac OS X 10.2">Mac OS X 10.2</OPTION> <OPTION
- value=Linux>Linux</OPTION> <OPTION value=BSD/OS>BSD/OS</OPTION> <OPTION
- value=FreeBSD>FreeBSD</OPTION> <OPTION value=NetBSD>NetBSD</OPTION>
- <OPTION value=OpenBSD>OpenBSD</OPTION> <OPTION value=AIX>AIX</OPTION>
- <OPTION value=BeOS>BeOS</OPTION> <OPTION value=HP-UX>HP-UX</OPTION>
- <OPTION value=IRIX>IRIX</OPTION> <OPTION
- value=Neutrino>Neutrino</OPTION> <OPTION value=OpenVMS>OpenVMS</OPTION>
- <OPTION value=OS/2>OS/2</OPTION> <OPTION value=OSF/1>OSF/1</OPTION>
- <OPTION value=Solaris>Solaris</OPTION> <OPTION
- value=SunOS>SunOS</OPTION> <OPTION value=other>other</OPTION></SELECT>
- </TD></TR>
- <TR>
- <TD align=right><STRONG><A
- href="http://hipikat.cs.ubc.ca:8081/bugzilla-test/bugzilla-2.17.6/bug_status.html#priority">Priority</A>:
- </STRONG></TD>
- <TD><SELECT name=priority> <OPTION value=P1>P1</OPTION> <OPTION value=P2
- selected>P2</OPTION> <OPTION value=P3>P3</OPTION> <OPTION
- value=P4>P4</OPTION> <OPTION value=P5>P5</OPTION></SELECT> </TD>
- <TD align=right><STRONG><A
- href="http://hipikat.cs.ubc.ca:8081/bugzilla-test/bugzilla-2.17.6/bug_status.html#bug_severity">Severity</A>:
- </STRONG></TD>
- <TD><SELECT name=bug_severity> <OPTION value=blocker>blocker</OPTION>
- <OPTION value=critical>critical</OPTION> <OPTION
- value=major>major</OPTION> <OPTION value=normal selected>normal</OPTION>
- <OPTION value=minor>minor</OPTION> <OPTION
- value=trivial>trivial</OPTION> <OPTION
- value=enhancement>enhancement</OPTION></SELECT> </TD></TR>
- <TR>
- <TD>&nbsp;</TD>
- <TD colSpan=3></TD></TR><INPUT type=hidden value=NEW name=bug_status>
- <TR>
- <TD align=right><STRONG><A
- href="http://hipikat.cs.ubc.ca:8081/bugzilla-test/bugzilla-2.17.6/bug_status.html#assigned_to">Assign
- To</A>: </STRONG></TD>
- <TD colSpan=3><INPUT size=32 name=assigned_to> <NOSCRIPT>(Leave blank to
- assign to default component owner)</NOSCRIPT> </TD></TR>
- <TR>
- <TD align=right><STRONG>Cc:</STRONG></TD>
- <TD colSpan=3><INPUT size=45 name=cc> </TD></TR>
- <TR>
- <TD>&nbsp;</TD>
- <TD colSpan=3></TD></TR>
- <TR>
- <TD align=right><STRONG>URL:</STRONG></TD>
- <TD colSpan=3><INPUT size=60 value=http:// name=bug_file_loc> </TD></TR>
- <TR>
- <TD align=right><STRONG>Summary:</STRONG></TD>
- <TD colSpan=3><INPUT size=60 name=short_desc> </TD></TR>
- <TR>
- <TD vAlign=top align=right><STRONG>Description:</STRONG></TD>
- <TD colSpan=3><TEXTAREA name=comment rows=10 wrap=hard cols=80></TEXTAREA>
- <BR></TD></TR>
- <TR>
- <TD vAlign=top align=right><STRONG><A
- href="http://hipikat.cs.ubc.ca:8081/bugzilla-test/bugzilla-2.17.6/describekeywords.cgi">Keywords</A>:
- </STRONG></TD>
- <TD colSpan=3><INPUT size=60 name=keywords> (optional) </TD></TR>
- <TR>
- <TD align=right><STRONG>Depends on:</STRONG> </TD>
- <TD><INPUT accessKey=d name=dependson> </TD></TR>
- <TR>
- <TD align=right><STRONG>Blocks:</STRONG> </TD>
- <TD><INPUT accessKey=b name=blocked> </TD></TR>
- <TR>
- <TD></TD>
- <TD colSpan=3></TD></TR>
- <TR>
- <TD></TD>
- <TD colSpan=3><INPUT onclick="if (this.form.short_desc.value == '')&#10; { alert('Please enter a summary sentence for this bug.');&#10; return false; } return true;" type=submit value=" Commit ">
- &nbsp;&nbsp;&nbsp;&nbsp; <INPUT type=submit value="Remember values as bookmarkable template" name=maketemplate>
- </TD></TR>
- <TR>
- <TD></TD>
- <TD colSpan=3><BR>We've made a guess at your operating system and
- platform. Please check them and, if we got it wrong, emailTHE MAINTAINER
- HAS NOT YET BEEN SET. </TD></TR></TBODY></TABLE><INPUT type=hidden
-value=enter_bug name=form_name> </FORM><!-- 1.0@bugzilla.org --><!-- 1.0@bugzilla.org -->
-<TABLE border=0>
- <TBODY>
- <TR>
- <TD vAlign=top bgColor=#000000>
- <TABLE cellSpacing=0 cellPadding=10 width="100%" bgColor=lightyellow
- border=0>
- <TBODY>
- <TR>
- <TD><!-- 1.0@bugzilla.org -->
- <FORM action=show_bug.cgi method=get>
- <TABLE width="100%">
- <TBODY>
- <TR>
- <TD>Actions: </TD>
- <TD vAlign=center noWrap><A
- href="http://hipikat.cs.ubc.ca:8081/bugzilla-test/bugzilla-2.17.6/enter_bug.cgi">New</A>
- | <A
- href="http://hipikat.cs.ubc.ca:8081/bugzilla-test/bugzilla-2.17.6/query.cgi">Search</A>
- | <INPUT type=submit value=Find> bug # <INPUT size=6 name=id>
- | <A
- href="http://hipikat.cs.ubc.ca:8081/bugzilla-test/bugzilla-2.17.6/report.cgi">Reports</A>
- | <A
- href="http://hipikat.cs.ubc.ca:8081/bugzilla-test/bugzilla-2.17.6/request.cgi?requester=tanya%40cs.ubc.ca&amp;requestee=tanya%40cs.ubc.ca&amp;do_union=1&amp;group=type">My
- Requests</A> | <A
- href="http://hipikat.cs.ubc.ca:8081/bugzilla-test/bugzilla-2.17.6/votes.cgi?action=show_user">My
- Votes</A> </TD>
- <TD>&nbsp;</TD>
- <TD vAlign=center>Edit <A
- href="http://hipikat.cs.ubc.ca:8081/bugzilla-test/bugzilla-2.17.6/userprefs.cgi">prefs</A>,
- <A
- href="http://hipikat.cs.ubc.ca:8081/bugzilla-test/bugzilla-2.17.6/editproducts.cgi">products</A>,
- <A
- href="http://hipikat.cs.ubc.ca:8081/bugzilla-test/bugzilla-2.17.6/editflagtypes.cgi">flags</A>,
- <A
- href="http://hipikat.cs.ubc.ca:8081/bugzilla-test/bugzilla-2.17.6/editkeywords.cgi">keywords</A>
- | <A
- href="http://hipikat.cs.ubc.ca:8081/bugzilla-test/bugzilla-2.17.6/relogin.cgi">Log&nbsp;out</A>&nbsp;tanya@cs.ubc.ca
- </TD></TR>
- <TR>
- <TD>Saved&nbsp;Searches: </TD>
- <TD colSpan=3><A
- href="http://hipikat.cs.ubc.ca:8081/bugzilla-test/bugzilla-2.17.6/buglist.cgi?bug_status=NEW&amp;bug_status=ASSIGNED&amp;bug_status=REOPENED&amp;email1=tanya%40cs.ubc.ca&amp;emailtype1=exact&amp;emailassigned_to1=1&amp;emailreporter1=1">My&nbsp;Bugs</A>
- </TD></TR></TBODY></TABLE></FORM></TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE></BODY></HTML>
diff --git a/org.eclipse.mylyn.bugzilla.tests/TestPages/product-page.html b/org.eclipse.mylyn.bugzilla.tests/TestPages/product-page.html
deleted file mode 100644
index f45028d4b..000000000
--- a/org.eclipse.mylyn.bugzilla.tests/TestPages/product-page.html
+++ /dev/null
@@ -1,237 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"><html><head><!-- 1.0@bugzilla.org --><!-- 1.0@bugzilla.org --><title>Enter Bug</title></head>
-
-
-
-
-
-
-
-
-
-
- <body bgcolor="#ffffff" onload="" text="#000000" link="#0000ee" vlink="#551a8b" alink="#ff0000">
-
-
-<!-- 1.0@bugzilla.org -->
-
-
-
-
-
-<table border="0" cellspacing="0" cellpadding="0" width="100%"><tbody><tr><td width="100%"><table border="0" cellspacing="0" cellpadding="0" width="100%" bgcolor="#006699"><tbody><tr><td bgcolor="#000000" width="116"><img src="main_data/EclipseBannerPic.jpg" width="115" height="50"></td><td width="637"><a href="http://www.eclipse.org/"><img src="main_data/gradient.jpg" border="0" height="50" width="282"></a></td><td width="250"><img src="main_data/eproject-simple.gif" width="250" height="48"></td></tr></tbody></table></td></tr></tbody></table>
-
- <table border="0" cellspacing="0">
- <tbody><tr>
- <td valign="top" align="left">
- <table border="0" cellpadding="0" cellspacing="2">
- <tbody><tr>
- <td valign="top" align="left" nowrap="nowrap">
- <font size="+1"><b>Enter Bug</b></font>
- </td>
- </tr>
- </tbody></table>
- </td>
- <td valign="middle">&nbsp;</td>
- <td valign="middle" align="left">First, you must pick a product on which to enter a bug.</td>
- </tr>
- </tbody></table>
-
-<table>
-
- <tbody><tr>
- <th align="right" valign="top">
- <a href="https://bugs.eclipse.org/bugs/enter_bug.cgi?product=AJDT">AJDT</a>:
- </th>
-
- <td valign="top">&nbsp;AJDT Development Tools</td>
- </tr>
- <tr>
- <th align="right" valign="top">
- <a href="https://bugs.eclipse.org/bugs/enter_bug.cgi?product=AspectJ">AspectJ</a>:
- </th>
-
- <td valign="top">&nbsp;AspectJ Development Tools</td>
- </tr>
- <tr>
- <th align="right" valign="top">
- <a href="https://bugs.eclipse.org/bugs/enter_bug.cgi?product=CDT">CDT</a>:
- </th>
-
- <td valign="top">&nbsp;C/C++ Development Toolkit</td>
- </tr>
- <tr>
- <th align="right" valign="top">
- <a href="https://bugs.eclipse.org/bugs/enter_bug.cgi?product=CME">CME</a>:
- </th>
-
- <td valign="top">&nbsp;CME Technology</td>
- </tr>
- <tr>
- <th align="right" valign="top">
- <a href="https://bugs.eclipse.org/bugs/enter_bug.cgi?product=ECESIS">ECESIS</a>:
- </th>
-
- <td valign="top">&nbsp;Eclipse Techology Open Courseware Project</td>
- </tr>
- <tr>
- <th align="right" valign="top">
- <a href="https://bugs.eclipse.org/bugs/enter_bug.cgi?product=EMF">EMF</a>:
- </th>
-
- <td valign="top">&nbsp;Eclipse Modelling Framework</td>
- </tr>
- <tr>
- <th align="right" valign="top">
- <a href="https://bugs.eclipse.org/bugs/enter_bug.cgi?product=Equinox">Equinox</a>:
- </th>
-
- <td valign="top">&nbsp;Eclipse Runtime Exploration</td>
- </tr>
- <tr>
- <th align="right" valign="top">
- <a href="https://bugs.eclipse.org/bugs/enter_bug.cgi?product=GEF">GEF</a>:
- </th>
-
- <td valign="top">&nbsp;Graphical Editing Framework</td>
- </tr>
- <tr>
- <th align="right" valign="top">
- <a href="https://bugs.eclipse.org/bugs/enter_bug.cgi?product=GMT">GMT</a>:
- </th>
-
- <td valign="top">&nbsp;Generative Model Generator</td>
- </tr>
- <tr>
- <th align="right" valign="top">
- <a href="https://bugs.eclipse.org/bugs/enter_bug.cgi?product=Hyades">Hyades</a>:
- </th>
-
- <td valign="top">&nbsp;Automated Software Quality Tools</td>
- </tr>
- <tr>
- <th align="right" valign="top">
- <a href="https://bugs.eclipse.org/bugs/enter_bug.cgi?product=JDT">JDT</a>:
- </th>
-
- <td valign="top">&nbsp;Java Development Toolkit</td>
- </tr>
- <tr>
- <th align="right" valign="top">
- <a href="https://bugs.eclipse.org/bugs/enter_bug.cgi?product=PDE">PDE</a>:
- </th>
-
- <td valign="top">&nbsp;Plugin Development Environment</td>
- </tr>
- <tr>
- <th align="right" valign="top">
- <a href="https://bugs.eclipse.org/bugs/enter_bug.cgi?product=Platform">Platform</a>:
- </th>
-
- <td valign="top">&nbsp;Eclipse Platform</td>
- </tr>
- <tr>
- <th align="right" valign="top">
- <a href="https://bugs.eclipse.org/bugs/enter_bug.cgi?product=Stellation">Stellation</a>:
- </th>
-
- <td valign="top">&nbsp;Stellation Project</td>
- </tr>
- <tr>
- <th align="right" valign="top">
- <a href="https://bugs.eclipse.org/bugs/enter_bug.cgi?product=UML2">UML2</a>:
- </th>
-
- <td valign="top">&nbsp;UML2 Tools</td>
- </tr>
- <tr>
- <th align="right" valign="top">
- <a href="https://bugs.eclipse.org/bugs/enter_bug.cgi?product=VE">VE</a>:
- </th>
-
- <td valign="top">&nbsp;Visual Editor Tools</td>
- </tr>
- <tr>
- <th align="right" valign="top">
- <a href="https://bugs.eclipse.org/bugs/enter_bug.cgi?product=WSVT">WSVT</a>:
- </th>
-
- <td valign="top">&nbsp;Web Service Validation Tools</td>
- </tr>
- <tr>
- <th align="right" valign="top">
- <a href="https://bugs.eclipse.org/bugs/enter_bug.cgi?product=XSD">XSD</a>:
- </th>
-
- <td valign="top">&nbsp;XML Schema Infoset Model</td>
- </tr>
-
-</tbody></table>
-<!-- 1.0@bugzilla.org -->
-
-
-
-
-
-
-<table border="0">
- <tbody><tr>
- <td bgcolor="#000000" valign="top">
- <table border="0" cellpadding="10" cellspacing="0" width="100%" bgcolor="lightyellow">
- <tbody><tr>
- <td>
-
-
-
- This is <b>Bugzilla</b>: the Mozilla bug system. For more
- information about what Bugzilla is and what it can do, see
- <a href="http://www.bugzilla.org/">bugzilla.org</a>.
-
-
-
- <br>
-
-
-<!-- 1.0@bugzilla.org -->
-
-
-
-
-
-
-<form method="get" action="show_bug.cgi">
- <table width="100%">
- <tbody><tr>
- <td>
- Actions:
- </td>
-
- <td valign="middle" nowrap="nowrap">
- <a href="https://bugs.eclipse.org/bugs/enter_bug.cgi">New</a> |
- <a href="https://bugs.eclipse.org/bugs/query.cgi">Query</a> |
-
- <input type="submit" value="Find"> bug #
- <input name="id" size="6"> |
-
- <a href="https://bugs.eclipse.org/bugs/reports.cgi">Reports</a>
-
- </td>
-
- <td>&nbsp;</td>
-
- <td valign="middle" align="right">
- <a href="https://bugs.eclipse.org/bugs/createaccount.cgi">New&nbsp;Account</a> |
- <a href="https://bugs.eclipse.org/bugs/query.cgi?GoAheadAndLogIn=1">Log&nbsp;In</a>
- </td>
- </tr>
-
- </tbody></table>
-</form>
-
- </td>
- </tr>
- </tbody></table>
- </td>
- </tr>
-</tbody></table>
-
-</body></html> \ No newline at end of file
diff --git a/org.eclipse.mylyn.bugzilla.tests/TestPages/ve-page.html b/org.eclipse.mylyn.bugzilla.tests/TestPages/ve-page.html
deleted file mode 100644
index e5423da71..000000000
--- a/org.eclipse.mylyn.bugzilla.tests/TestPages/ve-page.html
+++ /dev/null
@@ -1,178 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
-<!-- saved from url=(0054)https://bugs.eclipse.org/bugs/enter_bug.cgi?product=VE -->
-<!-- 1.0@bugzilla.org --><!-- 1.0@bugzilla.org --><HTML><HEAD><TITLE>Enter Bug</TITLE>
-<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
-<META content="MSHTML 6.00.2800.1400" name=GENERATOR></HEAD>
-<BODY text=#000000 vLink=#551a8b aLink=#ff0000 link=#0000ee bgColor=#ffffff
-onload=""><!-- 1.0@bugzilla.org -->
-<TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
- <TBODY>
- <TR>
- <TD width="100%">
- <TABLE cellSpacing=0 cellPadding=0 width="100%" bgColor=#006699
- border=0><TBODY>
- <TR>
- <TD width=116 bgColor=#000000><IMG height=50
- src="VE_files/EclipseBannerPic.jpg" width=115></TD>
- <TD width=637><A href="http://www.eclipse.org/"><IMG height=50
- src="VE_files/gradient.jpg" width=282 border=0></A></TD>
- <TD width=250><IMG height=48 src="VE_files/eproject-simple.gif"
- width=250></TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE>
-<TABLE cellSpacing=0 border=0>
- <TBODY>
- <TR>
- <TD vAlign=top align=left>
- <TABLE cellSpacing=2 cellPadding=0 border=0>
- <TBODY>
- <TR>
- <TD vAlign=top noWrap align=left><FONT size=+1><B>Enter
- Bug</B></FONT> </TD></TR></TBODY></TABLE></TD>
- <TD vAlign=center>&nbsp;</TD>
- <TD vAlign=center align=left>This page lets you enter a new bug into
- Bugzilla.</TD></TR></TBODY></TABLE>
-<FORM action=post_bug.cgi method=post><INPUT type=hidden value=VE name=product>
-<TABLE cellSpacing=2 cellPadding=0 border=0>
- <TBODY>
- <TR>
- <TD><BR></TD></TR>
- <TR>
- <TD></TD>
- <TD colSpan=3><!-- 1.0@bugzilla.org -->Before reporting a bug, please read
- the <A href="https://bugs.eclipse.org/bugs/bugwritinghelp.html">bug
- writing guidelines</A>, please look at the list of <A
- href="https://bugs.eclipse.org/bugs/duplicates.cgi">most frequently
- reported bugs</A>, and please <A
- href="https://bugs.eclipse.org/bugs/query.cgi">search</A> for the bug.
- </TD></TR>
- <TR>
- <TD><BR></TD></TR>
- <TR>
- <TD vAlign=top align=right><STRONG>Reporter:</STRONG></TD>
- <TD vAlign=top>tanya@cs.ubc.ca</TD>
- <TD vAlign=top align=right><STRONG>Product:</STRONG></TD>
- <TD vAlign=top>VE</TD></TR>
- <TR>
- <TD vAlign=top align=right><STRONG>Version:</STRONG> </TD>
- <TD><SELECT size=5 name=version> <OPTION value=0.5.0>0.5.0</OPTION>
- <OPTION value=1.0.0>1.0.0</OPTION> <OPTION value=unspecified
- selected>unspecified</OPTION></SELECT> </TD>
- <TD vAlign=top align=right><STRONG><A
- href="https://bugs.eclipse.org/bugs/describecomponents.cgi?product=VE">Component</A>:
- </STRONG></TD>
- <TD><SELECT size=5 name=component> <OPTION value=CDE>CDE</OPTION>
- <OPTION value=Doc>Doc</OPTION> <OPTION value="Java Core">Java
- Core</OPTION> <OPTION value="Java Model (JEM)">Java Model (JEM)</OPTION>
- <OPTION value=JFC/Swing>JFC/Swing</OPTION> <OPTION
- value=SWT>SWT</OPTION></SELECT> </TD></TR>
- <TR>
- <TD>&nbsp;</TD>
- <TD colSpan=3></TD></TR>
- <TR>
- <TD align=right><STRONG><A
- href="https://bugs.eclipse.org/bugs/bug_status.html#rep_platform">Platform</A>:
- </STRONG></TD>
- <TD><SELECT name=rep_platform> <OPTION value=All>All</OPTION> <OPTION
- value=Macintosh>Macintosh</OPTION> <OPTION value=PC selected>PC</OPTION>
- <OPTION value="Power PC">Power PC</OPTION> <OPTION
- value=Sun>Sun</OPTION> <OPTION value=Other>Other</OPTION></SELECT> </TD>
- <TD align=right><STRONG><A
- href="https://bugs.eclipse.org/bugs/bug_status.html#op_sys">OS</A>:
- </STRONG></TD>
- <TD><SELECT name=op_sys> <OPTION value=All>All</OPTION> <OPTION
- value="AIX Motif">AIX Motif</OPTION> <OPTION value="Windows 95">Windows
- 95</OPTION> <OPTION value="Windows 98">Windows 98</OPTION> <OPTION
- value="Windows CE">Windows CE</OPTION> <OPTION
- value="Windows ME">Windows ME</OPTION> <OPTION
- value="Windows 2000">Windows 2000</OPTION> <OPTION
- value="Windows NT">Windows NT</OPTION> <OPTION value="Windows XP"
- selected>Windows XP</OPTION> <OPTION value="Windows All">Windows
- All</OPTION> <OPTION value="MacOS X">MacOS X</OPTION> <OPTION
- value=Linux>Linux</OPTION> <OPTION value=Linux-GTK>Linux-GTK</OPTION>
- <OPTION value=Linux-Motif>Linux-Motif</OPTION> <OPTION
- value=HP-UX>HP-UX</OPTION> <OPTION value=Neutrino>Neutrino</OPTION>
- <OPTION value=QNX-Photon>QNX-Photon</OPTION> <OPTION
- value=Solaris>Solaris</OPTION> <OPTION value="Unix All">Unix
- All</OPTION> <OPTION value=other>other</OPTION></SELECT> </TD></TR>
- <TR><INPUT type=hidden value=P3 name=priority>
- <TD align=right><STRONG><A
- href="https://bugs.eclipse.org/bugs/bug_status.html#bug_severity">Severity</A>:
- </STRONG></TD>
- <TD><SELECT name=bug_severity> <OPTION value=blocker>blocker</OPTION>
- <OPTION value=critical>critical</OPTION> <OPTION
- value=major>major</OPTION> <OPTION value=normal selected>normal</OPTION>
- <OPTION value=minor>minor</OPTION> <OPTION
- value=trivial>trivial</OPTION> <OPTION
- value=enhancement>enhancement</OPTION></SELECT> </TD></TR>
- <TR>
- <TD>&nbsp;</TD>
- <TD colSpan=3></TD></TR><INPUT type=hidden value=NEW name=bug_status>
- <TR>
- <TD align=right><STRONG><A
- href="https://bugs.eclipse.org/bugs/bug_status.html#assigned_to">Assigned
- To</A>: </STRONG></TD>
- <TD colSpan=3><INPUT size=32 name=assigned_to> (Leave blank to assign to
- default component owner) </TD></TR>
- <TR>
- <TD align=right><STRONG>Cc:</STRONG></TD>
- <TD colSpan=3><INPUT size=45 name=cc> </TD></TR>
- <TR>
- <TD>&nbsp;</TD>
- <TD colSpan=3></TD></TR>
- <TR>
- <TD colSpan=3><INPUT type=hidden size=60 name=bug_file_loc input> </TD></TR>
- <TR>
- <TD align=right><STRONG>Summary:</STRONG></TD>
- <TD colSpan=3><INPUT size=60 name=short_desc> </TD></TR>
- <TR>
- <TD vAlign=top align=right><STRONG>Description:</STRONG></TD>
- <TD colSpan=3><TEXTAREA name=comment rows=10 wrap=hard cols=80></TEXTAREA>
- <BR></TD></TR>
- <TR>
- <TD></TD>
- <TD colSpan=3></TD></TR>
- <TR>
- <TD></TD>
- <TD colSpan=3><INPUT onclick="if (this.form.short_desc.value == '') &#10; { alert('Please enter a summary sentence for this bug.'); &#10; return false; } return true;" type=submit value=" Commit ">
- &nbsp;&nbsp;&nbsp;&nbsp; <INPUT type=submit value="Remember values as bookmarkable template" name=maketemplate>
- </TD></TR>
- <TR>
- <TD></TD>
- <TD colSpan=3><BR>We've made a guess at your operating system and
- platform. Please check them and, if we got it wrong, email
- webmaster@eclipse.org. </TD></TR></TBODY></TABLE><INPUT type=hidden
-value=enter_bug name=form_name> </FORM><!-- 1.0@bugzilla.org -->
-<TABLE border=0>
- <TBODY>
- <TR>
- <TD vAlign=top bgColor=#000000>
- <TABLE cellSpacing=0 cellPadding=10 width="100%" bgColor=lightyellow
- border=0>
- <TBODY>
- <TR>
- <TD>This is <B>Bugzilla</B>: the Mozilla bug system. For more
- information about what Bugzilla is and what it can do, see <A
- href="http://www.bugzilla.org/">bugzilla.org</A>. <BR><!-- 1.0@bugzilla.org -->
- <FORM action=show_bug.cgi method=get>
- <TABLE width="100%">
- <TBODY>
- <TR>
- <TD>Actions: </TD>
- <TD vAlign=center noWrap><A
- href="https://bugs.eclipse.org/bugs/enter_bug.cgi">New</A> |
- <A href="https://bugs.eclipse.org/bugs/query.cgi">Query</A> | <INPUT type=submit value=Find> bug # <INPUT size=6 name=id> |
- <A
- href="https://bugs.eclipse.org/bugs/reports.cgi">Reports</A> |
- <A
- href="https://bugs.eclipse.org/bugs/votes.cgi?action=show_user">My
- Votes</A> </TD>
- <TD>&nbsp;</TD>
- <TD vAlign=center>Edit <A
- href="https://bugs.eclipse.org/bugs/userprefs.cgi">prefs</A> |
- <A
- href="https://bugs.eclipse.org/bugs/relogin.cgi">Log&nbsp;out</A>&nbsp;tanya@cs.ubc.ca
- </TD></TR>
- <TR>
- <TD>Preset&nbsp;Queries: </TD>
- <TD colSpan=3><A
- href="https://bugs.eclipse.org/bugs/buglist.cgi?bug_status=NEW&amp;bug_status=ASSIGNED&amp;bug_status=REOPENED&amp;email1=tanya%40cs.ubc.ca&amp;emailtype1=exact&amp;emailassigned_to1=1&amp;emailreporter1=1">My&nbsp;Bugs</A>
- </TD></TR></TBODY></TABLE></FORM></TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE></BODY></HTML>
diff --git a/org.eclipse.mylyn.bugzilla.tests/about.html b/org.eclipse.mylyn.bugzilla.tests/about.html
deleted file mode 100644
index 60ca57b4b..000000000
--- a/org.eclipse.mylyn.bugzilla.tests/about.html
+++ /dev/null
@@ -1,22 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3c.org/TR/1999/REC-html401-19991224/loose.dtd">
-<!-- saved from url=(0043)http://www.eclipse.org/legal/epl/about.html -->
-<HTML><HEAD><TITLE>About</TITLE>
-<META http-equiv=Content-Type content="text/html; charset=ISO-8859-1">
-<META content="MSHTML 6.00.2900.2627" name=GENERATOR></HEAD>
-<BODY lang=EN-US>
-<H2>About This Content</H2>
-<P>February 24, 2005</P>
-<H3>License</H3>
-<P>The Eclipse Foundation makes available all content in this plug-in
-("Content"). Unless otherwise indicated below, the Content is provided to you
-under the terms and conditions of the Eclipse Public License Version 1.0
-("EPL"). A copy of the EPL is available at <A
-href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</A>.
-For purposes of the EPL, "Program" will mean the Content.</P>
-<P>If you did not receive this Content directly from the Eclipse Foundation, the
-Content is being redistributed by another party ("Redistributor") and different
-terms and conditions may apply to your use of any object code in the Content.
-Check the Redistributor's license that was provided with the Content. If no such
-license exists, contact the Redistributor. Unless otherwise indicated below, the
-terms and conditions of the EPL still apply to any source code in the
-Content.</P></BODY></HTML>
diff --git a/org.eclipse.mylyn.bugzilla.tests/build.properties b/org.eclipse.mylyn.bugzilla.tests/build.properties
deleted file mode 100644
index 579fd5261..000000000
--- a/org.eclipse.mylyn.bugzilla.tests/build.properties
+++ /dev/null
@@ -1,23 +0,0 @@
-###############################################################################
-# Copyright (c) 2004 - 2005 University Of British Columbia and others.
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Eclipse Public License v1.0
-# which accompanies this distribution, and is available at
-# http://www.eclipse.org/legal/epl-v10.html
-#
-# Contributors:
-# University Of British Columbia - initial API and implementation
-###############################################################################
-bin.includes = plugin.xml,\
- bugzilla-test.jar,\
- META-INF/,\
- TestPages/,\
- about.html
-jars.compile.order = bugzilla-test.jar
-source.bugzilla-test.jar = src/
-output.bugzilla-test.jar = bin/
-src.includes = src/,\
- plugin.xml,\
- about.html,\
- TestPages/,\
- META-INF/
diff --git a/org.eclipse.mylyn.bugzilla.tests/plugin.xml b/org.eclipse.mylyn.bugzilla.tests/plugin.xml
deleted file mode 100644
index 80e8dd15c..000000000
--- a/org.eclipse.mylyn.bugzilla.tests/plugin.xml
+++ /dev/null
@@ -1,6 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<?eclipse version="3.0"?>
-<?eclipse version="3.0"?>
-<plugin>
-
-</plugin>
diff --git a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/AllTests.java b/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/AllTests.java
deleted file mode 100644
index b880cd7ac..000000000
--- a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/AllTests.java
+++ /dev/null
@@ -1,42 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-package org.eclipse.mylar.bugzilla.test;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
-//TODO add tests for 2.18 bugzilla
-
-/**
- * @author tanya
- *
- * To change the template for this generated type comment go to
- * Window&gt;Preferences&gt;Java&gt;Code Generation&gt;Code and Comments
- */
-public class AllTests {
-
- public static Test suite() {
- TestSuite suite = new TestSuite("Test for org.eclipse.mylar.bugzilla.test");
- //$JUnit-BEGIN$
- suite.addTest(new TestSuite(BugzillaNewBugParserTestCDT.class));
- suite.addTest(new TestSuite(BugzillaNewBugParserTestEquinox.class));
- suite.addTest(new TestSuite(BugzillaNewBugParserTestGMT.class));
- suite.addTest(new TestSuite(BugzillaNewBugParserTestPlatform.class));
- suite.addTest(new TestSuite(BugzillaNewBugParserTestVE.class));
- suite.addTest(new TestSuite(BugzillaParserTest.class));
- suite.addTest(new TestSuite(BugzillaParserTestNoBug.class));
- suite.addTest(new TestSuite(
- BugzillaProductParser1ProductHipikatTest.class));
- suite.addTest(new TestSuite(BugzillaProductParserTest.class));
- //$JUnit-END$
- return suite;
- }
-}
diff --git a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaNewBugParserTestCDT.java b/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaNewBugParserTestCDT.java
deleted file mode 100644
index f6d241feb..000000000
--- a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaNewBugParserTestCDT.java
+++ /dev/null
@@ -1,231 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-package org.eclipse.mylar.bugzilla.test;
-
-import java.io.File;
-import java.io.FileReader;
-import java.io.Reader;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-
-import junit.framework.TestCase;
-
-import org.eclipse.core.runtime.Path;
-import org.eclipse.mylar.bugzilla.core.Attribute;
-import org.eclipse.mylar.bugzilla.core.internal.NewBugParser;
-import org.eclipse.mylar.bugzilla.ui.wizard.NewBugModel;
-
-
-/**
- * Tests NewBugParser -- parses product attributes for new bug reports
- */
-public class BugzillaNewBugParserTestCDT extends TestCase {
-
- public BugzillaNewBugParserTestCDT() {
- super();
- }
-
- public BugzillaNewBugParserTestCDT(String arg0) {
- super(arg0);
- }
-
- public void testProductCDT() throws Exception {
-
- File f = FileTool.getFileInPlugin(BugzillaTestPlugin.getDefault(), new Path("TestPages/cdt-page.html"));
-
- Reader in = new FileReader(f);
-
- NewBugModel nbm = new NewBugModel();
- new NewBugParser(in).parseBugAttributes(nbm, true); // ** TRUE vs FALSE **
-
- // attributes for this bug model
- List<Attribute> attributes = nbm.getAttributes();
-// printList(attributes);
-
- Iterator<Attribute> itr = attributes.iterator();
- Attribute att = itr.next();
-
- // Attribute: Severity
- assertEquals("Attribute: Severity", "Severity", att.getName());
-
- Map<String, String> attOptions = att.getOptionValues(); // HashMap of
- // options for the
- // current
- // attribute
- Object[] options = attOptions.keySet().toArray(); // Array of keys for
- // the options of the
- // current attribute
- assertEquals("# Severity options", 7, options.length);
-
- int i = 0;
- while (i < options.length) {
- assertEquals("severity options", "blocker", options[i++]);
- assertEquals("severity options", "critical", options[i++]);
- assertEquals("severity options", "major", options[i++]);
- assertEquals("severity options", "normal", options[i++]);
- assertEquals("severity options", "minor", options[i++]);
- assertEquals("severity options", "trivial", options[i++]);
- assertEquals("severity options", "enhancement", options[i++]);
- }
-
- // Attribute: product
- att = itr.next();
- assertEquals("Attribute: product", "product", att.getName());
-
- attOptions = att.getOptionValues();
- options = attOptions.keySet().toArray();
- assertEquals("No product options", 0, options.length);
-
- // Attribute: AssignedTo
- att = itr.next();
- assertEquals("Attribute: AssignedTo", "AssignedTo", att.getName());
-
- attOptions = att.getOptionValues();
- options = attOptions.keySet().toArray();
- assertEquals("No AssignedTo options", 0, options.length);
-
- // Attribute: OS
- att = itr.next();
- assertEquals("Attribute: OS", "OS", att.getName());
-
- attOptions = att.getOptionValues();
- options = attOptions.keySet().toArray();
- assertEquals("# of options", 20, options.length);
-
- i = 0;
- while (i < options.length) {
- assertEquals("OS options", "All", options[i++]);
- assertEquals("OS options", "AIX Motif", options[i++]);
- assertEquals("OS options", "Windows 95", options[i++]);
- assertEquals("OS options", "Windows 98", options[i++]);
- assertEquals("OS options", "Windows CE", options[i++]);
- assertEquals("OS options", "Windows ME", options[i++]);
- assertEquals("OS options", "Windows 2000", options[i++]);
- assertEquals("OS options", "Windows NT", options[i++]);
- assertEquals("OS options", "Windows XP", options[i++]);
- assertEquals("OS options", "Windows All", options[i++]);
- assertEquals("OS options", "MacOS X", options[i++]);
- assertEquals("OS options", "Linux", options[i++]);
- assertEquals("OS options", "Linux-GTK", options[i++]);
- assertEquals("OS options", "Linux-Motif", options[i++]);
- assertEquals("OS options", "HP-UX", options[i++]);
- assertEquals("OS options", "Neutrino", options[i++]);
- assertEquals("OS options", "QNX-Photon", options[i++]);
- assertEquals("OS options", "Solaris", options[i++]);
- assertEquals("OS options", "Unix All", options[i++]);
- assertEquals("OS options", "other", options[i++]);
- }
-
- // Attribute: Version
- att = itr.next();
- assertEquals("Attribute: Version", "Version", att.getName());
-
- //attOptions = (HashMap) att.getOptionValues();
- options = att.getOptionValues().keySet().toArray();
- assertEquals("# Version options", 5, options.length);
-
- i = 0;
- while (i < options.length) {
- assertEquals("Version options", "1.0", options[i++]);
- assertEquals("Version options", "1.0.1", options[i++]);
- assertEquals("Version options", "1.1", options[i++]);
- assertEquals("Version options", "1.2", options[i++]);
- assertEquals("Version options", "2.0", options[i++]);
- }
-
- // Attribute: Platform
- att = itr.next();
- assertEquals("Attribute: Platform", "Platform", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("# Platform options", 6, options.length);
-
- i = 0;
- while (i < options.length) {
- assertEquals("Platform options", "All", options[i++]);
- assertEquals("Platform options", "Macintosh", options[i++]);
- assertEquals("Platform options", "PC", options[i++]);
- assertEquals("Platform options", "Power PC", options[i++]);
- assertEquals("Platform options", "Sun", options[i++]);
- assertEquals("Platform options", "Other", options[i++]);
- }
-
- // Attribute: Component
- att = itr.next();
- assertEquals("Attribute: Component", "Component", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("# Component options", 9, options.length);
-
- i = 0;
- while (i < options.length) {
- assertEquals("Component options", "CDT-parser", options[i++]);
- assertEquals("Component options", "Core", options[i++]);
- assertEquals("Component options", "Cpp-Extensions", options[i++]);
- assertEquals("Component options", "Debug", options[i++]);
- assertEquals("Component options", "Debug-MI", options[i++]);
- assertEquals("Component options", "Doc", options[i++]);
- assertEquals("Component options", "Generic-Extensions",
- options[i++]);
- assertEquals("Component options", "Launcher", options[i++]);
- assertEquals("Component options", "UI", options[i++]);
- }
-
- // Attribute: bug_status
- att = itr.next();
- assertEquals("Attribute: bug_status", "bug_status", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("# bug_status options [none]", 0, options.length);
-
- // Attribute: form_name
- att = itr.next();
- assertEquals("Attribute: form_name", "form_name", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("No form_name options", 0, options.length);
-
- // Attribute: bug_file_loc
- att = itr.next();
- assertEquals("Attribute: bug_file_loc", "bug_file_loc", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("No bug_file_loc options", 0, options.length);
-
- // Attribute: priority
- att = itr.next();
- assertEquals("Attribute: priority", "priority", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("No priority options", 0, options.length);
-
- }
-
-// private void printList(List<Attribute> attributes) {
-//
-// Iterator<Attribute> itr = attributes.iterator();
-// System.out.println("Attributes for this Product:");
-// System.out.println("============================");
-//
-// while (itr.hasNext()) {
-// Attribute attr = itr.next();
-// System.out.println();
-// System.out.println(attr.getName() + ": ");
-// System.out.println("-----------");
-//
-// Map<String, String> options = attr.getOptionValues();
-// Object[] it = options.keySet().toArray();
-// for (int i = 0; i < it.length; i++)
-// System.out.println((String) it[i]);
-// }
-// }
-}
diff --git a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaNewBugParserTestEquinox.java b/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaNewBugParserTestEquinox.java
deleted file mode 100644
index 602483300..000000000
--- a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaNewBugParserTestEquinox.java
+++ /dev/null
@@ -1,216 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-package org.eclipse.mylar.bugzilla.test;
-
-import java.io.File;
-import java.io.FileReader;
-import java.io.Reader;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-
-import junit.framework.TestCase;
-
-import org.eclipse.core.runtime.Path;
-import org.eclipse.mylar.bugzilla.core.Attribute;
-import org.eclipse.mylar.bugzilla.core.internal.NewBugParser;
-import org.eclipse.mylar.bugzilla.ui.wizard.NewBugModel;
-
-
-/**
- * Tests NewBugParser -- parses product attributes
- */
-public class BugzillaNewBugParserTestEquinox extends TestCase {
-
- public BugzillaNewBugParserTestEquinox() {
- super();
- }
-
- public BugzillaNewBugParserTestEquinox(String arg0) {
- super(arg0);
- }
-
- public void testProductEquinox() throws Exception {
-
- File f = FileTool.getFileInPlugin(BugzillaTestPlugin.getDefault(), new Path("TestPages/equinox-page.html"));
-
- Reader in = new FileReader(f);
-
- NewBugModel nbm = new NewBugModel();
- new NewBugParser(in).parseBugAttributes(nbm, true); // ** TRUE vs FALSE **
-
- // attributes for this bug model
- List<Attribute> attributes = nbm.getAttributes();
-// printList(attributes);
-
- Iterator<Attribute> itr = attributes.iterator();
- Attribute att = itr.next();
-
- // Attribute: Severity
- assertEquals("Attribute: Severity", "Severity", att.getName());
-
- Map<String, String> attOptions = att.getOptionValues(); // HashMap of
- // options for the
- // current
- // attribute
- Object[] options = attOptions.keySet().toArray(); // Array of keys for
- // the options of the
- // current attribute
- assertEquals("# Severity options", 7, options.length);
-
- int i = 0;
- while (i < options.length) {
- assertEquals("severity options", "blocker", options[i++]);
- assertEquals("severity options", "critical", options[i++]);
- assertEquals("severity options", "major", options[i++]);
- assertEquals("severity options", "normal", options[i++]);
- assertEquals("severity options", "minor", options[i++]);
- assertEquals("severity options", "trivial", options[i++]);
- assertEquals("severity options", "enhancement", options[i++]);
- }
-
- // Attribute: product
- att = itr.next();
- assertEquals("Attribute: prodcut", "product", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("No product options", 0, options.length);
-
- // Attribute: AssignedTo
- att = itr.next();
- assertEquals("Attribute: AssignedTo", "AssignedTo", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("No AssignedTo options", 0, options.length);
-
- // Attribute: OS
- att = itr.next();
- assertEquals("Attribute: OS", "OS", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("# OS options", 20, options.length);
-
- i = 0;
- while (i < options.length) {
- assertEquals("OS options", "All", options[i++]);
- assertEquals("OS options", "AIX Motif", options[i++]);
- assertEquals("OS options", "Windows 95", options[i++]);
- assertEquals("OS options", "Windows 98", options[i++]);
- assertEquals("OS options", "Windows CE", options[i++]);
- assertEquals("OS options", "Windows ME", options[i++]);
- assertEquals("OS options", "Windows 2000", options[i++]);
- assertEquals("OS options", "Windows NT", options[i++]);
- assertEquals("OS options", "Windows XP", options[i++]);
- assertEquals("OS options", "Windows All", options[i++]);
- assertEquals("OS options", "MacOS X", options[i++]);
- assertEquals("OS options", "Linux", options[i++]);
- assertEquals("OS options", "Linux-GTK", options[i++]);
- assertEquals("OS options", "Linux-Motif", options[i++]);
- assertEquals("OS options", "HP-UX", options[i++]);
- assertEquals("OS options", "Neutrino", options[i++]);
- assertEquals("OS options", "QNX-Photon", options[i++]);
- assertEquals("OS options", "Solaris", options[i++]);
- assertEquals("OS options", "Unix All", options[i++]);
- assertEquals("OS options", "other", options[i++]);
- }
-
- // Attribute: Version
- att = itr.next();
- assertEquals("Attribute: Version", "Version", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("# Version options", 1, options.length);
-
- i = 0;
- while (i < options.length) {
- assertEquals("Version options", "unspecified", options[i++]);
- }
-
- // Attribute: Platform
- att = itr.next();
- assertEquals("Attribute: Platform", "Platform", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("# Platform options", 6, options.length);
-
- i = 0;
- while (i < options.length) {
- assertEquals("Platform options", "All", options[i++]);
- assertEquals("Platform options", "Macintosh", options[i++]);
- assertEquals("Platform options", "PC", options[i++]);
- assertEquals("Platform options", "Power PC", options[i++]);
- assertEquals("Platform options", "Sun", options[i++]);
- assertEquals("Platform options", "Other", options[i++]);
- }
-
- // Attribute: Component
- att = itr.next();
- assertEquals("Attribute: Component", "Component", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("# Component options", 3, options.length);
-
- i = 0;
- while (i < options.length) {
- assertEquals("Component options", "Dynamic Plugins", options[i++]);
- assertEquals("Component options", "General", options[i++]);
- assertEquals("Component options", "OSGi", options[i++]);
- }
-
- // Attribute: bug_status
- att = itr.next();
- assertEquals("Attribute: bug_status", "bug_status", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("No bug_status options", 0, options.length);
-
- // Attribute: form_name
- att = itr.next();
- assertEquals("Attribute: form_name", "form_name", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("No form_name options", 0, options.length);
-
- // Attribute: bug_file_loc
- att = itr.next();
- assertEquals("Attribute: bug_file_loc", "bug_file_loc", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("No bug_file_loc options", 0, options.length);
-
- // Attribute: priority
- att = itr.next();
- assertEquals("Attribute: priority", "priority", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("No priority options", 0, options.length);
-
- }
-
-// private void printList(List<Attribute> attributes) {
-//
-// Iterator<Attribute> itr = attributes.iterator();
-// System.out.println("Attributes for this Product:");
-// System.out.println("============================");
-//
-// while (itr.hasNext()) {
-// Attribute attr = itr.next();
-// System.out.println();
-// System.out.println(attr.getName() + ": ");
-// System.out.println("-----------");
-//
-// Map<String, String> options = attr.getOptionValues();
-// Object[] it = options.keySet().toArray();
-// for (int i = 0; i < it.length; i++)
-// System.out.println((String) it[i]);
-// }
-// }
-}
diff --git a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaNewBugParserTestGMT.java b/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaNewBugParserTestGMT.java
deleted file mode 100644
index 4edced4df..000000000
--- a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaNewBugParserTestGMT.java
+++ /dev/null
@@ -1,217 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-package org.eclipse.mylar.bugzilla.test;
-
-import java.io.File;
-import java.io.FileReader;
-import java.io.Reader;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-
-import junit.framework.TestCase;
-
-import org.eclipse.core.runtime.Path;
-import org.eclipse.mylar.bugzilla.core.Attribute;
-import org.eclipse.mylar.bugzilla.core.internal.NewBugParser;
-import org.eclipse.mylar.bugzilla.ui.wizard.NewBugModel;
-
-
-/**
- * Tests NewBugParser -- parses product attributes
- */
-public class BugzillaNewBugParserTestGMT extends TestCase {
-
- public BugzillaNewBugParserTestGMT() {
- super();
- }
-
- public BugzillaNewBugParserTestGMT(String arg0) {
- super(arg0);
- }
-
- public void testProductGMT() throws Exception {
-
- File f = FileTool.getFileInPlugin(BugzillaTestPlugin.getDefault(), new Path("TestPages/gmt-page.html"));
-
- Reader in = new FileReader(f);
-
- NewBugModel nbm = new NewBugModel();
- new NewBugParser(in).parseBugAttributes(nbm, true); // ** TRUE vs FALSE **
-
- // attributes for this bug model
- List<Attribute> attributes = nbm.getAttributes();
-// printList(attributes);
-
- Iterator<Attribute> itr = attributes.iterator();
- Attribute att = itr.next();
-
- // Attribute: Severity
- assertEquals("Attribute: Severity", "Severity", att.getName());
-
- Map<String, String> attOptions = att.getOptionValues(); // HashMap of
- // options for the
- // current
- // attribute
- Object[] options = attOptions.keySet().toArray(); // Array of keys for
- // the options of the
- // current attribute
- assertEquals("# Severity options", 7, options.length);
-
- int i = 0;
- while (i < options.length) {
- assertEquals("severity options", "blocker", options[i++]);
- assertEquals("severity options", "critical", options[i++]);
- assertEquals("severity options", "major", options[i++]);
- assertEquals("severity options", "normal", options[i++]);
- assertEquals("severity options", "minor", options[i++]);
- assertEquals("severity options", "trivial", options[i++]);
- assertEquals("severity options", "enhancement", options[i++]);
- }
-
- // Attribute: product
- att = itr.next();
- assertEquals("Attribute: product", "product", att.getName());
-
- attOptions = att.getOptionValues();
- options = attOptions.keySet().toArray();
- assertEquals("No product options", 0, options.length);
-
- // Attribute: AssignedTo
- att = itr.next();
- assertEquals("Attribute: AssignedTo", "AssignedTo", att.getName());
-
- attOptions = att.getOptionValues();
- options = attOptions.keySet().toArray();
- assertEquals("No AssignedTo options", 0, options.length);
-
- // Attribute: OS
- att = itr.next();
- assertEquals("Attribute: OS", "OS", att.getName());
-
- attOptions = att.getOptionValues();
- options = attOptions.keySet().toArray();
- assertEquals("# of options", 20, options.length);
-
- i = 0;
- while (i < options.length) {
- assertEquals("OS options", "All", options[i++]);
- assertEquals("OS options", "AIX Motif", options[i++]);
- assertEquals("OS options", "Windows 95", options[i++]);
- assertEquals("OS options", "Windows 98", options[i++]);
- assertEquals("OS options", "Windows CE", options[i++]);
- assertEquals("OS options", "Windows ME", options[i++]);
- assertEquals("OS options", "Windows 2000", options[i++]);
- assertEquals("OS options", "Windows NT", options[i++]);
- assertEquals("OS options", "Windows XP", options[i++]);
- assertEquals("OS options", "Windows All", options[i++]);
- assertEquals("OS options", "MacOS X", options[i++]);
- assertEquals("OS options", "Linux", options[i++]);
- assertEquals("OS options", "Linux-GTK", options[i++]);
- assertEquals("OS options", "Linux-Motif", options[i++]);
- assertEquals("OS options", "HP-UX", options[i++]);
- assertEquals("OS options", "Neutrino", options[i++]);
- assertEquals("OS options", "QNX-Photon", options[i++]);
- assertEquals("OS options", "Solaris", options[i++]);
- assertEquals("OS options", "Unix All", options[i++]);
- assertEquals("OS options", "other", options[i++]);
- }
-
- // Attribute: Version
- att = itr.next();
- assertEquals("Attribute: Version", "Version", att.getName());
-
- //attOptions = (HashMap) att.getOptionValues();
- options = att.getOptionValues().keySet().toArray();
- assertEquals("# Version options", 1, options.length);
-
- i = 0;
- while (i < options.length) {
- assertEquals("Version options", "unspecified", options[i++]);
- }
-
- // Attribute: Platform
- att = itr.next();
- assertEquals("Attribute: Platform", "Platform", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("# Platform options", 6, options.length);
-
- i = 0;
- while (i < options.length) {
- assertEquals("Platform options", "All", options[i++]);
- assertEquals("Platform options", "Macintosh", options[i++]);
- assertEquals("Platform options", "PC", options[i++]);
- assertEquals("Platform options", "Power PC", options[i++]);
- assertEquals("Platform options", "Sun", options[i++]);
- assertEquals("Platform options", "Other", options[i++]);
- }
-
- att = itr.next();
- assertEquals("Attribute: Component", "Component", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("# Component options", 1, options.length);
-
- i = 0;
- while (i < options.length) {
- assertEquals("Component options", "Core", options[i++]);
- }
-
- // Attribute: bug_status
- att = itr.next();
- assertEquals("Attribute: bug_status", "bug_status", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("No bug_status options", 0, options.length);
-
- // Attribute: form_name
- att = itr.next();
- assertEquals("Attribute: form_name", "form_name", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("No form_name options", 0, options.length);
-
- // Attribute: bug_file_loc
- att = itr.next();
- assertEquals("Attribute: bug_file_loc", "bug_file_loc", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("No bug_file_loc options", 0, options.length);
-
- // Attribute: priority
- att = itr.next();
- assertEquals("Attribute: priority", "priority", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("No priority options", 0, options.length);
-
- }
-
-// private void printList(List<Attribute> attributes) {
-//
-// Iterator<Attribute> itr = attributes.iterator();
-// System.out.println("Attributes for this Product:");
-// System.out.println("============================");
-//
-// while (itr.hasNext()) {
-// Attribute attr = itr.next();
-// System.out.println();
-// System.out.println(attr.getName() + ": ");
-// System.out.println("-----------");
-//
-// Map<String, String> options = attr.getOptionValues();
-// Object[] it = options.keySet().toArray();
-// for (int i = 0; i < it.length; i++)
-// System.out.println((String) it[i]);
-// }
-// }
-}
diff --git a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaNewBugParserTestPlatform.java b/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaNewBugParserTestPlatform.java
deleted file mode 100644
index 941814b84..000000000
--- a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaNewBugParserTestPlatform.java
+++ /dev/null
@@ -1,243 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-package org.eclipse.mylar.bugzilla.test;
-
-import java.io.File;
-import java.io.FileReader;
-import java.io.Reader;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-
-import junit.framework.TestCase;
-
-import org.eclipse.core.runtime.Path;
-import org.eclipse.mylar.bugzilla.core.Attribute;
-import org.eclipse.mylar.bugzilla.core.internal.NewBugParser;
-import org.eclipse.mylar.bugzilla.ui.wizard.NewBugModel;
-
-
-/**
- * Tests NewBugParser -- parses product attributes
- */
-public class BugzillaNewBugParserTestPlatform extends TestCase {
-
- public BugzillaNewBugParserTestPlatform() {
- super();
- }
-
- public BugzillaNewBugParserTestPlatform(String arg0) {
- super(arg0);
- }
-
- public void testProductPlatform() throws Exception {
-
- File f = FileTool.getFileInPlugin(BugzillaTestPlugin.getDefault(), new Path("TestPages/platform-page.html"));
-
- Reader in = new FileReader(f);
-
- NewBugModel nbm = new NewBugModel();
- new NewBugParser(in).parseBugAttributes(nbm, true); // ** TRUE vs FALSE **
-
- // attributes for this bug model
- List<Attribute> attributes = nbm.getAttributes();
-// printList(attributes);
-
- // to iterator over the ArrayList of attributes
- Iterator<Attribute> itr = attributes.iterator();
-
- // Attribute: Severity
- Attribute att = itr.next(); // current attribute
-
- // Attribute: Severity
- assertEquals("Attribute: Severity", "Severity", att.getName());
-
- Map<String, String> attOptions = att.getOptionValues(); // HashMap of
- // options for the
- // current
- // attribute
- Object[] options = attOptions.keySet().toArray(); // Array of keys for
- // the options of the
- // current attribute
- assertEquals("# Severity options", 7, options.length);
-
- int i = 0;
- while (i < options.length) {
- assertEquals("severity options", "blocker", options[i++]);
- assertEquals("severity options", "critical", options[i++]);
- assertEquals("severity options", "major", options[i++]);
- assertEquals("severity options", "normal", options[i++]);
- assertEquals("severity options", "minor", options[i++]);
- assertEquals("severity options", "trivial", options[i++]);
- assertEquals("severity options", "enhancement", options[i++]);
- }
-
- // Attribute: product
- att = itr.next();
- assertEquals("Attribute: product", "product", att.getName());
-
- attOptions = att.getOptionValues();
- options = attOptions.keySet().toArray();
- assertEquals("No product optins", 0, options.length);
-
- // Attribute: AssignedTo
- att = itr.next();
- assertEquals("Attribute: Assigned To", "Assigned To", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("No AssingedTo options", 0, options.length);
-
- // Attribute: OS
- att = itr.next();
- assertEquals("Attribute: OS", "OS", att.getName());
-
- attOptions = att.getOptionValues();
- options = attOptions.keySet().toArray();
- assertEquals("# OS options", 20, options.length);
-
- i = 0;
- while (i < options.length) {
- assertEquals("OS options", "All", options[i++]);
- assertEquals("OS options", "AIX Motif", options[i++]);
- assertEquals("OS options", "Windows 95", options[i++]);
- assertEquals("OS options", "Windows 98", options[i++]);
- assertEquals("OS options", "Windows CE", options[i++]);
- assertEquals("OS options", "Windows ME", options[i++]);
- assertEquals("OS options", "Windows 2000", options[i++]);
- assertEquals("OS options", "Windows NT", options[i++]);
- assertEquals("OS options", "Windows XP", options[i++]);
- assertEquals("OS options", "Windows All", options[i++]);
- assertEquals("OS options", "MacOS X", options[i++]);
- assertEquals("OS options", "Linux", options[i++]);
- assertEquals("OS options", "Linux-GTK", options[i++]);
- assertEquals("OS options", "Linux-Motif", options[i++]);
- assertEquals("OS options", "HP-UX", options[i++]);
- assertEquals("OS options", "Neutrino", options[i++]);
- assertEquals("OS options", "QNX-Photon", options[i++]);
- assertEquals("OS options", "Solaris", options[i++]);
- assertEquals("OS options", "Unix All", options[i++]);
- assertEquals("OS options", "other", options[i++]);
- }
-
- // Attribute: Version
- att = itr.next();
- assertEquals("Attribute: Version", "Version", att.getName());
-
- attOptions = att.getOptionValues();
- options = attOptions.keySet().toArray();
- assertEquals("# Version options", 8, options.length);
-
- i = 0;
- while (i < options.length) {
- assertEquals("Version options", "1.0", options[i++]);
- assertEquals("Version options", "2.0", options[i++]);
- assertEquals("Version options", "2.0.1", options[i++]);
- assertEquals("Version options", "2.0.2", options[i++]);
- assertEquals("Version options", "2.1", options[i++]);
- assertEquals("Version options", "2.1.1", options[i++]);
- assertEquals("Version options", "2.1.2", options[i++]);
- assertEquals("Version options", "3.0", options[i++]);
- }
-
- // Attribute: Platform
- att = itr.next();
- assertEquals("Attribute: Platform", "Platform", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("# Platform options", 6, options.length);
-
- i = 0;
- while (i < options.length) {
- assertEquals("Platform options", "All", options[i++]);
- assertEquals("Platform options", "Macintosh", options[i++]);
- assertEquals("Platform options", "PC", options[i++]);
- assertEquals("Platform options", "Power PC", options[i++]);
- assertEquals("Platform options", "Sun", options[i++]);
- assertEquals("Platform options", "Other", options[i++]);
- }
-
- // Attribute: Component
- att = itr.next();
- assertEquals("Attribute: Component", "Component", att.getName());
-
- attOptions = att.getOptionValues();
- options = attOptions.keySet().toArray();
- assertEquals("# Component options", 16, options.length);
-
- i = 0;
- while (i < options.length) {
- assertEquals("Component options", "Ant", options[i++]);
- assertEquals("Component options", "Compare", options[i++]);
- assertEquals("Component options", "Core", options[i++]);
- assertEquals("Component options", "CVS", options[i++]);
- assertEquals("Component options", "Debug", options[i++]);
- assertEquals("Component options", "Doc", options[i++]);
- assertEquals("Component options", "Help", options[i++]);
- assertEquals("Component options", "Releng", options[i++]);
- assertEquals("Component options", "Scripting", options[i++]);
- assertEquals("Component options", "Search", options[i++]);
- assertEquals("Component options", "SWT", options[i++]);
- assertEquals("Component options", "Team", options[i++]);
- assertEquals("Component options", "Text", options[i++]);
- assertEquals("Component options", "UI", options[i++]);
- assertEquals("Component options", "Update", options[i++]);
- assertEquals("Component options", "WebDAV", options[i++]);
- }
-
- // Attribute: bug_status
- att = itr.next();
- assertEquals("Attribute: bug_status", "bug_status", att.getName());
-
- attOptions = att.getOptionValues();
- options = attOptions.keySet().toArray();
- assertEquals("No bug_status options", 0, options.length);
-
- // Attribute: form_name
- att = itr.next();
- assertEquals("Attribute: form_name", "form_name", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("No form_name options", 0, options.length);
-
- // Attribute: bug_file_loc
- att = itr.next();
- assertEquals("Attribute: bug_file_loc", "bug_file_loc", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("No bug_file_loc options", 0, options.length);
-
- // Attribute: priority
- att = itr.next();
- assertEquals("Attribute: priority", "priority", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("No priority options", 0, options.length);
- }
-
-// private void printList(List<Attribute> attributes) {
-//
-// Iterator<Attribute> itr = attributes.iterator();
-// System.out.println("Attributes for this Product:");
-// System.out.println("============================");
-//
-// while (itr.hasNext()) {
-// Attribute attr = itr.next();
-// System.out.println();
-// System.out.println(attr.getName() + ": ");
-// System.out.println("-----------");
-//
-// Map<String, String> options = attr.getOptionValues();
-// Object[] it = options.keySet().toArray();
-// for (int i = 0; i < it.length; i++)
-// System.out.println((String) it[i]);
-// }
-// }
-}
diff --git a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaNewBugParserTestVE.java b/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaNewBugParserTestVE.java
deleted file mode 100644
index 9fafda828..000000000
--- a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaNewBugParserTestVE.java
+++ /dev/null
@@ -1,223 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-package org.eclipse.mylar.bugzilla.test;
-
-import java.io.File;
-import java.io.FileReader;
-import java.io.Reader;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-
-import junit.framework.TestCase;
-
-import org.eclipse.core.runtime.Path;
-import org.eclipse.mylar.bugzilla.core.Attribute;
-import org.eclipse.mylar.bugzilla.core.internal.NewBugParser;
-import org.eclipse.mylar.bugzilla.ui.wizard.NewBugModel;
-
-
-/**
- * Tests NewBugParser -- parses product attributes
- */
-public class BugzillaNewBugParserTestVE extends TestCase {
-
- public BugzillaNewBugParserTestVE() {
- super();
- }
-
- public BugzillaNewBugParserTestVE(String arg0) {
- super(arg0);
- }
-
- public void testProductVE() throws Exception {
- File f = FileTool.getFileInPlugin(BugzillaTestPlugin.getDefault(), new Path("TestPages/ve-page.html"));
-
- Reader in = new FileReader(f);
-
- NewBugModel nbm = new NewBugModel();
- new NewBugParser(in).parseBugAttributes(nbm, true); // ** TRUE vs FALSE **
-
- // attributes for this but model
- List<Attribute> attributes = nbm.getAttributes();
-// printList(attributes);
-
- Iterator<Attribute> itr = attributes.iterator();
- Attribute att = itr.next();
-
- // Attribute: Severity
- assertEquals("Attribute: Severity", "Severity", att.getName());
-
- Map<String, String> attOptions = att.getOptionValues(); // HashMap of
- // options for the
- // current
- // attribute
- Object[] options = attOptions.keySet().toArray(); // Array of keys for
- // the options of the
- // current attribute
- assertEquals("# Severity options", 7, options.length);
-
- int i = 0;
- while (i < options.length) {
- assertEquals("severity options", "blocker", options[i++]);
- assertEquals("severity options", "critical", options[i++]);
- assertEquals("severity options", "major", options[i++]);
- assertEquals("severity options", "normal", options[i++]);
- assertEquals("severity options", "minor", options[i++]);
- assertEquals("severity options", "trivial", options[i++]);
- assertEquals("severity options", "enhancement", options[i++]);
- }
-
- // Attribute: product
- att = itr.next();
- assertEquals("Attribute: product", "product", att.getName());
-
- attOptions = att.getOptionValues();
- options = attOptions.keySet().toArray();
- assertEquals("No product options", 0, options.length);
-
- // Attribute: AssignedTo
- att = itr.next();
- assertEquals("Attribute: AssignedTo", "AssignedTo", att.getName());
-
- attOptions = att.getOptionValues();
- options = attOptions.keySet().toArray();
- assertEquals("No AssignedTo options", 0, options.length);
-
- // Attribute: OS
- att = itr.next();
- assertEquals("Attribute: OS", "OS", att.getName());
-
- attOptions = att.getOptionValues();
- options = attOptions.keySet().toArray();
- assertEquals("# of options", 20, options.length);
-
- i = 0;
- while (i < options.length) {
- assertEquals("OS options", "All", options[i++]);
- assertEquals("OS options", "AIX Motif", options[i++]);
- assertEquals("OS options", "Windows 95", options[i++]);
- assertEquals("OS options", "Windows 98", options[i++]);
- assertEquals("OS options", "Windows CE", options[i++]);
- assertEquals("OS options", "Windows ME", options[i++]);
- assertEquals("OS options", "Windows 2000", options[i++]);
- assertEquals("OS options", "Windows NT", options[i++]);
- assertEquals("OS options", "Windows XP", options[i++]);
- assertEquals("OS options", "Windows All", options[i++]);
- assertEquals("OS options", "MacOS X", options[i++]);
- assertEquals("OS options", "Linux", options[i++]);
- assertEquals("OS options", "Linux-GTK", options[i++]);
- assertEquals("OS options", "Linux-Motif", options[i++]);
- assertEquals("OS options", "HP-UX", options[i++]);
- assertEquals("OS options", "Neutrino", options[i++]);
- assertEquals("OS options", "QNX-Photon", options[i++]);
- assertEquals("OS options", "Solaris", options[i++]);
- assertEquals("OS options", "Unix All", options[i++]);
- assertEquals("OS options", "other", options[i++]);
- }
-
- // Attribute: Version
- att = itr.next();
- assertEquals("Attribute: Version", "Version", att.getName());
-
- //attOptions = (HashMap) att.getOptionValues();
- options = att.getOptionValues().keySet().toArray();
- assertEquals("# Version options", 3, options.length);
-
- i = 0;
- while (i < options.length) {
- assertEquals("Version options", "0.5.0", options[i++]);
- assertEquals("Version options", "1.0.0", options[i++]);
- assertEquals("Version options", "unspecified", options[i++]);
- }
-
- // Attribute: Platform
- att = itr.next();
- assertEquals("Attribute: Platform", "Platform", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("# Platform options", 6, options.length);
-
- i = 0;
- while (i < options.length) {
- assertEquals("Platform options", "All", options[i++]);
- assertEquals("Platform options", "Macintosh", options[i++]);
- assertEquals("Platform options", "PC", options[i++]);
- assertEquals("Platform options", "Power PC", options[i++]);
- assertEquals("Platform options", "Sun", options[i++]);
- assertEquals("Platform options", "Other", options[i++]);
- }
-
- att = itr.next();
- assertEquals("Attribute: Component", "Component", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("# Component options", 6, options.length);
-
- i = 0;
- while (i < options.length) {
- assertEquals("Component options", "CDE", options[i++]);
- assertEquals("Component options", "Doc", options[i++]);
- assertEquals("Component options", "Java Core", options[i++]);
- assertEquals("Component options", "Java Model (JEM)", options[i++]);
- assertEquals("Component options", "JFC/Swing", options[i++]);
- assertEquals("Component options", "SWT", options[i++]);
- }
-
- // Attribute: bug_status
- att = itr.next();
- assertEquals("Attribute: bug_status", "bug_status", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("No bug_status options", 0, options.length);
-
- // Attribute: form_name
- att = itr.next();
- assertEquals("Attribute: form_name", "form_name", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("No form_name options", 0, options.length);
-
- // Attribute: bug_file_loc
- att = itr.next();
- assertEquals("Attribute: bug_file_loc", "bug_file_loc", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("No bug_file_loc options", 0, options.length);
-
- // Attribute: priority
- att = itr.next();
- assertEquals("Attribute: priority", "priority", att.getName());
-
- options = att.getOptionValues().keySet().toArray();
- assertEquals("No priority options", 0, options.length);
-
- }
-
-// private void printList(List<Attribute> attributes) {
-//
-// Iterator<Attribute> itr = attributes.iterator();
-// System.out.println("Attributes for this Product:");
-// System.out.println("============================");
-//
-// while (itr.hasNext()) {
-// Attribute attr = itr.next();
-// System.out.println();
-// System.out.println(attr.getName() + ": ");
-// System.out.println("-----------");
-//
-// Map<String, String> options = attr.getOptionValues();
-// Object[] it = options.keySet().toArray();
-// for (int i = 0; i < it.length; i++)
-// System.out.println((String) it[i]);
-// }
-// }
-}
diff --git a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaParserTest.java b/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaParserTest.java
deleted file mode 100644
index 00a34463f..000000000
--- a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaParserTest.java
+++ /dev/null
@@ -1,215 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-package org.eclipse.mylar.bugzilla.test;
-
-import java.io.File;
-import java.io.FileReader;
-import java.io.Reader;
-import java.util.Iterator;
-
-import junit.framework.TestCase;
-
-import org.eclipse.core.runtime.Path;
-import org.eclipse.mylar.bugzilla.core.BugReport;
-import org.eclipse.mylar.bugzilla.core.Comment;
-import org.eclipse.mylar.bugzilla.core.internal.BugParser;
-
-
-/**
- * Tests for parsing Bugzilla reports
- */
-public class BugzillaParserTest extends TestCase {
-
- public BugzillaParserTest() {
- super();
- }
-
- public BugzillaParserTest(String arg0) {
- super(arg0);
- }
-
- public void testFullReportBug1() throws Exception {
-
- File f = FileTool.getFileInPlugin(BugzillaTestPlugin.getDefault(), new Path("TestPages/bug-1-full.html"));
-
- Reader in = new FileReader(f);
-
- BugReport bug = BugParser.parseBug(in, 1, "<server>", false, null, null);
-
-// displayBug(bug);
- assertEquals("Bug id", 1, bug.getId());
- assertEquals("Bug summary",
- "Usability issue with external editors (1GE6IRL)", bug
- .getSummary());
- assertEquals("Reporter", "andre_weinand@ch.ibm.com (Andre Weinand)",
- bug.getReporter());
- assertEquals("Reporter", "andre_weinand@ch.ibm.com (Andre Weinand)",
- bug.getAttribute("Reporter").getValue());
- assertEquals("Summary",
- "Usability issue with external editors (1GE6IRL)", bug
- .getSummary());
- assertEquals("Status", "VERIFIED", bug.getStatus());
- assertEquals("Resolution", "FIXED", bug.getResolution());
- assertEquals("Keywords", null, bug.getKeywords());
- assertEquals("Assigned To", "James_Moody@ca.ibm.com (James Moody)", bug
- .getAssignedTo());
- assertEquals("Priority", "P3", bug.getAttribute("Priority").getValue());
- assertEquals("OS", "All", bug.getAttribute("OS").getValue());
- assertEquals("Version", "2.0", bug.getAttribute("Version").getValue());
- assertEquals("Target Milestone", "---", bug.getAttribute(
- "Target Milestone").getValue());
- assertEquals("Keywords", "", bug.getAttribute("Keywords").getValue());
- assertEquals("Severity", "normal", bug.getAttribute("Severity")
- .getValue());
- assertEquals("Component", "VCM", bug.getAttribute("Component")
- .getValue());
- assertEquals("CC", "Kevin_McGuire@oti.com", bug.getCC()
- .iterator().next());
- assertEquals("Platform", "All", bug.getAttribute("Platform").getValue());
- assertEquals("Product", "Platform", bug.getAttribute("Product")
- .getValue());
- assertEquals("URL", "", bug.getAttribute("URL").getValue());
- assertEquals("Bug#", "1", bug.getAttribute("Bug#").getValue());
-
- // Description
- String description = "- Setup a project that contains a *.gif resource\n"
- + "\t- release project to CVS\n"
- + "\t- edit the *.gif resource with an external editor, e.g. PaintShop\n"
- + "\t- save and close external editor\n"
- + "\t- in Navigator open the icon resource and verify that your changes are there\n"
- + "\t- release project\n"
- + "\t\t-> nothing to release!\n"
- + "\t- in Navigator open the icon resource and verify that your changes are still there\n\n"
- +
-
- "\tProblem: because I never \"Refreshed from local\", the workspace hasn't changed so \"Release\" didn't find anything.\n"
- + "\tHowever opening the resource with an external editor found the modified file on disk and showed the changes.\n\n"
- +
-
- "\tThe real problem occurs if \"Release\" actually finds something to release but you don't spot that some resources are missing.\n"
- + "\tThis is extremely error prone: one of my changes didn't made it into build 110 because of this!\n\n"
- +
-
- "NOTES:\n"
- + "EG (5/23/01 3:00:33 PM)\n"
- + "\tRelease should do a refresh from local before doing the release.\n"
- + "\tMoving to VCM\n\n\n"
- +
-
- "KM (05/27/01 5:10:19 PM)\n"
- + "\tComments from JM in related email:\n\n"
- +
-
- "\tShould not do this for free. Could have a setting which made it optoinal but should nt be mandatory. Default setting could be to have it on.\n"
- + "\tConsider the SWT team who keep their workspaces on network drives. This will be slow. \n\n"
- +
-
- "\tSide effects will be that a build runs when the refresh is completed unless you somehow do it in a workspace runnable and don't end the\n"
- + "\trunnable until after the release. This would be less than optimal as some builders may be responsible for maintaining some invariants and deriving resources which are releasable. If you don't run the builders before releasing, the invariants will not be maintained and you will release inconsistent state.\n\n"
- +
-
- "\tSummary: Offer to \"ensure local consistency\" before releasing.\n\n"
- +
-
- "KM (5/31/01 1:30:35 PM)\n"
- + "\tSee also 1GEAG1A: ITPVCM:WINNT - Internal error comparing with a document\n"
- + "\twhich failed with an error. Never got log from Tod though.";
-
- assertTrue(description.length() == bug.getDescription().length());
- assertEquals("Description", description, bug.getDescription());
-
- // Comments:
- Iterator<Comment> it = bug.getComments().iterator();
- while (it.hasNext()) {
- // COMMENT #1
- Comment comment = it.next();
- assertEquals("Author1", "James_Moody@ca.ibm.com", comment
- .getAuthor());
- assertEquals("Name1", "James Moody", comment.getAuthorName());
- assertEquals(
- "Text1",
- "*** Bug 183 has been marked as a duplicate of this bug. ***",
- comment.getText());
-
- // COMMENT #2
- comment = it.next();
- assertEquals("Author2", "James_Moody@ca.ibm.com", comment
- .getAuthor());
- assertEquals("Name2", "James Moody", comment.getAuthorName());
- assertEquals("Text2",
- "Implemented 'auto refresh' option. Default value is off.",
- comment.getText());
-
- // COMMENT 3
- comment = it.next();
- assertEquals("Author3", "dj_houghton@ca.ibm.com", comment
- .getAuthor());
- assertEquals("Name3", "DJ Houghton", comment.getAuthorName());
- assertEquals("Text3", "PRODUCT VERSION:\n\t109\n\n", comment
- .getText());
-
- // COMMENT 4
- comment = it.next();
- assertEquals("Author4", "James_Moody@ca.ibm.com", comment
- .getAuthor());
- assertEquals("Name4", "James Moody", comment.getAuthorName());
- assertEquals("Text4", "Fixed in v206", comment.getText());
- }
- }
-
-// private static void displayBug(BugReport bug) {
-// System.out.println("Bug " + bug.getId() + ": " + bug.getSummary());
-// System.out.println("Opened: " + bug.getCreated());
-// for (Iterator<Attribute> it = bug.getAttributes().iterator(); it.hasNext();) {
-// Attribute attribute = it.next();
-// String key = attribute.getName();
-// System.out.println(key + ": " + attribute.getValue()
-// + (attribute.isEditable() ? " [OK]" : " %%"));
-// }
-//
-// System.out.print("CC: ");
-// for (Iterator<String> it = bug.getCC().iterator(); it.hasNext();) {
-// String email = it.next();
-// System.out.print(email + " ");
-// }
-// System.out.println();
-//
-// System.out.println(bug.getDescription());
-// for (Iterator<Comment> it = bug.getComments().iterator(); it.hasNext();) {
-// Comment comment = it.next();
-// System.out.println(comment.getAuthorName() + " <"
-// + comment.getAuthor() + "> (" + comment.getCreated() + ")");
-// System.out.print(comment.getText());
-// System.out.println();
-// }
-// }
-//
-// private static void printComments(BugReport bug) {
-// for (Iterator<Comment> it = bug.getComments().iterator(); it.hasNext();) {
-// Comment comment = it.next();
-// System.out.println("Author: " + comment.getAuthor());
-// System.out.println("Name: " + comment.getAuthorName());
-// System.out.println("Date: " + comment.getCreated());
-// System.out.println("Bug ID: " + comment.getBug().getId());
-// System.out.println("Comment: " + comment.getText());
-// System.out.println();
-// }
-// }
-//
-// /** prints names of attributes */
-// private static void printAttributes(BugReport bug) {
-// System.out.println("ATTRIBUTE KEYS:");
-// for (Iterator<Attribute> it = bug.getAttributes().iterator(); it.hasNext();) {
-// Attribute att = it.next();
-// System.out.println(att.getName());
-// }
-// }
-}
diff --git a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaParserTestNoBug.java b/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaParserTestNoBug.java
deleted file mode 100644
index fe3f96746..000000000
--- a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaParserTestNoBug.java
+++ /dev/null
@@ -1,46 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-package org.eclipse.mylar.bugzilla.test;
-
-import java.io.File;
-import java.io.FileReader;
-import java.io.Reader;
-
-import junit.framework.TestCase;
-
-import org.eclipse.core.runtime.Path;
-import org.eclipse.mylar.bugzilla.core.BugReport;
-import org.eclipse.mylar.bugzilla.core.internal.BugParser;
-
-
-/**
- * Tests for parsing Bugzilla reports
- */
-public class BugzillaParserTestNoBug extends TestCase {
-
- public BugzillaParserTestNoBug() {
- super();
- }
-
- public BugzillaParserTestNoBug(String arg0) {
- super(arg0);
- }
-
- public void testBugNotFound() throws Exception {
-
- File f = FileTool.getFileInPlugin(BugzillaTestPlugin.getDefault(), new Path("TestPages/bug-not-found-eclipse.html"));
-
- Reader in = new FileReader(f);
-
- BugReport bug = BugParser.parseBug(in, 666, "<server>", false, null, null);
- assertNull(bug);
- }
-}
diff --git a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaProductParser1ProductHipikatTest.java b/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaProductParser1ProductHipikatTest.java
deleted file mode 100644
index b9d66e13b..000000000
--- a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaProductParser1ProductHipikatTest.java
+++ /dev/null
@@ -1,68 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-package org.eclipse.mylar.bugzilla.test;
-
-import java.io.File;
-import java.io.FileReader;
-import java.io.Reader;
-import java.util.ArrayList;
-import java.util.List;
-
-import junit.framework.TestCase;
-
-import org.eclipse.core.runtime.Path;
-import org.eclipse.mylar.bugzilla.core.internal.ProductParser;
-
-
-/**
- * Tests for parsing Product Page for new Bugzilla reports
- */
-public class BugzillaProductParser1ProductHipikatTest extends TestCase {
-
- public BugzillaProductParser1ProductHipikatTest() {
- super();
- }
-
- public BugzillaProductParser1ProductHipikatTest(String arg0) {
- super(arg0);
- }
-
- public void testOneProduct() throws Exception {
-
- // If only one product, should skip product page (nothing in product
- // list
- // and display the attributes for that product
-
- File f = FileTool.getFileInPlugin(BugzillaTestPlugin.getDefault(), new Path("TestPages/product-page-1-product-hipikat.html"));
-
- Reader in = new FileReader(f);
-
- List<String> productList = new ArrayList<String>();
- productList = new ProductParser(in).getProducts();
-// printList(productList);
-
- assertNull("There were products parsed, and there shouldn't have been", productList);
- }
-
-// private void printList(List<String> productList) {
-//
-// if(productList == null){
-// System.out.println("No products");
-// return;
-// }
-// Iterator<String> itr = productList.iterator();
-// System.out.println("Product List:");
-// if (!itr.hasNext())
-// System.out.println("No products");
-// while (itr.hasNext())
-// System.out.println(itr.next());
-// }
-}
diff --git a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaProductParserTest.java b/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaProductParserTest.java
deleted file mode 100644
index 704f49074..000000000
--- a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaProductParserTest.java
+++ /dev/null
@@ -1,80 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-package org.eclipse.mylar.bugzilla.test;
-
-import java.io.File;
-import java.io.FileReader;
-import java.io.Reader;
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import junit.framework.TestCase;
-
-import org.eclipse.core.runtime.Path;
-import org.eclipse.mylar.bugzilla.core.internal.ProductParser;
-
-
-/**
- * Tests for parsing Product Page for new Bugzilla reports
- */
-public class BugzillaProductParserTest extends TestCase {
-
- public BugzillaProductParserTest() {
- super();
- }
-
- public BugzillaProductParserTest(String arg0) {
- super(arg0);
- }
-
- public void testFullReportBugNoBug() throws Exception {
-
- File f = FileTool.getFileInPlugin(BugzillaTestPlugin.getDefault(), new Path("TestPages/product-page.html"));
-
- Reader in = new FileReader(f);
-
- List<String> productList = new ArrayList<String>();
- productList = new ProductParser(in).getProducts();
-// printList(productList);
-
- Iterator<String> itr = productList.iterator();
-
- while (itr.hasNext()) {
- assertEquals("AJDT", "AJDT", itr.next());
- assertEquals("AspectJ", "AspectJ", itr.next());
- assertEquals("CDT", "CDT", itr.next());
- assertEquals("CME", "CME", itr.next());
- assertEquals("ECESIS", "ECESIS", itr.next());
- assertEquals("EMF", "EMF", itr.next());
- assertEquals("Equinox", "Equinox", itr.next());
- assertEquals("GEF", "GEF", itr.next());
- assertEquals("GMT", "GMT", itr.next());
- assertEquals("Hyades", "Hyades", itr.next());
- assertEquals("JDT", "JDT", itr.next());
- assertEquals("PDE", "PDE", itr.next());
- assertEquals("Platform", "Platform", itr.next());
- assertEquals("Stellation", "Stellation", itr.next());
- assertEquals("UML2", "UML2", itr.next());
- assertEquals("VE", "VE", itr.next());
- assertEquals("WSVT", "WSVT", itr.next());
- assertEquals("XSD", "XSD", itr.next());
- }
- }
-
-// private void printList(List<String> productList) {
-//
-// Iterator<String> itr = productList.iterator();
-// System.out.println("Product List:");
-// while (itr.hasNext())
-// System.out.println(itr.next());
-// }
-}
diff --git a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaTestPlugin.java b/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaTestPlugin.java
deleted file mode 100644
index 337945802..000000000
--- a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/BugzillaTestPlugin.java
+++ /dev/null
@@ -1,96 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-package org.eclipse.mylar.bugzilla.test;
-
-import org.eclipse.ui.plugin.*;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.osgi.framework.BundleContext;
-import java.util.*;
-
-/**
- * The main plugin class to be used in the desktop.
- */
-public class BugzillaTestPlugin extends AbstractUIPlugin {
- //The shared instance.
- private static BugzillaTestPlugin plugin;
- //Resource bundle.
- private ResourceBundle resourceBundle;
-
- /**
- * The constructor.
- */
- public BugzillaTestPlugin() {
- super();
- plugin = this;
- }
-
- /**
- * This method is called upon plug-in activation
- */
- @Override
- public void start(BundleContext context) throws Exception {
- super.start(context);
- }
-
- /**
- * This method is called when the plug-in is stopped
- */
- @Override
- public void stop(BundleContext context) throws Exception {
- super.stop(context);
- plugin = null;
- resourceBundle = null;
- }
-
- /**
- * Returns the shared instance.
- */
- public static BugzillaTestPlugin getDefault() {
- return plugin;
- }
-
- /**
- * Returns the string from the plugin's resource bundle,
- * or 'key' if not found.
- */
- public static String getResourceString(String key) {
- ResourceBundle bundle = BugzillaTestPlugin.getDefault().getResourceBundle();
- try {
- return (bundle != null) ? bundle.getString(key) : key;
- } catch (MissingResourceException e) {
- return key;
- }
- }
-
- /**
- * Returns the plugin's resource bundle,
- */
- public ResourceBundle getResourceBundle() {
- try {
- if (resourceBundle == null)
- resourceBundle = ResourceBundle.getBundle("org.eclipse.mylar.bugzilla.tests.TestsPluginResources");
- } catch (MissingResourceException x) {
- resourceBundle = null;
- }
- return resourceBundle;
- }
-
- /**
- * Returns an image descriptor for the image file at the given
- * plug-in relative path.
- *
- * @param path the path
- * @return the image descriptor
- */
- public static ImageDescriptor getImageDescriptor(String path) {
- return AbstractUIPlugin.imageDescriptorFromPlugin("org.eclipse.mylar.bugzilla.tests", path);
- }
-}
diff --git a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/FileTool.java b/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/FileTool.java
deleted file mode 100644
index 2f8c66c56..000000000
--- a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/test/FileTool.java
+++ /dev/null
@@ -1,256 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2005 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.mylar.bugzilla.test;
-
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileOutputStream;
-import java.io.FileReader;
-import java.io.FileWriter;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.OutputStream;
-import java.io.Reader;
-import java.io.Writer;
-import java.net.URL;
-import java.util.Enumeration;
-import java.util.zip.ZipEntry;
-import java.util.zip.ZipFile;
-
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.Platform;
-import org.eclipse.core.runtime.Plugin;
-
-
-public class FileTool {
-
- private final static int MAX_RETRY= 5;
-
- /**
- * A buffer.
- */
- private static byte[] buffer = new byte[8192];
-
- /**
- * Unzips the given zip file to the given destination directory
- * extracting only those entries the pass through the given
- * filter.
- *
- * @param zipFile the zip file to unzip
- * @param dstDir the destination directory
- * @throws IOException in case of problem
- */
- public static void unzip(ZipFile zipFile, File dstDir) throws IOException {
- unzip(zipFile, dstDir, dstDir, 0);
- }
-
- private static void unzip(ZipFile zipFile, File rootDstDir, File dstDir, int depth) throws IOException {
-
- Enumeration<? extends ZipEntry> entries = zipFile.entries();
-
- try {
- while(entries.hasMoreElements()){
- ZipEntry entry = entries.nextElement();
- if(entry.isDirectory()){
- continue;
- }
- String entryName = entry.getName();
- File file = new File(dstDir, changeSeparator(entryName, '/', File.separatorChar));
- file.getParentFile().mkdirs();
- InputStream src = null;
- OutputStream dst = null;
- try {
- src = zipFile.getInputStream(entry);
- dst = new FileOutputStream(file);
- transferData(src, dst);
- } finally {
- if(dst != null){
- try {
- dst.close();
- } catch(IOException e){
- // don't worry in the finally
- }
- }
- if(src != null){
- try {
- src.close();
- } catch(IOException e){
- // don't worry in the finally
- }
- }
- }
- }
- } finally {
- try {
- zipFile.close();
- } catch(IOException e){
- // don't worry in the finally
- }
- }
- }
-
- /**
- * Returns the given file path with its separator
- * character changed from the given old separator to the
- * given new separator.
- *
- * @param path a file path
- * @param oldSeparator a path separator character
- * @param newSeparator a path separator character
- * @return the file path with its separator character
- * changed from the given old separator to the given new
- * separator
- */
- public static String changeSeparator(String path, char oldSeparator, char newSeparator){
- return path.replace(oldSeparator, newSeparator);
- }
-
- /**
- * Copies all bytes in the given source file to
- * the given destination file.
- *
- * @param source the given source file
- * @param destination the given destination file
- * @throws IOException in case of error
- */
- public static void transferData(File source, File destination) throws IOException {
- destination.getParentFile().mkdirs();
- InputStream is = null;
- OutputStream os = null;
- try {
- is = new FileInputStream(source);
- os = new FileOutputStream(destination);
- transferData(is, os);
- } finally {
- if(os != null){
- try {
- os.close();
- } catch(IOException e){
- // don't worry in the finally
- }
- }
- if(is != null){
- try {
- is.close();
- } catch(IOException e){
- // don't worry in the finally
- }
- }
- }
- }
-
- /**
- * Copies all bytes in the given source stream to
- * the given destination stream. Neither streams
- * are closed.
- *
- * @param source the given source stream
- * @param destination the given destination stream
- * @throws IOException in case of error
- */
- public static void transferData(InputStream source, OutputStream destination) throws IOException {
- int bytesRead = 0;
- while(bytesRead != -1){
- bytesRead = source.read(buffer, 0, buffer.length);
- if(bytesRead != -1){
- destination.write(buffer, 0, bytesRead);
- }
- }
- }
-
- /**
- * Copies the given source file to the given destination file.
- *
- * @param src the given source file
- * @param dst the given destination file
- * @throws IOException in case of error
- */
- public static void copy(File src, File dst) throws IOException {
- if(src.isDirectory()){
- String[] srcChildren = src.list();
- for(int i = 0; i < srcChildren.length; ++i){
- File srcChild= new File(src, srcChildren[i]);
- File dstChild= new File(dst, srcChildren[i]);
- copy(srcChild, dstChild);
- }
- } else
- transferData(src, dst);
- }
-
- public static File getFileInPlugin(Plugin plugin, IPath path) {
- try {
- URL installURL= plugin.getBundle().getEntry(path.toString());
- URL localURL= Platform.asLocalURL(installURL);
- return new File(localURL.getFile());
- } catch (IOException e) {
- return null;
- }
- }
-
- public static File createTempFileInPlugin(Plugin plugin, IPath path) {
- IPath stateLocation= plugin.getStateLocation();
- stateLocation= stateLocation.append(path);
- return stateLocation.toFile();
- }
-
- public static StringBuffer read(String fileName) throws IOException {
- return read(new FileReader(fileName));
- }
-
- public static StringBuffer read(Reader reader) throws IOException {
- StringBuffer s= new StringBuffer();
- try {
- char[] charBuffer= new char[8196];
- int chars= reader.read(charBuffer);
- while (chars != -1) {
- s.append(charBuffer, 0, chars);
- chars= reader.read(charBuffer);
- }
- } finally {
- try {
- reader.close();
- } catch (IOException e) {
- // don't worry in the finally
- }
- }
- return s;
- }
-
- public static void write(String fileName, StringBuffer content) throws IOException {
- Writer writer= new FileWriter(fileName);
- try {
- writer.write(content.toString());
- } finally {
- try {
- writer.close();
- } catch (IOException e) {
- // don't worry in the finally
- }
- }
- }
-
- public static void delete(File file) {
- if (file.exists()) {
- for (int i= 0; i < MAX_RETRY; i++) {
- if (file.delete())
- i= MAX_RETRY;
- else {
- try {
- Thread.sleep(1000); // sleep a second
- } catch (InterruptedException e) {
- // don't care if the sleep is interrupted
- }
- }
- }
- }
- }
-}
diff --git a/org.eclipse.mylyn.help.ui/.classpath b/org.eclipse.mylyn.help.ui/.classpath
deleted file mode 100644
index 9a0869b45..000000000
--- a/org.eclipse.mylyn.help.ui/.classpath
+++ /dev/null
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
- <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
- <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
- <classpathentry kind="output" path="bin"/>
- <classpathentry kind="src" path="src"/>
-</classpath>
diff --git a/org.eclipse.mylyn.help.ui/.cvsignore b/org.eclipse.mylyn.help.ui/.cvsignore
deleted file mode 100644
index ba077a403..000000000
--- a/org.eclipse.mylyn.help.ui/.cvsignore
+++ /dev/null
@@ -1 +0,0 @@
-bin
diff --git a/org.eclipse.mylyn.help.ui/.project b/org.eclipse.mylyn.help.ui/.project
deleted file mode 100644
index cc9ad6c69..000000000
--- a/org.eclipse.mylyn.help.ui/.project
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.mylar.doc</name>
- <comment></comment>
- <projects>
- </projects>
- <buildSpec>
- <buildCommand>
- <name>org.eclipse.jdt.core.javabuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.pde.ManifestBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.pde.SchemaBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- </buildSpec>
- <natures>
- <nature>org.eclipse.pde.PluginNature</nature>
- <nature>org.eclipse.jdt.core.javanature</nature>
- </natures>
-</projectDescription>
diff --git a/org.eclipse.mylyn.help.ui/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.mylyn.help.ui/.settings/org.eclipse.jdt.core.prefs
deleted file mode 100644
index 0635cc815..000000000
--- a/org.eclipse.mylyn.help.ui/.settings/org.eclipse.jdt.core.prefs
+++ /dev/null
@@ -1,12 +0,0 @@
-#Thu Jun 30 08:33:05 PDT 2005
-eclipse.preferences.version=1
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5
-org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.5
-org.eclipse.jdt.core.compiler.debug.lineNumber=generate
-org.eclipse.jdt.core.compiler.debug.localVariable=generate
-org.eclipse.jdt.core.compiler.debug.sourceFile=generate
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
-org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
-org.eclipse.jdt.core.compiler.source=1.5
diff --git a/org.eclipse.mylyn.help.ui/META-INF/MANIFEST.MF b/org.eclipse.mylyn.help.ui/META-INF/MANIFEST.MF
deleted file mode 100644
index f818c9802..000000000
--- a/org.eclipse.mylyn.help.ui/META-INF/MANIFEST.MF
+++ /dev/null
@@ -1,14 +0,0 @@
-Manifest-Version: 1.0
-Bundle-ManifestVersion: 2
-Bundle-Name: Mylar Documentation Plugin
-Bundle-SymbolicName: org.eclipse.mylar.doc; singleton:=true
-Bundle-Version: 0.2.4
-Bundle-Activator: org.eclipse.mylar.doc.MylarDocPlugin
-Bundle-Localization: plugin
-Require-Bundle: org.eclipse.ui,
- org.eclipse.core.runtime,
- org.eclipse.core.resources
-Eclipse-AutoStart: true
-Bundle-Vendor: University of British Columbia
-Export-Package: org.eclipse.mylar.doc
-Bundle-ClassPath: mylar-doc.jar
diff --git a/org.eclipse.mylyn.help.ui/about.html b/org.eclipse.mylyn.help.ui/about.html
deleted file mode 100644
index 60ca57b4b..000000000
--- a/org.eclipse.mylyn.help.ui/about.html
+++ /dev/null
@@ -1,22 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3c.org/TR/1999/REC-html401-19991224/loose.dtd">
-<!-- saved from url=(0043)http://www.eclipse.org/legal/epl/about.html -->
-<HTML><HEAD><TITLE>About</TITLE>
-<META http-equiv=Content-Type content="text/html; charset=ISO-8859-1">
-<META content="MSHTML 6.00.2900.2627" name=GENERATOR></HEAD>
-<BODY lang=EN-US>
-<H2>About This Content</H2>
-<P>February 24, 2005</P>
-<H3>License</H3>
-<P>The Eclipse Foundation makes available all content in this plug-in
-("Content"). Unless otherwise indicated below, the Content is provided to you
-under the terms and conditions of the Eclipse Public License Version 1.0
-("EPL"). A copy of the EPL is available at <A
-href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</A>.
-For purposes of the EPL, "Program" will mean the Content.</P>
-<P>If you did not receive this Content directly from the Eclipse Foundation, the
-Content is being redistributed by another party ("Redistributor") and different
-terms and conditions may apply to your use of any object code in the Content.
-Check the Redistributor's license that was provided with the Content. If no such
-license exists, contact the Redistributor. Unless otherwise indicated below, the
-terms and conditions of the EPL still apply to any source code in the
-Content.</P></BODY></HTML>
diff --git a/org.eclipse.mylyn.help.ui/build.properties b/org.eclipse.mylyn.help.ui/build.properties
deleted file mode 100644
index 1ff373b88..000000000
--- a/org.eclipse.mylyn.help.ui/build.properties
+++ /dev/null
@@ -1,22 +0,0 @@
-###############################################################################
-# Copyright (c) 2004 - 2005 University Of British Columbia and others.
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Eclipse Public License v1.0
-# which accompanies this distribution, and is available at
-# http://www.eclipse.org/legal/epl-v10.html
-#
-# Contributors:
-# University Of British Columbia - initial API and implementation
-###############################################################################
-source.mylar-doc.jar = src/
-output.mylar-doc.jar = bin/
-bin.includes = plugin.xml,\
- mylar-doc.jar,\
- META-INF/,\
- toc.xml,\
- about.html
-src.includes = META-INF/,\
- plugin.xml,\
- src/,\
- toc.xml,\
- about.html
diff --git a/org.eclipse.mylyn.help.ui/plugin.xml b/org.eclipse.mylyn.help.ui/plugin.xml
deleted file mode 100644
index 6bc9f066d..000000000
--- a/org.eclipse.mylyn.help.ui/plugin.xml
+++ /dev/null
@@ -1,15 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<?eclipse version="3.0"?>
-<?eclipse version="3.0"?>
-<plugin>
-
- <extension
- id="org.eclipse.mylar.helpDocs"
- name="Mylar Help"
- point="org.eclipse.help.toc">
- <toc
- file="toc.xml"
- primary="true">
- </toc>
- </extension>
-</plugin>
diff --git a/org.eclipse.mylyn.help.ui/src/org/eclipse/mylyn/doc/MylarDocPlugin.java b/org.eclipse.mylyn.help.ui/src/org/eclipse/mylyn/doc/MylarDocPlugin.java
deleted file mode 100644
index 9b47f20d3..000000000
--- a/org.eclipse.mylyn.help.ui/src/org/eclipse/mylyn/doc/MylarDocPlugin.java
+++ /dev/null
@@ -1,66 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-package org.eclipse.mylar.doc;
-
-import org.eclipse.ui.plugin.*;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.osgi.framework.BundleContext;
-
-/**
- * The main plugin class to be used in the desktop.
- */
-public class MylarDocPlugin extends AbstractUIPlugin {
- //The shared instance.
- private static MylarDocPlugin plugin;
-
- /**
- * The constructor.
- */
- public MylarDocPlugin() {
- super();
- plugin = this;
- }
-
- /**
- * This method is called upon plug-in activation
- */
- @Override
- public void start(BundleContext context) throws Exception {
- super.start(context);
- }
-
- /**
- * This method is called when the plug-in is stopped
- */
- @Override
- public void stop(BundleContext context) throws Exception {
- super.stop(context);
- plugin = null;
- }
-
- /**
- * Returns the shared instance.
- */
- public static MylarDocPlugin getDefault() {
- return plugin;
- }
-
- /**
- * Returns an image descriptor for the image file at the given
- * plug-in relative path.
- *
- * @param path the path
- * @return the image descriptor
- */
- public static ImageDescriptor getImageDescriptor(String path) {
- return AbstractUIPlugin.imageDescriptorFromPlugin("org.eclipse.mylar.doc", path);
- }
-}
diff --git a/org.eclipse.mylyn.help.ui/toc.xml b/org.eclipse.mylyn.help.ui/toc.xml
deleted file mode 100644
index 7f0d028c1..000000000
--- a/org.eclipse.mylyn.help.ui/toc.xml
+++ /dev/null
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<?NLS TYPE="org.eclipse.help.toc"?>
-
-<toc label="Mylar" topic="docs/html/book.html">
-</toc>
diff --git a/org.eclipse.mylyn.tasks.tests/.classpath b/org.eclipse.mylyn.tasks.tests/.classpath
deleted file mode 100644
index a5424b27d..000000000
--- a/org.eclipse.mylyn.tasks.tests/.classpath
+++ /dev/null
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
- <classpathentry kind="src" path="src"/>
- <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins">
- <accessrules>
- <accessrule kind="accessible" pattern="**/internal/**"/>
- </accessrules>
- </classpathentry>
- <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
- <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/org.eclipse.mylyn.tasks.tests/.cvsignore b/org.eclipse.mylyn.tasks.tests/.cvsignore
deleted file mode 100644
index ba077a403..000000000
--- a/org.eclipse.mylyn.tasks.tests/.cvsignore
+++ /dev/null
@@ -1 +0,0 @@
-bin
diff --git a/org.eclipse.mylyn.tasks.tests/.project b/org.eclipse.mylyn.tasks.tests/.project
deleted file mode 100644
index 7bbb3bbd6..000000000
--- a/org.eclipse.mylyn.tasks.tests/.project
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.mylar.tasks.tests</name>
- <comment></comment>
- <projects>
- </projects>
- <buildSpec>
- <buildCommand>
- <name>org.eclipse.jdt.core.javabuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.pde.ManifestBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.pde.SchemaBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- </buildSpec>
- <natures>
- <nature>org.eclipse.pde.PluginNature</nature>
- <nature>org.eclipse.jdt.core.javanature</nature>
- </natures>
-</projectDescription>
diff --git a/org.eclipse.mylyn.tasks.tests/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.mylyn.tasks.tests/.settings/org.eclipse.jdt.core.prefs
deleted file mode 100644
index 7ca1a203c..000000000
--- a/org.eclipse.mylyn.tasks.tests/.settings/org.eclipse.jdt.core.prefs
+++ /dev/null
@@ -1,12 +0,0 @@
-#Thu Jun 30 08:33:56 PDT 2005
-eclipse.preferences.version=1
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5
-org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.5
-org.eclipse.jdt.core.compiler.debug.lineNumber=generate
-org.eclipse.jdt.core.compiler.debug.localVariable=generate
-org.eclipse.jdt.core.compiler.debug.sourceFile=generate
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
-org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
-org.eclipse.jdt.core.compiler.source=1.5
diff --git a/org.eclipse.mylyn.tasks.tests/META-INF/MANIFEST.MF b/org.eclipse.mylyn.tasks.tests/META-INF/MANIFEST.MF
deleted file mode 100644
index d575b7dde..000000000
--- a/org.eclipse.mylyn.tasks.tests/META-INF/MANIFEST.MF
+++ /dev/null
@@ -1,21 +0,0 @@
-Manifest-Version: 1.0
-Bundle-ManifestVersion: 2
-Bundle-Name: Mylar Tasklist Tests Plug-in
-Bundle-SymbolicName: org.eclipse.mylar.tasks.tests
-Bundle-Version: 1.0.0
-Bundle-Activator: org.eclipse.mylar.tasks.tests.MylarTasksTestsPlugin
-Bundle-Vendor: University of British Columbia
-Bundle-Localization: plugin
-Require-Bundle: org.eclipse.core.runtime,
- org.junit,
- org.eclipse.mylar.core,
- org.eclipse.mylar.core.tests,
- org.eclipse.mylar.tasks,
- org.eclipse.mylar.bugzilla,
- org.eclipse.jdt.core,
- org.eclipse.core.resources,
- org.eclipse.ui
-Eclipse-AutoStart: true
-Bundle-ClassPath: mylar-tasklist-tests.jar
-Export-Package: org.eclipse.mylar.tasks.bugzilla.tests,
- org.eclipse.mylar.tasks.tests
diff --git a/org.eclipse.mylyn.tasks.tests/about.html b/org.eclipse.mylyn.tasks.tests/about.html
deleted file mode 100644
index 60ca57b4b..000000000
--- a/org.eclipse.mylyn.tasks.tests/about.html
+++ /dev/null
@@ -1,22 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3c.org/TR/1999/REC-html401-19991224/loose.dtd">
-<!-- saved from url=(0043)http://www.eclipse.org/legal/epl/about.html -->
-<HTML><HEAD><TITLE>About</TITLE>
-<META http-equiv=Content-Type content="text/html; charset=ISO-8859-1">
-<META content="MSHTML 6.00.2900.2627" name=GENERATOR></HEAD>
-<BODY lang=EN-US>
-<H2>About This Content</H2>
-<P>February 24, 2005</P>
-<H3>License</H3>
-<P>The Eclipse Foundation makes available all content in this plug-in
-("Content"). Unless otherwise indicated below, the Content is provided to you
-under the terms and conditions of the Eclipse Public License Version 1.0
-("EPL"). A copy of the EPL is available at <A
-href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</A>.
-For purposes of the EPL, "Program" will mean the Content.</P>
-<P>If you did not receive this Content directly from the Eclipse Foundation, the
-Content is being redistributed by another party ("Redistributor") and different
-terms and conditions may apply to your use of any object code in the Content.
-Check the Redistributor's license that was provided with the Content. If no such
-license exists, contact the Redistributor. Unless otherwise indicated below, the
-terms and conditions of the EPL still apply to any source code in the
-Content.</P></BODY></HTML>
diff --git a/org.eclipse.mylyn.tasks.tests/build.properties b/org.eclipse.mylyn.tasks.tests/build.properties
deleted file mode 100644
index 7ca24197e..000000000
--- a/org.eclipse.mylyn.tasks.tests/build.properties
+++ /dev/null
@@ -1,15 +0,0 @@
-###############################################################################
-# Copyright (c) 2004 - 2005 University Of British Columbia and others.
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Eclipse Public License v1.0
-# which accompanies this distribution, and is available at
-# http://www.eclipse.org/legal/epl-v10.html
-#
-# Contributors:
-# University Of British Columbia - initial API and implementation
-###############################################################################
-bin.includes = META-INF/,\
- mylar-tasklist-tests.jar
-jars.compile.order = mylar-tasklist-tests.jar
-source.mylar-tasklist-tests.jar = src/
-output.mylar-tasklist-tests.jar = bin/
diff --git a/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/bugzilla/tests/BugzillaSearchPluginTest.java b/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/bugzilla/tests/BugzillaSearchPluginTest.java
deleted file mode 100644
index 566486648..000000000
--- a/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/bugzilla/tests/BugzillaSearchPluginTest.java
+++ /dev/null
@@ -1,328 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on Nov 19, 2004
- */
-package org.eclipse.mylar.tasks.bugzilla.tests;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import junit.framework.TestCase;
-
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.IType;
-import org.eclipse.mylar.core.search.IActiveSearchListener;
-import org.eclipse.mylar.core.tests.support.WorkspaceSetupHelper;
-import org.eclipse.mylar.core.tests.support.search.SearchPluginTestHelper;
-import org.eclipse.mylar.tasks.BugzillaTask;
-import org.eclipse.mylar.tasks.TaskCategory;
-import org.eclipse.mylar.tasks.MylarTasksPlugin;
-import org.eclipse.mylar.tasks.TaskList;
-import org.eclipse.mylar.tasks.BugzillaTask.BugTaskState;
-import org.eclipse.mylar.tasks.bugzilla.BugzillaReportNode;
-import org.eclipse.mylar.tasks.bugzilla.search.BugzillaMylarSearch;
-
-/*TEST CASES TO HANDLE
- * 1. what is here
- * 2. different scopes ( local and remote )
- * 3. no bugs
- * 4. offline bugs
- *
- * DEGREE OF SEPARATIONS
- * 1 Local bug, qualified reference
- * 2 local bug, unqualified reference
- * 3 remote bug, qualified reference
- * 4 remote bug, unqualified reference
- * 5 NONE
- */
-
-/**
- * Test the bugzilla search functionality of the bridge
- * @author Shawn Minto
- */
-public class BugzillaSearchPluginTest extends TestCase{
-
- //SHAWNTODO Add tests for the different types of searches (local qual, local unqual, fully qual, unqual) and mock up a bugs db for testing
-
- /** The expected number of results when searching for astNode */
-// SHAWNTODO add back in when we have a test server mocked up
-// private static final int NUM_AST_RESULTS = 302;
-//
-// private static final int NUM_AST_SETSOURCERANGE_RESULTS = 15;
-
- /** list to add collectors to when notified */
- private List<List<?>> lists = new ArrayList<List<?>>();
-
- private IType astNodeType;
-
- @Override
- protected void setUp() throws Exception {
- WorkspaceSetupHelper.setupWorkspace();
- IJavaProject jp = WorkspaceSetupHelper.getJdtCoreDomProject();
- astNodeType = WorkspaceSetupHelper.getType(jp, "org.eclipse.jdt.core.dom.ASTNode");
- }
-
- @Override
- protected void tearDown() throws Exception {
- WorkspaceSetupHelper.clearDoiModel();
- }
-
- /**
- * Test adding and removing ISearchCompletedListeners
- */
- public void testSearchCompletedListenerAddAndRemove(){
- lists.clear();
-
- // create 2 listeners
- IActiveSearchListener l1 =new IActiveSearchListener() {
- private boolean gathered = false;
-
- public void searchCompleted(List<?> l)
- {
- lists.add(l);
- gathered = true;
- }
-
- public boolean resultsGathered() {
- return gathered;
- }
- };
- IActiveSearchListener l2 =new IActiveSearchListener() {
- private boolean gathered = false;
-
- public void searchCompleted(List<?> l)
- {
- lists.add(l);
- gathered = true;
- }
-
- public boolean resultsGathered() {
- return gathered;
- }
- };
-
- BugzillaMylarSearch s = new BugzillaMylarSearch(BugzillaMylarSearch.UNQUAL, astNodeType);
-
- // add the first listener
- s.addListener(l1);
- // remove the first listener
- s.removeListener(l1);
-
- // perform the search
- SearchPluginTestHelper.search(s, l2);
-
- // make sure that only the second listener added has any results left
- assertTrue("listener was not removed", lists.size() >= 1 && !l1.resultsGathered());
- assertTrue("listener was not added", lists.size() == 1);
-
- // display the time it took for the search
-// System.err.println("Search Took About " + time + " seconds");
- MylarTasksPlugin.getBridge().removeFromLandmarksHash(astNodeType);
- }
-
- /**
- * Tests that the bridge gets the right data for us
- * This test is wierd because it waits on results.
- */
- public void testBridge() {
- lists.clear();
- BugzillaMylarSearch s = new BugzillaMylarSearch(BugzillaMylarSearch.UNQUAL, astNodeType);
-
- IActiveSearchListener l = new IActiveSearchListener() {
- private boolean gathered = false;
-
- public void searchCompleted(List<?> results)
- {
- lists.add(results);
- gathered = true;
- }
-
- public boolean resultsGathered() {
- return gathered;
- }
- };
-
- // perform the search
- SearchPluginTestHelper.search(s, l);
-
- // make sure we got the right number of bugs back
- assertTrue("No collector returned", lists.size() != 0);
- List<?> c = lists.get(0);
- assertTrue("Results not the right size", c.size() > 0); // TODO should be assertEquals on expected size
-
- // display the time it took for the search and the results returned
-// System.err.println("Search Took About " + time + " seconds");
-// System.err.println(c);
- MylarTasksPlugin.getBridge().removeFromLandmarksHash(astNodeType);
-
- }
-
-
- /**
- * Tests that the bridge saves the results of a search so that it
- * can be used later
- */
- public void testSaveResults() {
- lists.clear();
- BugzillaMylarSearch s = new BugzillaMylarSearch(BugzillaMylarSearch.UNQUAL, astNodeType);
-
- IActiveSearchListener l = new IActiveSearchListener() {
- private boolean gathered = false;
-
- public void searchCompleted(List<?> results)
- {
- lists.add(results);
- gathered = true;
- }
-
- public boolean resultsGathered() {
- return gathered;
- }
- };
-
- // perform the search
- SearchPluginTestHelper.search(s, l);
-// System.err.println("Search Took About " + time + " seconds");
-
- // do an inital search
- assertTrue("No collectors returned", lists.size() != 0);
- List<?> c = lists.get(0);
- assertTrue("Results not the right size", c.size() > 0); // TODO should be assertEquals on expected size
-
- // check that the search has been saved
- List<BugzillaReportNode> saved = MylarTasksPlugin.getBridge().getFromLandmarksHash(astNodeType, BugzillaMylarSearch.UNQUAL);
- assertTrue("Results not cached", saved != null);
- assertTrue("Results not the right size", saved.size() > 0); // TODO should be assertEquals on expected size
-
- assertTrue(c.containsAll(saved) && saved.containsAll(c));
- MylarTasksPlugin.getBridge().removeFromLandmarksHash(astNodeType);
- }
-
- public void testLocalBugUnqual() throws InterruptedException {
- lists.clear();
-
- String bugPrefix = "Bugzilla-";
-
- TaskList t = MylarTasksPlugin.getTaskListManager().createNewTaskList();
- MylarTasksPlugin.getTaskListManager().setTaskList(t);
- TaskCategory cat = new TaskCategory("Testing Category");
- t.addCategory(cat);
- BugzillaTask bugTask1 = new BugzillaTask(bugPrefix +94185, "<bugzilla info>");
- cat.addTask(bugTask1);
- while(bugTask1.getState() != BugTaskState.FREE){
- Thread.sleep(500);
- }
- BugzillaTask bugTask2 = new BugzillaTask(bugPrefix + 3692, "<bugzilla info>");
- cat.addTask(bugTask2);
- while(bugTask2.getState() != BugTaskState.FREE){
- Thread.sleep(500);
- }
- BugzillaTask bugTask3 = new BugzillaTask(bugPrefix + 3693, "<bugzilla info>");
- cat.addTask(bugTask3);
- while(bugTask3.getState() != BugTaskState.FREE){
- Thread.sleep(500);
- }
-
- BugzillaTask bugTask4 = new BugzillaTask(bugPrefix + 9583, "<bugzilla info>");
- cat.addTask(bugTask4);
- while(bugTask4.getState() != BugTaskState.FREE){
- Thread.sleep(500);
- }
-
- BugzillaMylarSearch s = new BugzillaMylarSearch(BugzillaMylarSearch.LOCAL_UNQUAL, astNodeType);
-
- IActiveSearchListener l = new IActiveSearchListener() {
- private boolean gathered = false;
-
- public void searchCompleted(List<?> results)
- {
- lists.add(results);
- gathered = true;
- }
-
- public boolean resultsGathered() {
- return gathered;
- }
- };
-
- // perform the search
- SearchPluginTestHelper.search(s, l);
-// System.err.println("Search Took About " + time + " seconds");
-
- // do an inital search
- assertTrue("No collectors returned", lists.size() != 0);
- List<?> c = lists.get(0);
- assertEquals("Results not the right size", 3, c.size());
-
- MylarTasksPlugin.getBridge().removeFromLandmarksHash(astNodeType);
- MylarTasksPlugin.getTaskListManager().getTaskList().deleteCategory(cat);
- }
-
- //TODO need to test a bug that wraps...should fail since we can only search on a single line
- public void testLocalBugFullyQual() throws InterruptedException{
- lists.clear();
-
- String bugPrefix = "Bugzilla-";
-
-
- TaskList t = MylarTasksPlugin.getTaskListManager().createNewTaskList();
- MylarTasksPlugin.getTaskListManager().setTaskList(t);
- TaskCategory cat = new TaskCategory("Testing Category");
- t.addCategory(cat);
- BugzillaTask bugTask1 = new BugzillaTask(bugPrefix + 94185, "<bugzilla info>");
- cat.addTask(bugTask1);
- while(bugTask1.getState() != BugTaskState.FREE){
- Thread.sleep(500);
- }
-
- BugzillaTask bugTask2 = new BugzillaTask(bugPrefix + 9583, "<bugzilla info>");
- cat.addTask(bugTask2);
- while(bugTask2.getState() != BugTaskState.FREE){
- Thread.sleep(500);
- }
- BugzillaTask bugTask3 = new BugzillaTask(bugPrefix + 3693, "<bugzilla info>");
- cat.addTask(bugTask3);
- while(bugTask3.getState() != BugTaskState.FREE){
- Thread.sleep(500);
- }
-
-
- BugzillaMylarSearch s = new BugzillaMylarSearch(BugzillaMylarSearch.LOCAL_QUAL, astNodeType);
-
- IActiveSearchListener l = new IActiveSearchListener() {
- private boolean gathered = false;
-
- public void searchCompleted(List<?> results)
- {
- lists.add(results);
- gathered = true;
- }
-
- public boolean resultsGathered() {
- return gathered;
- }
- };
-
- // perform the search
- SearchPluginTestHelper.search(s, l);
-// System.err.println("Search Took About " + time + " seconds");
-
- // do an inital search
- assertTrue("No collectors returned", lists.size() != 0);
- List<?> c = lists.get(0);
- assertEquals("Results not the right size", 1, c.size());
-
- MylarTasksPlugin.getBridge().removeFromLandmarksHash(astNodeType);
- MylarTasksPlugin.getTaskListManager().getTaskList().deleteCategory(cat);
- }
-
-}
diff --git a/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/bugzilla/tests/BugzillaStackTraceTest.java b/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/bugzilla/tests/BugzillaStackTraceTest.java
deleted file mode 100644
index 1ca6993e0..000000000
--- a/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/bugzilla/tests/BugzillaStackTraceTest.java
+++ /dev/null
@@ -1,170 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-////Created on Oct 12, 2004
-package org.eclipse.mylar.tasks.bugzilla.tests;
-
-import java.io.File;
-import java.io.FileReader;
-import java.io.Reader;
-import java.util.ArrayList;
-import java.util.List;
-
-import junit.framework.TestCase;
-
-import org.eclipse.core.runtime.Path;
-import org.eclipse.mylar.bugzilla.core.internal.BugParser;
-import org.eclipse.mylar.bugzilla.search.BugzillaSearchHit;
-import org.eclipse.mylar.core.tests.MylarCoreTestsPlugin;
-import org.eclipse.mylar.core.tests.support.FileTool;
-import org.eclipse.mylar.tasks.bugzilla.BugzillaReportNode;
-import org.eclipse.mylar.tasks.bugzilla.StackTrace;
-import org.eclipse.mylar.tasks.bugzilla.search.BugzillaMylarSearchOperation;
-
-
-/**
- * Class to test the Bridge methods that do not require server queries
- * @author Shawn Minto
- */
-public class BugzillaStackTraceTest extends TestCase {
-
- private static final String TEST_FILE_LOC = "testdata/BugzillaBridgeData/";
-
- private static final String BUGZILLA_SERVER_NAME = "https://bugs.eclipse.org/bugs";
-
- /**
- * Test that the regular expression escaping mechanism works properly
- */
- public void testREGEX(){
- String r = ".*+(){}[]^$|?/\\";
- String r2 = StackTrace.escapeForRegex(r);
- String ans = "\\.\\*\\+\\(\\)\\{\\}\\[\\]\\^\\$\\|\\?\\/\\\\";
- String msg = "Regular Expression matching wrong:\nwas: " + r2 + "\nshould be:" + ans;
- assertTrue(msg, r2.equals(ans));
- }
-
- /**
- * Test parsing the bug for multiple stacks in in
- */
- public void testMultipleStacksDiffComments(){
- // BUG 4862 - 2 stack traces - 1 in description, 1 in comment - text before and after
- performParse(4862, "4862.html", 2, false);
-
- }
-
- /**
- * Test parsing the bug for a single stack in the description with some
- * text before it
- */
- public void testSingleStackCodeBeforeInDescription(){
-
- // BUG 76388 - 1 stack trace - description - text before and formatted ugly
- performParse(76388, "76388.html", 1, false);
- }
-
- /**
- * Test parsing the bug for a single stack trace in the description with
- * text before and after it
- */
- public void testSingleStackCodeBeforeAndAfterInDescription(){
-
- // BUG 76146 - 1 stack trace - description - text before and code after
- performParse(76146, "76146.html", 1, false);
- }
-
- /**
- * Test parsing a bug that has 1 stack trace in the description with no extra
- * text, but has lines in it that span 3 lines
- */
- public void testSingleStackPoorFormatInDescription(){
- // BUG 67395 - 1 stack trace - description - no extra text, 1 at line spans 3 lines
- performParse(67395, "67395.html", 1, false);
- }
-
- /**
- * Test parsing a bug with no stack traces and no qualified exception names
- */
- public void testNoStackNoQualified(){
- // BUG 4548 - no stack traces, no qualified reference to an exception
- performParse(4548, "4548.html", 0, false);
- }
-
- /**
- * Test parsing a bug with no stack traces, but a qualified reference to
- * an exception
- */
- public void testNoStackQual(){
- // BUG 1 - no stack traces, qualified reference to exception - made up bug
- performParse(1, "1.html", 0, false);
- }
-
-
- /**
- * Test parsing of a bug with 1 stack trace and multiple qualified references
- */
- public void testSingleStackQual(){
- // BUG 2 - 1 stack trace- 2 qual ref, stack trace, 1 qual ref - made up bug
- performParse(2, "2.html", 1, false);
- }
-
- /**
- * Test parsing of a bug with many stacks traces in a single comment
- */
- public void testMultipleStackSingleComment(){
- // BUG 40152 - 1 stack trace- 2 qual ref, stack trace, 1 qual ref - made up bug
- performParse(40152, "40152.html", 33, false);
- }
-
- /**
- * Print out the stack traces
- * @param l List of stack traces
- */
- private void printStackTraces(List<StackTrace> l){
- System.out.println("\n\n");
- for(int i = 0; i < l.size(); i++){
- StackTrace trace = l.get(i);
- System.out.println("*****************?????????????????*****************\n");
- System.out.println("OFFSET: " + trace.getOffset() + " LENGTH: " + trace.getLength());
- System.out.println(trace.getStackTrace());
- System.out.println("*****************?????????????????*****************\n\n");
- }
- }
-
- private void performParse(int bugNumber, String bugFileName, int numTracesExpected, boolean printStackTraces){
-
- BugzillaSearchHit hit = new BugzillaSearchHit(bugNumber,"","","","","","","","", "<TEST-SERVER>"); // stack trace in desc and com
-
- // create a new doi info
- BugzillaReportNode doi = new BugzillaReportNode(0, hit, false);
- try {
-
- // read the bug in from a file
- File f = FileTool.getFileInPlugin(MylarCoreTestsPlugin.getDefault(), new Path(TEST_FILE_LOC+bugFileName)); // used if run as a plugin test
-// File f = new File(TEST_FILE_LOC+bugFileName); // used if run as a standalone test
- Reader reader = new FileReader(f);
- doi.setBug(BugParser.parseBug(reader, hit.getId(), BUGZILLA_SERVER_NAME, true, null, null));
- reader.close();
- } catch (Exception e) {
- e.printStackTrace();
- }
-
- // do a second pass parse on the bug
- List<BugzillaReportNode> l = new ArrayList<BugzillaReportNode>();
- l.add(doi);
- BugzillaMylarSearchOperation.secondPassBugzillaParser(l);
-
- // make sure that we received the right number of stack traces back
-// System.out.println("*** BUG " + hit.getId() + " ***");
-// System.out.println("NumStackTraces = " + doi.getStackTraces().size());
- assertEquals("Wrong Number stack traces", numTracesExpected, doi.getStackTraces().size());
- if(printStackTraces)
- printStackTraces(doi.getStackTraces());
- }
-}
diff --git a/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/bugzilla/tests/MylarBugzillaTestsPlugin.java b/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/bugzilla/tests/MylarBugzillaTestsPlugin.java
deleted file mode 100644
index 87a99779a..000000000
--- a/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/bugzilla/tests/MylarBugzillaTestsPlugin.java
+++ /dev/null
@@ -1,49 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-package org.eclipse.mylar.tasks.bugzilla.tests;
-
-import org.eclipse.core.runtime.Plugin;
-import org.osgi.framework.BundleContext;
-
-/**
- * The main plugin class to be used in the desktop.
- */
-public class MylarBugzillaTestsPlugin extends Plugin {
- //The shared instance.
- private static MylarBugzillaTestsPlugin plugin;
-
- /**
- * The constructor.
- */
- public MylarBugzillaTestsPlugin() {
- super();
- plugin = this;
- }
-
- @Override
- public void start(BundleContext context) throws Exception {
- super.start(context);
- }
-
- @Override
- public void stop(BundleContext context) throws Exception {
- super.stop(context);
- plugin = null;
- }
-
- /**
- * Returns the shared instance.
- */
- public static MylarBugzillaTestsPlugin getDefault() {
- return plugin;
- }
-
-}
diff --git a/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/Job.java b/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/Job.java
deleted file mode 100644
index 62d95fcce..000000000
--- a/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/Job.java
+++ /dev/null
@@ -1,87 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-package org.eclipse.mylar.tasks.tests;
-
-public class Job {
- private String company;
- private String position;
- private int salary;
- private String email;
- private String supervisor;
-
- public static String foo = "TESTING STATIC FOR XSTREAM";
-
- public Job() {
- this.company = "Foo";
- this.position = "slave";
- this.salary = 100;
- this.email = "a@bc.com";
- //this.supervisor = "bill gates";
- }
-
- public Job(String comp, String pos, int salary, String email, String supervisor) {
- this.company = comp;
- this.position = pos;
- this.salary = salary;
- this.email = email;
- this.supervisor = supervisor;
- }
-
- public boolean equals(Job j) {
- boolean result = true;
- result = result && j.company == this.company;
- result = result && j.position == this.position;
- result = result && j.salary == this.salary;
- result = result && j.email == this.email;
- result = result && j.supervisor == this.supervisor;
- return result;
- }
-
- public String getCompany() {
- return company;
- }
-
- public void setCompany(String company) {
- this.company = company;
- }
-
- public String getEmail() {
- return email;
- }
-
- public void setEmail(String email) {
- this.email = email;
- }
-
- public String getPosition() {
- return position;
- }
-
- public void setPosition(String position) {
- this.position = position;
- }
-
- public int getSalary() {
- return salary;
- }
-
- public void setSalary(int salary) {
- this.salary = salary;
- }
-
- public String getSupervisor() {
- return supervisor;
- }
-
- public void setSupervisor(String supervisor) {
- this.supervisor = supervisor;
- }
-}
diff --git a/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/MylarTasksTestsPlugin.java b/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/MylarTasksTestsPlugin.java
deleted file mode 100644
index 7d420e1fd..000000000
--- a/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/MylarTasksTestsPlugin.java
+++ /dev/null
@@ -1,49 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-package org.eclipse.mylar.tasks.tests;
-
-import org.eclipse.core.runtime.Plugin;
-import org.osgi.framework.BundleContext;
-
-/**
- * The main plugin class to be used in the desktop.
- */
-public class MylarTasksTestsPlugin extends Plugin {
- //The shared instance.
- private static MylarTasksTestsPlugin plugin;
-
- /**
- * The constructor.
- */
- public MylarTasksTestsPlugin() {
- super();
- plugin = this;
- }
-
- @Override
- public void start(BundleContext context) throws Exception {
- super.start(context);
- }
-
- @Override
- public void stop(BundleContext context) throws Exception {
- super.stop(context);
- plugin = null;
- }
-
- /**
- * Returns the shared instance.
- */
- public static MylarTasksTestsPlugin getDefault() {
- return plugin;
- }
-
-}
diff --git a/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/People.java b/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/People.java
deleted file mode 100644
index 2e88dcca4..000000000
--- a/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/People.java
+++ /dev/null
@@ -1,67 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-package org.eclipse.mylar.tasks.tests;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-
-public class People {
- private List<Person> list = new ArrayList<Person>();
-
- public People() {
- // don't need to do any initialization
- }
-
- public void createDefault() {
- Person p = new Person("Ken Sueda", "ksueda@hotmail.com", "123-4567", 22, 1);
- Job j = new Job("UBCCS", "developer", 1000, "ksueda@cs.ubc.ca", "foo");
- p.setJob(j);
- list.add(p);
-
- p = new Person("Shawn Minto", "minto@hotmail.com", "798-1234", 23, 2);
- j = new Job("UBCCS", "grad student", 3000, "minto@cs.ubc.ca", "foo");
- p.setJob(j);
- list.add(p);
-
-
- p = new Person("Mik Kersten", "kersten@hotmail.com", "456-7891", 24, 3);
- j = new Job("UBCCS", "PhD", 1000000, "kersten@cs.ubc.ca", "foo");
- p.setJob(j);
- list.add(p);
-
- p = new Person("Gail Murphy", "murphy@hotmail.com", "987-6543", 25, 4);
- j = new Job("UBCCS", "Professor", 100000000, "", "");
- p.setJob(j);
- list.add(p);
- }
-
- public boolean equals(People people) {
- boolean result = true;
- if (list.size() == people.list.size()) {
- Iterator<Person> itr = list.iterator();
- Iterator<Person> itr2 = people.list.iterator();
-
- while(itr.hasNext()) {
- Person p = itr.next();
- Person p2 = itr2.next();
- result = result && p.equals(p2);
- if (!result) {
- break;
- }
- }
- } else {
- result = false;
- }
- return result;
- }
-}
diff --git a/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/Person.java b/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/Person.java
deleted file mode 100644
index b4064f1b1..000000000
--- a/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/Person.java
+++ /dev/null
@@ -1,106 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-package org.eclipse.mylar.tasks.tests;
-
-import java.util.ArrayList;
-import java.util.List;
-
-public class Person {
- private String name;
- private String emailAddress;
- private String phoneNumber;
- private int age;
- private int id;
- private Job job;
-
- private List<Person> list = new ArrayList<Person>();
-
- public Person() {
- name = "Ken Sueda";
- id = 1;
- age = 22;
- emailAddress = "ksueda@hotmail.com";
- phoneNumber = "123-4567";
- job = null;
- }
-
- public Person(String name, String email, String phone, int age, int id) {
- this.name = name;
- this.emailAddress = email;
- this.phoneNumber = phone;
- this.age = age;
- this.id = id;
- this.job = null;
- }
-
- public void add(Person p) {
- list.add(p);
- }
-
- public boolean equals(Person p) {
- boolean result = true;
- result = result && p.name == this.name;
- result = result && p.emailAddress == this.emailAddress;
- result = result && p.phoneNumber == this.phoneNumber;
- result = result && p.age == this.age;
- result = result && p.id == this.id;
- result = result && p.job.equals(this.job);
- return result;
- }
-
- public int getAge() {
- return age;
- }
-
- public void setAge(int age) {
- this.age = age;
- }
-
- public int getId() {
- return id;
- }
-
- public void setId(int id) {
- this.id = id;
- }
-
- public String getName() {
- return name;
- }
-
- public void setName(String name) {
- this.name = name;
- }
-
- public String getEmailAddress() {
- return emailAddress;
- }
-
- public void setEmailAddress(String emailAddress) {
- this.emailAddress = emailAddress;
- }
-
- public String getPhoneNumber() {
- return phoneNumber;
- }
-
- public void setPhoneNumber(String phoneNumber) {
- this.phoneNumber = phoneNumber;
- }
-
- public Job getJob() {
- return job;
- }
-
- public void setJob(Job job) {
- this.job = job;
- }
-}
diff --git a/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/TaskListManagerTest.java b/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/TaskListManagerTest.java
deleted file mode 100644
index 7d5babeaa..000000000
--- a/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/TaskListManagerTest.java
+++ /dev/null
@@ -1,93 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on Dec 21, 2004
- */
-package org.eclipse.mylar.tasks.tests;
-
-import java.util.List;
-import java.io.File;
-
-import junit.framework.TestCase;
-
-import org.eclipse.mylar.tasks.TaskCategory;
-import org.eclipse.mylar.tasks.ITask;
-import org.eclipse.mylar.tasks.MylarTasksPlugin;
-import org.eclipse.mylar.tasks.Task;
-import org.eclipse.mylar.tasks.TaskList;
-import org.eclipse.mylar.tasks.TaskListManager;
-
-/**
- * @author Mik Kersten
- */
-public class TaskListManagerTest extends TestCase {
-
- public void testCreationAndExternalization() {
- File file = new File("foo" + MylarTasksPlugin.FILE_EXTENSION);
- file.deleteOnExit();
- TaskListManager manager = new TaskListManager(file);
-
- TaskList tlist = manager.getTaskList();
- Task task1 = new Task(MylarTasksPlugin.getTaskListManager().genUniqueTaskId(), "task 1");
- tlist.addRootTask(task1);
- Task sub1 = new Task(MylarTasksPlugin.getTaskListManager().genUniqueTaskId(), "sub 1");
- task1.addSubTask(sub1);
- sub1.setParent(task1);
- Task task2 = new Task(MylarTasksPlugin.getTaskListManager().genUniqueTaskId(), "task 2");
- tlist.addRootTask(task2);
-
- TaskCategory cat1 = new TaskCategory("Category 1");
- tlist.addCategory(cat1);
- Task task3 = new Task(MylarTasksPlugin.getTaskListManager().genUniqueTaskId(), "task 3");
- cat1.addTask(task3);
- Task sub2 = new Task(MylarTasksPlugin.getTaskListManager().genUniqueTaskId(), "sub 2");
- task3.addSubTask(sub2);
- sub2.setParent(task3);
- Task task4 = new Task(MylarTasksPlugin.getTaskListManager().genUniqueTaskId(), "task 4");
- cat1.addTask(task4);
-
- TaskCategory cat2 = new TaskCategory("Category 2");
- tlist.addCategory(cat2);
- Task task5 = new Task(MylarTasksPlugin.getTaskListManager().genUniqueTaskId(), "task 5");
- cat2.addTask(task5);
- Task task6 = new Task(MylarTasksPlugin.getTaskListManager().genUniqueTaskId(), "task 6");
- cat2.addTask(task6);
-
- assertEquals(manager.getTaskList().getRoots().size(), 4);
-
- manager.saveTaskList();
- assertNotNull(manager.getTaskList());
- TaskList list = new TaskList();
- manager.setTaskList(list);
- manager.readTaskList();
- assertNotNull(manager.getTaskList());
- assertEquals(manager.getTaskList().getRootTasks().size(), 2);
- assertEquals(manager.getTaskList().getCategories().size(), 2);
- check(manager);
- }
-
- public boolean check(TaskListManager manager) {
- List<ITask> list = manager.getTaskList().getRootTasks();
- assertTrue(list.get(0).getLabel().equals("task 1"));
- assertTrue(list.get(0).getChildren().get(0).getLabel().equals("sub 1"));
- assertTrue(list.get(1).getLabel().equals("task 2"));
-
- List<TaskCategory> clist = manager.getTaskList().getTaskCategories();
- list = clist.get(0).getChildren();
- assertTrue(list.get(0).getLabel().equals("task 3"));
- assertTrue(list.get(0).getChildren().get(0).getLabel().equals("sub 2"));
- assertTrue(list.get(1).getLabel().equals("task 4"));
- list = clist.get(1).getChildren();
- assertTrue(list.get(0).getLabel().equals("task 5"));
- assertTrue(list.get(1).getLabel().equals("task 6"));
- return true;
- }
-}
diff --git a/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/TaskListUiTest.java b/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/TaskListUiTest.java
deleted file mode 100644
index d68da958b..000000000
--- a/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/TaskListUiTest.java
+++ /dev/null
@@ -1,263 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.mylar.tasks.tests;
-
-import java.io.File;
-
-import junit.framework.TestCase;
-
-import org.eclipse.jface.viewers.IStructuredContentProvider;
-import org.eclipse.jface.viewers.ITreeContentProvider;
-import org.eclipse.jface.viewers.TreeViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.mylar.tasks.TaskCategory;
-import org.eclipse.mylar.tasks.ITask;
-import org.eclipse.mylar.tasks.MylarTasksPlugin;
-import org.eclipse.mylar.tasks.Task;
-import org.eclipse.mylar.tasks.TaskList;
-import org.eclipse.mylar.tasks.TaskListManager;
-import org.eclipse.mylar.tasks.ui.views.TaskListView;
-import org.eclipse.mylar.tasks.ui.views.TaskListView.PriorityFilter;
-import org.eclipse.swt.widgets.TreeItem;
-import org.eclipse.ui.PartInitException;
-
-/**
- * Tests TaskListView's filtering mechanism.
- * @author Ken Sueda
- *
- */
-public class TaskListUiTest extends TestCase {
- private TaskList tlist = null;
- private TaskCategory cat1 = null;
- private Task cat1task1 = null;
- private Task cat1task2 = null;
- private Task cat1task3 = null;
- private Task cat1task4 = null;
- private Task cat1task5 = null;
- private Task cat1task1sub1 = null;
-
- private TaskCategory cat2 = null;
- private Task cat2task1 = null;
- private Task cat2task2 = null;
- private Task cat2task3 = null;
- private Task cat2task4 = null;
- private Task cat2task5 = null;
- private Task cat2task1sub1 = null;
-
-
- private final static int CHECK_COMPLETE_FILTER = 1;
- private final static int CHECK_INCOMPLETE_FILTER = 2;
- private final static int CHECK_PRIORITY_FILTER = 3;
-
- public void setUp() throws PartInitException{
- MylarTasksPlugin.getDefault().getWorkbench().getActiveWorkbenchWindow().getActivePage().showView("org.eclipse.mylar.tasks.ui.views.TaskListView");
- File file = new File("foo" + MylarTasksPlugin.FILE_EXTENSION);
- TaskListManager manager = new TaskListManager(file);
- tlist = manager.createNewTaskList();
- cat1 = new TaskCategory("First Category");
-
- cat1task1 = new Task(MylarTasksPlugin.getTaskListManager().genUniqueTaskId(), "task 1");
- cat1task1.setPriority("P1");
- cat1task1.setCompleted(true);
- cat1task1.setCategory(cat1);
- cat1.addTask(cat1task1);
-
- cat1task1sub1 = new Task(MylarTasksPlugin.getTaskListManager().genUniqueTaskId(), "sub task 1");
- cat1task1sub1.setPriority("P1");
- cat1task1sub1.setCompleted(true);
- cat1task1sub1.setParent(cat1task1);
- cat1task1.addSubTask(cat1task1sub1);
-
- cat1task2 = new Task(MylarTasksPlugin.getTaskListManager().genUniqueTaskId(), "task 2");
- cat1task2.setPriority("P2");
- cat1task2.setCategory(cat1);
- cat1.addTask(cat1task2);
-
- cat1task3 = new Task(MylarTasksPlugin.getTaskListManager().genUniqueTaskId(), "task 3");
- cat1task3.setPriority("P3");
- cat1task3.setCompleted(true);
- cat1task3.setCategory(cat1);
- cat1.addTask(cat1task3);
-
- cat1task4 = new Task(MylarTasksPlugin.getTaskListManager().genUniqueTaskId(), "task 4");
- cat1task4.setPriority("P4");
- cat1task4.setCategory(cat1);
- cat1.addTask(cat1task4);
-
- cat1task5 = new Task(MylarTasksPlugin.getTaskListManager().genUniqueTaskId(), "task 5");
- cat1task5.setPriority("P5");
- cat1task5.setCompleted(true);
- cat1task5.setCategory(cat1);
- cat1.addTask(cat1task5);
-
- tlist.addCategory(cat1);
- assertEquals(cat1.getChildren().size(), 5);
-
- cat2 = new TaskCategory("Second Category");
-
- cat2task1 = new Task(MylarTasksPlugin.getTaskListManager().genUniqueTaskId(), "task 1");
- cat2task1.setPriority("P1");
- cat2task1.setCategory(cat2);
- cat2.addTask(cat2task1);
-
- cat2task1sub1 = new Task(MylarTasksPlugin.getTaskListManager().genUniqueTaskId(), "sub task 1");
- cat2task1sub1.setPriority("P1");
- cat2task1sub1.setParent(cat2task1);
- cat2task1.addSubTask(cat2task1sub1);
-
- cat2task2 = new Task(MylarTasksPlugin.getTaskListManager().genUniqueTaskId(), "task 2");
- cat2task2.setPriority("P2");
- cat2task2.setCompleted(true);
- cat2task2.setCategory(cat2);
- cat2.addTask(cat2task2);
-
- cat2task3 = new Task(MylarTasksPlugin.getTaskListManager().genUniqueTaskId(), "task 3");
- cat2task3.setPriority("P3");
- cat2task3.setCategory(cat2);
- cat2.addTask(cat2task3);
-
- cat2task4 = new Task(MylarTasksPlugin.getTaskListManager().genUniqueTaskId(), "task 4");
- cat2task4.setPriority("P4");
- cat2task4.setCompleted(true);
- cat2task4.setCategory(cat2);
- cat2.addTask(cat2task4);
-
- cat2task5 = new Task(MylarTasksPlugin.getTaskListManager().genUniqueTaskId(), "task 5");
- cat2task5.setPriority("P5");
- cat2task5.setCategory(cat2);
- cat2.addTask(cat2task5);
-
- tlist.addCategory(cat2);
- manager.saveTaskList();
- }
-
- public void tearDown() {
- // clear everything
- }
-
- public void testUiFilter() {
- assertNotNull(TaskListView.getDefault());
- TreeViewer viewer = TaskListView.getDefault().getViewer();
- viewer.setContentProvider(new ContentProvider());
- viewer.refresh();
- viewer.addFilter(TaskListView.getDefault().getCompleteFilter());
- viewer.refresh();
- viewer.expandAll();
- TreeItem[] items = viewer.getTree().getItems();
- assertTrue(checkFilter(CHECK_COMPLETE_FILTER, items));
- // check complete tasks
-
- viewer.removeFilter(TaskListView.getDefault().getCompleteFilter());
- viewer.addFilter(TaskListView.getDefault().getInCompleteFilter());
- viewer.refresh();
- viewer.expandAll();
- items = viewer.getTree().getItems();
- assertTrue(checkFilter(CHECK_INCOMPLETE_FILTER, items));
- // check incomplte tasks
-
- viewer.removeFilter(TaskListView.getDefault().getInCompleteFilter());
- PriorityFilter filter = TaskListView.getDefault().getPriorityFilter();
- filter.hidePriority("P1");
- filter.hidePriority("P3");
- filter.hidePriority("P4");
- viewer.addFilter(filter);
- viewer.refresh();
- viewer.expandAll();
- items = viewer.getTree().getItems();
-
- // check priority tasks
- assertTrue(checkFilter(CHECK_PRIORITY_FILTER, items));
- }
-
- public boolean checkFilter(int type, TreeItem[] items) {
- switch(type) {
- case CHECK_COMPLETE_FILTER: return checkCompleteIncompleteFilter(items, false);
- case CHECK_INCOMPLETE_FILTER: return checkCompleteIncompleteFilter(items, true);
- case CHECK_PRIORITY_FILTER: return checkPriorityFilter(items);
- default: return false;
- }
- }
-
- public boolean checkCompleteIncompleteFilter(TreeItem[] items, boolean checkComplete) {
- assertTrue(items.length == 2);
- int count = 0;
- for (int i = 0; i < items.length; i++) {
- assertTrue(items[i].getData() instanceof TaskCategory);
- TreeItem[] sub = items[i].getItems();
- for (int j = 0; j < sub.length; j++) {
- assertTrue(sub[j].getData() instanceof ITask);
- ITask task = (ITask) sub[j].getData();
- if (checkComplete) {
- assertTrue(task.isCompleted());
- } else {
- assertFalse(task.isCompleted());
- }
- count++;
- }
- }
- assertTrue(count == 5);
- return true;
- }
-
- public boolean checkPriorityFilter(TreeItem[] items) {
- assertTrue(items.length == 2);
- int p2Count = 0;
- int p5Count = 0;
- for (int i = 0; i < items.length; i++) {
- assertTrue(items[i].getData() instanceof TaskCategory);
- TreeItem[] sub = items[i].getItems();
- for (int j = 0; j < sub.length; j++) {
- assertTrue(sub[j].getData() instanceof ITask);
- ITask task = (ITask) sub[j].getData();
- assertTrue(task.getPriority().equals("P2") || task.getPriority().equals("P5"));
- if (task.getPriority().equals("P2")) {
- p2Count++;
- } else {
- p5Count++;
- }
- }
- }
- assertTrue(p2Count == 2 && p5Count == 2);
- return true;
- }
-
- class ContentProvider implements IStructuredContentProvider, ITreeContentProvider {
- public void inputChanged(Viewer v, Object oldInput, Object newInput) {
- // don't care if the input changes
- }
- public void dispose() {
- // don't care if we are disposed
- }
- public Object[] getElements(Object parent) {
- return tlist.getRoots().toArray();
- }
- public Object getParent(Object child) {
- if (child instanceof TaskCategory) {
- return ((Task)child).getCategory();
- }
- return null;
- }
- public Object [] getChildren(Object parent) {
- if (parent instanceof TaskCategory) {
- return ((TaskCategory)parent).getChildren().toArray();
- }
- return new Object[0];
- }
- public boolean hasChildren(Object parent) {
- if (parent instanceof TaskCategory) {
- TaskCategory cat = (TaskCategory)parent;
- return cat.getChildren() != null && cat.getChildren().size() > 0;
- }
- return false;
- }
- }
-}
diff --git a/org.eclipse.mylyn.tasks.ui/.classpath b/org.eclipse.mylyn.tasks.ui/.classpath
deleted file mode 100644
index 003e39624..000000000
--- a/org.eclipse.mylyn.tasks.ui/.classpath
+++ /dev/null
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
- <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins">
- <accessrules>
- <accessrule kind="accessible" pattern="**/internal/**"/>
- </accessrules>
- </classpathentry>
- <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
- <classpathentry kind="src" path="src"/>
- <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/org.eclipse.mylyn.tasks.ui/.cvsignore b/org.eclipse.mylyn.tasks.ui/.cvsignore
deleted file mode 100644
index ba077a403..000000000
--- a/org.eclipse.mylyn.tasks.ui/.cvsignore
+++ /dev/null
@@ -1 +0,0 @@
-bin
diff --git a/org.eclipse.mylyn.tasks.ui/.project b/org.eclipse.mylyn.tasks.ui/.project
deleted file mode 100644
index 2537de5d3..000000000
--- a/org.eclipse.mylyn.tasks.ui/.project
+++ /dev/null
@@ -1,30 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.mylar.tasks</name>
- <comment></comment>
- <projects>
- </projects>
- <buildSpec>
- <buildCommand>
- <name>org.eclipse.jdt.core.javabuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.pde.ManifestBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.pde.SchemaBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- </buildSpec>
- <natures>
- <nature>org.eclipse.jem.workbench.JavaEMFNature</nature>
- <nature>org.eclipse.jdt.core.javanature</nature>
- <nature>org.eclipse.pde.PluginNature</nature>
- <nature>org.eclipse.jem.beaninfo.BeanInfoNature</nature>
- </natures>
-</projectDescription>
diff --git a/org.eclipse.mylyn.tasks.ui/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.mylyn.tasks.ui/.settings/org.eclipse.jdt.core.prefs
deleted file mode 100644
index a5958370b..000000000
--- a/org.eclipse.mylyn.tasks.ui/.settings/org.eclipse.jdt.core.prefs
+++ /dev/null
@@ -1,12 +0,0 @@
-#Thu Jun 30 08:33:53 PDT 2005
-eclipse.preferences.version=1
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5
-org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.5
-org.eclipse.jdt.core.compiler.debug.lineNumber=generate
-org.eclipse.jdt.core.compiler.debug.localVariable=generate
-org.eclipse.jdt.core.compiler.debug.sourceFile=generate
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
-org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
-org.eclipse.jdt.core.compiler.source=1.5
diff --git a/org.eclipse.mylyn.tasks.ui/META-INF/MANIFEST.MF b/org.eclipse.mylyn.tasks.ui/META-INF/MANIFEST.MF
deleted file mode 100644
index fffccc8ea..000000000
--- a/org.eclipse.mylyn.tasks.ui/META-INF/MANIFEST.MF
+++ /dev/null
@@ -1,33 +0,0 @@
-Manifest-Version: 1.0
-Bundle-ManifestVersion: 2
-Bundle-Name: Mylar Task Plug-in
-Bundle-SymbolicName: org.eclipse.mylar.tasks; singleton:=true
-Bundle-Version: 0.2.4
-Bundle-Activator: org.eclipse.mylar.tasks.MylarTasksPlugin
-Bundle-Localization: plugin
-Require-Bundle: org.eclipse.ui,
- org.eclipse.core.runtime,
- org.eclipse.core.resources,
- org.eclipse.ui.views,
- org.eclipse.ui.forms,
- org.eclipse.ui.ide,
- org.eclipse.osgi.util,
- org.eclipse.osgi.services,
- org.eclipse.search,
- org.eclipse.jdt.ui,
- org.eclipse.pde.ui,
- org.eclipse.mylar.core,
- org.eclipse.mylar.ui,
- org.eclipse.mylar.bugzilla,
- org.eclipse.jdt.core
-Eclipse-AutoStart: true
-Bundle-Vendor: University of British Columbia
-Bundle-ClassPath: mylar-tasklist.jar
-Export-Package: org.eclipse.mylar.tasks,
- org.eclipse.mylar.tasks.bugzilla,
- org.eclipse.mylar.tasks.bugzilla.search,
- org.eclipse.mylar.tasks.bugzilla.ui,
- org.eclipse.mylar.tasks.ui,
- org.eclipse.mylar.tasks.ui.actions,
- org.eclipse.mylar.tasks.ui.views,
- org.eclipse.mylar.tasks.util
diff --git a/org.eclipse.mylyn.tasks.ui/about.html b/org.eclipse.mylyn.tasks.ui/about.html
deleted file mode 100644
index 60ca57b4b..000000000
--- a/org.eclipse.mylyn.tasks.ui/about.html
+++ /dev/null
@@ -1,22 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3c.org/TR/1999/REC-html401-19991224/loose.dtd">
-<!-- saved from url=(0043)http://www.eclipse.org/legal/epl/about.html -->
-<HTML><HEAD><TITLE>About</TITLE>
-<META http-equiv=Content-Type content="text/html; charset=ISO-8859-1">
-<META content="MSHTML 6.00.2900.2627" name=GENERATOR></HEAD>
-<BODY lang=EN-US>
-<H2>About This Content</H2>
-<P>February 24, 2005</P>
-<H3>License</H3>
-<P>The Eclipse Foundation makes available all content in this plug-in
-("Content"). Unless otherwise indicated below, the Content is provided to you
-under the terms and conditions of the Eclipse Public License Version 1.0
-("EPL"). A copy of the EPL is available at <A
-href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</A>.
-For purposes of the EPL, "Program" will mean the Content.</P>
-<P>If you did not receive this Content directly from the Eclipse Foundation, the
-Content is being redistributed by another party ("Redistributor") and different
-terms and conditions may apply to your use of any object code in the Content.
-Check the Redistributor's license that was provided with the Content. If no such
-license exists, contact the Redistributor. Unless otherwise indicated below, the
-terms and conditions of the EPL still apply to any source code in the
-Content.</P></BODY></HTML>
diff --git a/org.eclipse.mylyn.tasks.ui/build.properties b/org.eclipse.mylyn.tasks.ui/build.properties
deleted file mode 100644
index c9d4ccc4a..000000000
--- a/org.eclipse.mylyn.tasks.ui/build.properties
+++ /dev/null
@@ -1,24 +0,0 @@
-###############################################################################
-# Copyright (c) 2004 - 2005 University Of British Columbia and others.
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Eclipse Public License v1.0
-# which accompanies this distribution, and is available at
-# http://www.eclipse.org/legal/epl-v10.html
-#
-# Contributors:
-# University Of British Columbia - initial API and implementation
-###############################################################################
-bin.includes = plugin.xml,\
- icons/,\
- lib/,\
- mylar-tasklist.jar,\
- META-INF/
-src.includes = icons/,\
- plugin.xml,\
- tasklist.jar,\
- src/,\
- lib/,\
- META-INF/
-jars.compile.order = mylar-tasklist.jar
-source.mylar-tasklist.jar = src/
-output.mylar-tasklist.jar = bin/
diff --git a/org.eclipse.mylyn.tasks.ui/icons/elcl16/delete.gif b/org.eclipse.mylyn.tasks.ui/icons/elcl16/delete.gif
deleted file mode 100644
index b6922ac11..000000000
--- a/org.eclipse.mylyn.tasks.ui/icons/elcl16/delete.gif
+++ /dev/null
Binary files differ
diff --git a/org.eclipse.mylyn.tasks.ui/icons/elcl16/refresh.gif b/org.eclipse.mylyn.tasks.ui/icons/elcl16/refresh.gif
deleted file mode 100644
index 634306d4c..000000000
--- a/org.eclipse.mylyn.tasks.ui/icons/elcl16/refresh.gif
+++ /dev/null
Binary files differ
diff --git a/org.eclipse.mylyn.tasks.ui/icons/elcl16/remove.gif b/org.eclipse.mylyn.tasks.ui/icons/elcl16/remove.gif
deleted file mode 100644
index 2cd9c5444..000000000
--- a/org.eclipse.mylyn.tasks.ui/icons/elcl16/remove.gif
+++ /dev/null
Binary files differ
diff --git a/org.eclipse.mylyn.tasks.ui/icons/eview16/task-bug.gif b/org.eclipse.mylyn.tasks.ui/icons/eview16/task-bug.gif
deleted file mode 100644
index 99e9e98f2..000000000
--- a/org.eclipse.mylyn.tasks.ui/icons/eview16/task-bug.gif
+++ /dev/null
Binary files differ
diff --git a/org.eclipse.mylyn.tasks.ui/icons/eview16/task-list.gif b/org.eclipse.mylyn.tasks.ui/icons/eview16/task-list.gif
deleted file mode 100644
index 009443dfe..000000000
--- a/org.eclipse.mylyn.tasks.ui/icons/eview16/task-list.gif
+++ /dev/null
Binary files differ
diff --git a/org.eclipse.mylyn.tasks.ui/icons/eview16/task.gif b/org.eclipse.mylyn.tasks.ui/icons/eview16/task.gif
deleted file mode 100644
index 9881d3872..000000000
--- a/org.eclipse.mylyn.tasks.ui/icons/eview16/task.gif
+++ /dev/null
Binary files differ
diff --git a/org.eclipse.mylyn.tasks.ui/plugin.xml b/org.eclipse.mylyn.tasks.ui/plugin.xml
deleted file mode 100644
index 06fee1ced..000000000
--- a/org.eclipse.mylyn.tasks.ui/plugin.xml
+++ /dev/null
@@ -1,34 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<?eclipse version="3.0"?>
-<plugin>
-
- <extension
- name="Mylar Tasks startup"
- point="org.eclipse.ui.startup">
- </extension>
-
- <extension point="org.eclipse.ui.views">
-
- <view name="Mylar Tasks"
- icon="icons/eview16/task-list.gif"
- category="org.eclipse.mylar"
- class="org.eclipse.mylar.tasks.ui.views.TaskListView"
- id="org.eclipse.mylar.tasks.ui.views.TaskListView" />
- </extension>
- <extension
- point="org.eclipse.ui.editors">
- <editor
- icon="icons/eview16/task.gif"
- class="org.eclipse.mylar.tasks.ui.TaskEditor"
- name="Task Viewer"
- id="org.eclipse.mylar.tasks.ui.taskEditor"/>
- <editor
- icon="icons/eview16/task-bug.gif"
- name="Bugzilla task viewer"
- class="org.eclipse.mylar.tasks.ui.BugzillaTaskEditor"
- id="org.eclipse.mylar.tasks.ui.bugzillaTaskEditor"/>
- </extension>
-
- <extension point="org.eclipse.ui.commands">
- </extension>
-</plugin>
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/AbstractCategory.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/AbstractCategory.java
deleted file mode 100644
index 599106aba..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/AbstractCategory.java
+++ /dev/null
@@ -1,60 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.mylar.tasks;
-
-import org.eclipse.swt.graphics.Image;
-
-/**
- * @author Ken Sueda
- */
-public class AbstractCategory implements ITaskListElement {
-
- private String priority = "";
- private String description = "";
- private String handle = "";
-
- public AbstractCategory(String description) {
- this.description = description;
- }
-
- public Image getIcon() {
- return null;
- }
-
- public String getPriority() {
- return priority;
- }
-
- public String getDescription(boolean label) {
- return description;
- }
-
- public String getHandle() {
- return handle;
- }
-
- public void setDescription(String description) {
- this.description = description;
- }
-
- public void setHandle(String handle) {
- this.handle = handle;
- }
-
- public void setPriority(String priority) {
- this.priority = priority;
- }
-
- public Image getStatusIcon() {
- return null;
- }
-}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/BugzillaHit.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/BugzillaHit.java
deleted file mode 100644
index f768eca1d..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/BugzillaHit.java
+++ /dev/null
@@ -1,91 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.mylar.tasks;
-
-import org.eclipse.mylar.bugzilla.BugzillaImages;
-import org.eclipse.mylar.ui.MylarImages;
-import org.eclipse.swt.graphics.Image;
-
-/**
- * @author Ken Sueda
- */
-public class BugzillaHit implements ITaskListElement {
-
- private String description;
- private String priority;
- private int id;
- private BugzillaTask task;
-
- public BugzillaHit(String description, String priority, int id, BugzillaTask task) {
- this.description = description;
- this.priority = priority;
- this.id = id;
- this.task = task;
- }
-
- public boolean isTask(){
- return task != null;
- }
-
- public BugzillaTask getAssociatedTask(){
- return task;
- }
-
- public void setAssociatedTask(BugzillaTask task){
- this.task = task;
- }
-
- public Image getIcon() {
- if(isTask()){
- return task.getIcon();
- } else {
- return BugzillaImages.getImage(BugzillaImages.BUG);
- }
- }
-
- public Image getStatusIcon() {
- if (isTask()) {
- return task.getStatusIcon();
- } else {
- return MylarImages.getImage(MylarImages.TASK_INACTIVE);
- }
- }
-
- public String getPriority() {
- return priority;
- }
-
- public String getDescription(boolean label) {
- return description;
- }
-
- public String getHandle() {
- return getServerName()+"-"+getID();
- }
- public void setDescription(String description) {
- this.description = description;
- }
- public String getServerName() {
- // TODO need the right server name - get from the handle
- return "Bugzilla";
- }
- public int getID() {
-
- return id;
- }
-
- public String getIDString() {
- Integer bugId = new Integer(this.id);
- return bugId.toString();
- }
-
-}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/BugzillaQueryCategory.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/BugzillaQueryCategory.java
deleted file mode 100644
index 2858c3236..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/BugzillaQueryCategory.java
+++ /dev/null
@@ -1,155 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.mylar.tasks;
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-import javax.security.auth.login.LoginException;
-
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.jface.dialogs.ErrorDialog;
-import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.mylar.bugzilla.BugzillaPlugin;
-import org.eclipse.mylar.bugzilla.IBugzillaConstants;
-import org.eclipse.mylar.bugzilla.search.BugzillaSearchHit;
-import org.eclipse.mylar.tasks.bugzilla.search.BugzillaCategorySearchOperation;
-import org.eclipse.mylar.tasks.bugzilla.search.BugzillaResultCollector;
-import org.eclipse.mylar.tasks.bugzilla.search.BugzillaCategorySearchOperation.ICategorySearchListener;
-import org.eclipse.mylar.ui.MylarImages;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.ui.PlatformUI;
-
-/**
- * @author Shawn Minto
- */
-public class BugzillaQueryCategory extends AbstractCategory {
-
- private static final long serialVersionUID = 5517146402031743253L;
- private String url;
- private List<BugzillaHit> hits = new ArrayList<BugzillaHit>();
- private boolean hasBeenRefreshed = false;
-
- public class BugzillaQueryCategorySearchListener implements
- ICategorySearchListener {
-
- Map<Integer, BugzillaSearchHit> hits = new HashMap<Integer, BugzillaSearchHit>();
-
- public void searchCompleted(BugzillaResultCollector collector) {
- for(BugzillaSearchHit hit: collector.getResults()){
-
- // HACK need the server name and handle properly
- addHit(new BugzillaHit(hit.getId() + ": " + hit.getDescription(), hit.getPriority(), hit.getId(), null));
- }
- }
-
- }
-
- private ICategorySearchListener listener = new BugzillaQueryCategorySearchListener();
-
- public BugzillaQueryCategory(String label, String url) {
- super(label);
- this.url = url;
- }
-
- public String getDescription(boolean label) {
- if (hits.size() > 0 || !label) {
- return super.getDescription(label);
- } else if (!hasBeenRefreshed) {
- return super.getDescription(label) + " <needs refresh>";
- } else {
- return super.getDescription(label) + " <no hits>";
- }
- }
-
-
- public Image getIcon() {
- return MylarImages.getImage(MylarImages.CATEGORY_QUERY);
- }
-
- public String getUrl() {
- return url;
- }
-
- public List<BugzillaHit> getHits() {
- return hits;
- }
-
- public void addHit(BugzillaHit hit) {
- BugzillaTask task = MylarTasksPlugin.getTaskListManager().getTaskList().getFromBugzillaTaskRegistry(hit.getHandle());
- hit.setAssociatedTask(task);
- hits.add(hit);
- }
-
- public void removeHit(BugzillaHit hit) {
- hits.remove(hit);
- }
-
- public void refreshBugs() {
- hits.clear();
- final BugzillaCategorySearchOperation catSearch = new BugzillaCategorySearchOperation(
- getUrl());
- catSearch.addResultsListener(listener);
- final IStatus[] status = new IStatus[1];
-
- try {
- // execute the search operation
- catSearch.execute(new NullProgressMonitor());
- hasBeenRefreshed = true;
-
- // get the status of the search operation
- status[0] = catSearch.getStatus();
-
- // determine if there was an error, if it was cancelled, or if it is
- // ok
- if (status[0].getCode() == IStatus.CANCEL) {
- // it was cancelled, so just return
- status[0] = Status.OK_STATUS;
- // return status[0];
- return;
- } else if (!status[0].isOK()) {
- // there was an error, so display an error message
- PlatformUI.getWorkbench().getDisplay().asyncExec(
- new Runnable() {
- public void run() {
- ErrorDialog.openError(null,
- "Bugzilla Search Error", null,
- status[0]);
- }
- });
- status[0] = Status.OK_STATUS;
- return;
- // return status[0];
- }
- } catch (LoginException e) {
- // we had a problem while searching that seems like a login info
- // problem
- // thrown in BugzillaSearchOperation
- MessageDialog
- .openError(
- null,
- "Login Error",
- "Bugzilla could not log you in to get the information you requested since login name or password is incorrect.\nPlease check your settings in the bugzilla preferences. ");
- BugzillaPlugin.log(new Status(IStatus.ERROR,
- IBugzillaConstants.PLUGIN_ID, IStatus.OK, "", e));
- }
- return;
- }
-
- public void setUrl(String url) {
- this.url = url;
- }
-
-}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/BugzillaTask.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/BugzillaTask.java
deleted file mode 100644
index 9385f7666..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/BugzillaTask.java
+++ /dev/null
@@ -1,471 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on 14-Jan-2005
- */
-package org.eclipse.mylar.tasks;
-
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.Date;
-import java.util.List;
-
-import javax.security.auth.login.LoginException;
-
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.core.runtime.jobs.IJobChangeEvent;
-import org.eclipse.core.runtime.jobs.IJobChangeListener;
-import org.eclipse.core.runtime.jobs.ISchedulingRule;
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.mylar.bugzilla.BugzillaPlugin;
-import org.eclipse.mylar.bugzilla.core.BugReport;
-import org.eclipse.mylar.bugzilla.core.BugzillaRepository;
-import org.eclipse.mylar.bugzilla.core.IBugzillaBug;
-import org.eclipse.mylar.bugzilla.offlineReports.OfflineReportsFile;
-import org.eclipse.mylar.bugzilla.ui.OfflineView;
-import org.eclipse.mylar.core.MylarPlugin;
-import org.eclipse.mylar.tasks.ui.BugzillaTaskEditorInput;
-import org.eclipse.mylar.ui.MylarImages;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.ui.IEditorInput;
-import org.eclipse.ui.IWorkbench;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.internal.Workbench;
-
-
-/**
- * @author Mik Kersten
- */
-public class BugzillaTask extends Task {
-
- /**
- * Comment for <code>serialVersionUID</code>
- */
- private static final long serialVersionUID = 3257007648544469815L;
-
- public static final String FILE_EXTENSION = ".bug_reports";
-
- public enum BugTaskState {FREE, WAITING, DOWNLOADING, COMPARING, OPENING}
- private transient BugTaskState state;
-
- /**
- * The bug report for this BugzillaTask. This is <code>null</code> if the
- * bug report with the specified ID was unable to download.
- */
- protected transient BugReport bugReport = null;
-
- /**
- * Value is <code>true</code> if the bug report has saved changes that
- * need synchronizing with the Bugzilla server.
- */
- private boolean isDirty;
-
- /** The last time this task's bug report was downloaded from the server. */
- protected Date lastRefresh;
-
- public static final ISchedulingRule rule = new ISchedulingRule() {
- public boolean isConflicting(ISchedulingRule schedulingRule) {
- return schedulingRule == this;
- }
- public boolean contains(ISchedulingRule schedulingRule) {
- return schedulingRule == this;
- }
- };
-
- public BugzillaTask(String id, String label) {
- super(id, label);
- isDirty = false;
- GetBugReportJob job = new GetBugReportJob("Downloading from Bugzilla server...");
- job.schedule();
- }
-
- public BugzillaTask(String id, String label, boolean noDownload) {
- super(id, label);
- isDirty = false;
- if (!noDownload) {
- GetBugReportJob job = new GetBugReportJob("Downloading from Bugzilla server...");
- job.schedule();
- }
- }
-
- public BugzillaTask(BugzillaHit hit) {
- this(hit.getHandle(), hit.getDescription(false));
- }
-
- @Override
- public String getLabel() {
- return MylarTasksPlugin.getDefault().getBugzillaProvider().getBugzillaDescription(this);
- }
-
- /**
- * @return Returns the bugReport.
- */
- public BugReport getBugReport() {
- return bugReport;
- }
-
- /**
- * @param bugReport The bugReport to set.
- */
- public void setBugReport(BugReport bugReport) {
- this.bugReport = bugReport;
- }
-
- /**
- * @return Returns the serialVersionUID.
- */
- public static long getSerialVersionUID() {
- return serialVersionUID;
- }
- /**
- * @return Returns the lastRefresh.
- */
- public Date getLastRefresh() {
- return lastRefresh;
- }
- /**
- * @param lastRefresh The lastRefresh to set.
- */
- public void setLastRefresh(Date lastRefresh) {
- this.lastRefresh = lastRefresh;
- }
- /**
- * @param state The state to set.
- */
- public void setState(BugTaskState state) {
- this.state = state;
- }
- /**
- * @return Returns <code>true</code> if the bug report has saved changes
- * that need synchronizing with the Bugzilla server.
- */
- public boolean isDirty() {
- return isDirty;
- }
-
- /**
- * @param isDirty The isDirty to set.
- */
- public void setDirty(boolean isDirty) {
- this.isDirty = isDirty;
- notifyTaskDataChange();
- }
-
- /**
- * @return Returns the state of the Bugzilla task.
- */
- public BugTaskState getState() {
- return state;
- }
-
- /**
- * Try to download the bug from the server.
- * @param bugId The ID of the bug report to download.
- *
- * @return The bug report, or <code>null</code> if it was unsuccessfully
- * downloaded.
- */
- public BugReport downloadReport() {
-// BugzillaTaskEditorInput input = new BugzillaTaskEditorInput(this);
- try {
- // XXX make sure to send in the server name if there are multiple repositories
- return BugzillaRepository.getInstance().getBug(getBugId(getHandle()));
- } catch (LoginException e) {
- MylarPlugin.log(e, "download failed");
- } catch (IOException e) {
- MylarPlugin.log(e, "download failed");
- }
- return null;
- }
-
- @Override
- public void openTaskInEditor(){
- openTask(-1);
- }
-
- /**
- * Opens this task's bug report in an editor revealing the selected comment.
- * @param commentNumber The comment number to reveal
- */
- public void openTask(int commentNumber) {
- if (state != BugTaskState.FREE) {
- return;
- }
-
- state = BugTaskState.OPENING;
- notifyTaskDataChange();
- OpenBugTaskJob job = new OpenBugTaskJob("Opening Bugzilla task in editor...", this);
- job.schedule();
- job.addJobChangeListener(new IJobChangeListener(){
-
- public void aboutToRun(IJobChangeEvent event) {
- // don't care about this event
- }
-
- public void awake(IJobChangeEvent event) {
- // don't care about this event
- }
-
- public void done(IJobChangeEvent event) {
- state = BugTaskState.FREE;
- notifyTaskDataChange();
- }
-
- public void running(IJobChangeEvent event) {
- // don't care about this event
- }
-
- public void scheduled(IJobChangeEvent event) {
- // don't care about this event
- }
-
- public void sleeping(IJobChangeEvent event) {
- // don't care about this event
- }
- });
- }
-
- /**
- * @return <code>true</code> if the bug report for this BugzillaTask was
- * successfully downloaded.
- */
- public boolean isBugDownloaded() {
- return bugReport != null;
- }
-
- @Override
- public String toString() {
- return "bugzilla report id: " + getHandle();
- }
-
- protected void openTaskEditor(final IEditorInput input) {
- if (isBugDownloaded()) {
-
- Workbench.getInstance().getDisplay().asyncExec(new Runnable() {
- public void run() {
- // get the active workbench page
- IWorkbenchPage page = MylarTasksPlugin.getDefault().getWorkbench().getActiveWorkbenchWindow().getActivePage();
-
- // if we couldn't get the page, get out of here
- if (page == null)
- return;
-
- try {
- // try to open an editor on the input bug
- //page.openEditor(input, IBugzillaConstants.EXISTING_BUG_EDITOR_ID);
- page.openEditor(input, "org.eclipse.mylar.tasks.ui.bugzillaTaskEditor");
- }
- catch (PartInitException ex) {
- MylarPlugin.log(ex, "couldn't open");
- return;
- }
- }
- });
- }
- else {
- Workbench.getInstance().getDisplay().asyncExec(new Runnable() {
- public void run() {
- MessageDialog.openInformation(Workbench.getInstance().getActiveWorkbenchWindow().getShell(),
- "Could not open bug.", "Bug #" + getHandle()
- + " could not be read from the server. Try refreshing the bug task.");
- }
- });
- }
- }
-
- /**
- * @return Returns the last time this task's bug report was downloaded from
- * the server.
- */
- public Date getLastRefreshTime() {
- return lastRefresh;
- }
-
- /**
- * @return The number of seconds ago that this task's bug report was
- * downloaded from the server.
- */
- public long getTimeSinceLastRefresh() {
- Date timeNow = new Date();
- return (timeNow.getTime() - lastRefresh.getTime())/1000;
- }
-
- private class GetBugReportJob extends Job {
- public GetBugReportJob(String name) {
- super(name);
- setRule(rule);
- state = BugTaskState.WAITING;
- notifyTaskDataChange();
- }
-
- @Override
- protected IStatus run(IProgressMonitor monitor) {
- state = BugTaskState.DOWNLOADING;
- notifyTaskDataChange();
- // Update time this bugtask was last downloaded.
- lastRefresh = new Date();
- bugReport = downloadReport();
- state = BugTaskState.FREE;
- updateTaskDetails();
- notifyTaskDataChange();
- saveBugReport(true);
- return new Status(IStatus.OK, MylarPlugin.IDENTIFIER, IStatus.OK, "", null);
- }
- }
-
- public void updateTaskDetails() {
- setPriority(bugReport.getAttribute("Priority").getValue());
- String status = bugReport.getAttribute("Status").getValue();
- if (status.equals("RESOLVED")) {
- setCompleted(true);
- }
- }
-
- private class OpenBugTaskJob extends Job {
-
- protected BugzillaTask bugTask;
-
- public OpenBugTaskJob(String name, BugzillaTask bugTask) {
- super(name);
- this.bugTask = bugTask;
- }
-
- @Override
- protected IStatus run(IProgressMonitor monitor) {
- try{
- final IEditorInput input = new BugzillaTaskEditorInput(bugTask);
- state = BugTaskState.OPENING;
- notifyTaskDataChange();
- openTaskEditor(input);
-
- state = BugTaskState.FREE;
- notifyTaskDataChange();
- return new Status(IStatus.OK, MylarPlugin.IDENTIFIER, IStatus.OK, "", null);
- }catch(Exception e){
- MylarPlugin.log(e, "couldn't open");
- }
- return Status.CANCEL_STATUS;
- }
- }
-
- /**
- * Refreshes the bug report with the Bugzilla server.
- */
- public void refresh() {
- // The bug report must be untouched, and this task must not be busy.
- if (isDirty() || (state != BugTaskState.FREE)) {
- return;
- }
- GetBugReportJob job = new GetBugReportJob("Refreshing with Bugzilla server...");
- job.schedule();
- }
-
- @Override
- public String getToolTipText() {
- if(lastRefresh == null)
- return "";
- // Get the current time.
- Date timeNow = new Date();
-
- // Get the number of minutes between the current time
- // and the last time the bug report was downloaded
- long timeDifference = (timeNow.getTime() - lastRefresh.getTime())/60000;
-
- // Calculate the number of minutes and hours.
- // The amount left in "timeDifference" is the
- // days' difference.
- long minutes = timeDifference % 60;
- timeDifference /= 60;
- long hours = timeDifference % 24;
- timeDifference /= 24;
-
- // Gradually generate the tooltip string...
- String toolTip;
- if (bugReport == null) {
- toolTip = "Last attempted download ";
- }
- else {
- toolTip = "Last downloaded ";
- }
-
- if (timeDifference > 0) {
- toolTip += timeDifference + ((timeDifference == 1) ? " day " : " days ");
- }
- if (hours > 0 || timeDifference > 0) {
- toolTip += hours + ((hours == 1) ? " hour " : " hours ");
- }
- toolTip += minutes + ((minutes == 1) ? " minute " : " minutes ") + "ago";
-
- return toolTip;
- }
-
- public boolean readBugReport() {
- // XXX server name needs to be with the bug report
- int location = BugzillaPlugin.getDefault().getOfflineReports().find(getBugId(getHandle()));
- if(location == -1){
- bugReport = null;
- return true;
- }
- bugReport = (BugReport)BugzillaPlugin.getDefault().getOfflineReports().elements().get(location);
- return true;
- }
-
- public void saveBugReport(boolean refresh) {
- if(bugReport == null)
- return;
-
- // XXX use the server name for multiple repositories
- OfflineReportsFile offlineReports = BugzillaPlugin.getDefault().getOfflineReports();
- int location = offlineReports.find(getBugId(getHandle()));
- if(location != -1){
- IBugzillaBug tmpBugReport = offlineReports.elements().get(location);
- List<IBugzillaBug> l = new ArrayList<IBugzillaBug>(1);
- l.add(tmpBugReport);
- offlineReports.remove(l);
- }
- offlineReports.add(bugReport);
-
- if(refresh){
- final IWorkbench workbench = PlatformUI.getWorkbench();
- workbench.getDisplay().asyncExec(new Runnable() {
- public void run() {
- OfflineView.refresh();
- }
- });
- }
- }
-
- public static String getServerName(String handle) {
- int index = handle.lastIndexOf('-');
- if(index != -1){
- return handle.substring(0, index);
- }
- return null;
- }
-
- public static int getBugId(String handle) {
- int index = handle.lastIndexOf('-');
- if(index != -1){
- String id = handle.substring(index+1);
- return Integer.parseInt(id);
- }
- return -1;
- }
-
- public Image getIcon() {
- return MylarImages.getImage(MylarImages.TASK_BUGZILLA);
- }
-}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ITask.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ITask.java
deleted file mode 100644
index 7380741d2..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ITask.java
+++ /dev/null
@@ -1,97 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on Jan 13, 2005
- */
-package org.eclipse.mylar.tasks;
-
-import java.io.Serializable;
-import java.util.List;
-
-/**
- * @author Mik Kersten
- *
- * TODO: make IDs be handles
- */
-public interface ITask extends Serializable {
-
- @Override
- public abstract String toString();
-
- public abstract String getPath();
-
- public abstract void setPath(String path);
-
- public abstract String getHandle();
-
- public abstract void setHandle(String id);
-
- public abstract String getLabel();
-
- public abstract void setLabel(String label);
-
- public abstract ITask getParent();
-
- public abstract void setParent(ITask parent);
-
- public abstract boolean isActive();
-
- public abstract void setActive(boolean active);
-
- public abstract boolean isCompleted();
-
- public abstract void setCompleted(boolean completed);
-
- public abstract RelatedLinks getRelatedLinks();
-
- public abstract void setRelatedLinks(RelatedLinks relatedLinks);
-
- public abstract void addLink(String url);
-
- public abstract void removeLink(String url);
-
- public abstract String getNotes();
-
- public abstract void setNotes(String notes);
-
- public abstract String getElapsedTime();
-
- public abstract void setElapsedTime(String elapsed);
-
- public abstract String getEstimatedTime();
-
- public abstract void setEstimatedTime(String estimated);
-
- public abstract List<ITask> getChildren();
-
- public abstract void addSubTask(ITask t);
-
- public abstract void removeSubTask(ITask t);
-
- /**
- * Opens this task in an editor
- */
- public abstract void openTaskInEditor();
-
- public abstract String getToolTipText();
-
- public abstract String getPriority();
-
- public abstract void setPriority(String priority);
- @Deprecated
- public abstract boolean isCategory();
- @Deprecated
- public abstract void setIsCategory(boolean b);
-
- public abstract void setCategory(TaskCategory cat);
-
- public abstract TaskCategory getCategory();
-} \ No newline at end of file
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ITaskActivityListener.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ITaskActivityListener.java
deleted file mode 100644
index 98abbe02a..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ITaskActivityListener.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on Jan 13, 2005
- */
-package org.eclipse.mylar.tasks;
-
-import java.util.List;
-
-/**
- * @author Mik Kersten
- */
-public interface ITaskActivityListener {
-
- public abstract void taskActivated(ITask task);
-
- public abstract void tasksActivated(List<ITask> tasks);
-
- public abstract void taskDeactivated(ITask task);
-
- public abstract void taskPropertyChanged(ITask updatedTask, String property);
-}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ITaskInfo.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ITaskInfo.java
deleted file mode 100644
index e8fbc8de8..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ITaskInfo.java
+++ /dev/null
@@ -1,23 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on Jan 12, 2005
- */
-package org.eclipse.mylar.tasks;
-
-/**
- * @author Mik Kersten
- */
-public interface ITaskInfo {
-
- public String getHandle();
-
-}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ITaskListElement.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ITaskListElement.java
deleted file mode 100644
index b8b0a5927..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ITaskListElement.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-package org.eclipse.mylar.tasks;
-
-import org.eclipse.swt.graphics.Image;
-
-/**
- * @author Ken Sueda
- */
-public interface ITaskListElement {
-
- public abstract Image getIcon();
-
- public abstract Image getStatusIcon();
-
- public abstract String getPriority();
-
- public abstract String getDescription(boolean label);
-
- public abstract String getHandle();
-}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/MylarTasksPlugin.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/MylarTasksPlugin.java
deleted file mode 100644
index 061cc0fd2..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/MylarTasksPlugin.java
+++ /dev/null
@@ -1,356 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-package org.eclipse.mylar.tasks;
-
-import java.io.File;
-import java.util.ArrayList;
-import java.util.List;
-import java.util.MissingResourceException;
-import java.util.ResourceBundle;
-
-import org.eclipse.core.runtime.Preferences.IPropertyChangeListener;
-import org.eclipse.core.runtime.Preferences.PropertyChangeEvent;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.mylar.core.MylarPlugin;
-import org.eclipse.mylar.tasks.bugzilla.BugzillaContentProvider;
-import org.eclipse.mylar.tasks.bugzilla.BugzillaEditingMonitor;
-import org.eclipse.mylar.tasks.bugzilla.BugzillaMylarBridge;
-import org.eclipse.mylar.tasks.bugzilla.BugzillaReferencesProvider;
-import org.eclipse.mylar.tasks.bugzilla.BugzillaStructureBridge;
-import org.eclipse.mylar.tasks.bugzilla.ui.BugzillaUiBridge;
-import org.eclipse.mylar.ui.MylarUiPlugin;
-import org.eclipse.swt.events.ShellEvent;
-import org.eclipse.swt.events.ShellListener;
-import org.eclipse.ui.IStartup;
-import org.eclipse.ui.IWorkbench;
-import org.eclipse.ui.IWorkbenchWindow;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.internal.Workbench;
-import org.eclipse.ui.plugin.AbstractUIPlugin;
-import org.osgi.framework.BundleContext;
-
-/**
- * @author Mik Kersten
- */
-public class MylarTasksPlugin extends AbstractUIPlugin implements IStartup {
-
- private static MylarTasksPlugin plugin;
- private static TaskListManager taskListManager;
- private BugzillaContentProvider bugzillaProvider;
-
- public static final String FILE_EXTENSION = ".xml";
- public static final String TASK_ID = "org.eclipse.mylar.tasks.userid";
- public static final String DEFAULT_TASK_LIST_FILE = "tasklist" + FILE_EXTENSION;
- public static final String TASK_EDITOR_ID = "org.eclipse.mylar.tasks.ui.taskEditor";
- public static final String SHOW_P1_MODE = "org.eclipse.mylar.tasks.show.p1";
- public static final String SHOW_P2_MODE = "org.eclipse.mylar.tasks.show.p2";
- public static final String SHOW_P3_MODE = "org.eclipse.mylar.tasks.show.p3";
- public static final String SHOW_P4_MODE = "org.eclipse.mylar.tasks.show.p4";
- public static final String SHOW_P5_MODE = "org.eclipse.mylar.tasks.show.p5";
- public static final String FILTER_COMPLETE_MODE = "org.eclipse.mylar.tasks.filter.complete";
- public static final String FILTER_INCOMPLETE_MODE = "org.eclipse.mylar.tasks.filter.incomplete";
-
- private ResourceBundle resourceBundle;
-
- public enum Priority_Level {
- P1,
- P2,
- P3,
- P4,
- P5;
-
- @Override
- public String toString() {
- switch(this) {
- case P1: return "P1";
- case P2: return "P2";
- case P3: return "P3";
- case P4: return "P4";
- case P5: return "P5";
- default: return "null";
- }
- }
- public static Priority_Level fromString(String string) {
- if (string == null) return null;
- if (string.equals("P1")) return P1;
- if (string.equals("P2")) return P2;
- if (string.equals("P3")) return P3;
- if (string.equals("P4")) return P4;
- if (string.equals("P5")) return P5;
- return null;
- }
- }
-
- /** The bridge between Bugzilla and mylar */
- private static BugzillaMylarBridge bridge = null;
-
- private BugzillaStructureBridge structureBridge;
-
- private static BugzillaReferencesProvider referencesProvider = new BugzillaReferencesProvider();
-
- private static ITaskActivityListener TASK_LIST_LISTENER = new ITaskActivityListener() {
-
- public void taskActivated(ITask task) {
- MylarPlugin.getTaskscapeManager().taskActivated(task.getHandle(), task.getPath());
- }
-
- public void tasksActivated(List<ITask> tasks) {
- for (ITask task : tasks) {
- MylarPlugin.getTaskscapeManager().taskActivated(task.getHandle(), task.getPath());
- }
- }
-
- public void taskDeactivated(ITask task) {
- MylarPlugin.getTaskscapeManager().taskDeactivated(task.getHandle(), task.getPath());
- }
-
- public void taskPropertyChanged(ITask updatedTask, String property) {
- // don't care about property change
- }
-
- };
-
- private static ShellListener SHELL_LISTENER = new ShellListener() {
- private void saveState() {
- taskListManager.saveTaskList();
- for(ITask task : taskListManager.getTaskList().getActiveTasks()) {
- MylarPlugin.getTaskscapeManager().saveTaskscape(task.getHandle(), task.getPath());
- }
- }
- public void shellClosed(ShellEvent arg0) {
- saveState();
- }
- public void shellDeactivated(ShellEvent arg0) {
- saveState();
- }
- public void shellActivated(ShellEvent arg0) { }
- public void shellDeiconified(ShellEvent arg0) { }
- public void shellIconified(ShellEvent arg0) { }
- };
-
- private static IPropertyChangeListener PREFERENCE_LISTENER = new IPropertyChangeListener() {
-
- public void propertyChange(PropertyChangeEvent event) {
- // TODO Auto-generated method stub
- if (event.getProperty().equals(MylarPlugin.MYLAR_DIR)) {
- if (event.getOldValue() instanceof String) {
- String prevDir = (String) event.getOldValue();
- MylarPlugin.getTaskscapeManager().updateMylarDirContents(prevDir);
- getTaskListManager().updateTaskscapeReference(prevDir);
-
- String path = MylarPlugin.getDefault().getUserDataDirectory() + File.separator + DEFAULT_TASK_LIST_FILE;
- getTaskListManager().setFile(new File(path));
- }
- } else {
- }
- }
- };
-
- public MylarTasksPlugin() {
- super();
- plugin = this;
- }
-
- public void earlyStartup() {
- final IWorkbench workbench = PlatformUI.getWorkbench();
- workbench.getDisplay().asyncExec(new Runnable() {
- public void run() {
-
- structureBridge = new BugzillaStructureBridge();
-
- MylarPlugin.getDefault().addBridge(structureBridge);
- MylarPlugin.getTaskscapeManager().addListener(referencesProvider);
- MylarUiPlugin.getDefault().addAdapter(BugzillaStructureBridge.EXTENSION, new BugzillaUiBridge());
- MylarPlugin.getDefault().getSelectionMonitors().add(new BugzillaEditingMonitor());
-
- IWorkbenchWindow window = workbench.getActiveWorkbenchWindow();
-
- Workbench.getInstance().getActiveWorkbenchWindow().getShell().addShellListener(SHELL_LISTENER);
- MylarPlugin.getDefault().getPluginPreferences().addPropertyChangeListener(PREFERENCE_LISTENER);
-
- getPrefs().setDefault(SHOW_P1_MODE, true);
- getPrefs().setDefault(SHOW_P2_MODE, true);
- getPrefs().setDefault(SHOW_P3_MODE, true);
- getPrefs().setDefault(SHOW_P4_MODE, true);
- getPrefs().setDefault(SHOW_P5_MODE, true);
- if (window != null) {
- // create a new bridge and initialize it
- bridge = new BugzillaMylarBridge();
- }
- }
- });
- }
-
- @Override
- public void start(BundleContext context) throws Exception {
- bugzillaProvider = new BugzillaContentProvider();
- String path = MylarPlugin.getDefault().getUserDataDirectory() + File.separator + DEFAULT_TASK_LIST_FILE;
- File taskListFile = new File(path);
- taskListManager = new TaskListManager(taskListFile);
- taskListManager.addListener(TASK_LIST_LISTENER);
- taskListManager.readTaskList();
- if (taskListManager.getTaskList() == null) taskListManager.createNewTaskList();
-
- super.start(context);
- }
-
- @Override
- public void stop(BundleContext context) throws Exception {
- super.stop(context);
- plugin = null;
- resourceBundle = null;
- }
-
- /**
- * Get the bridge for this plugin
- *
- * @return The bugzilla mylar bridge
- */
- public static BugzillaMylarBridge getBridge() {
- // make sure that the bridge initialized, if not, make a new one
- if (bridge == null) {
- bridge = new BugzillaMylarBridge();
-// MylarPlugin.getTaskscapeManager().addRelationshipProvider(new BugzillaRelationshipProvider());
-// MylarUiPlugin.getDefault().getAdapters().put(ITaskscapeNode.Kind.Bugzilla, new BugzillaUiAdapter());
- }
- return bridge;
- }
-
-
- public static TaskListManager getTaskListManager() {
- return taskListManager;
- }
-
- /**
- * Returns the shared instance.
- */
- public static MylarTasksPlugin getDefault() {
- return plugin;
- }
-
- /**
- * Returns the string from the plugin's resource bundle,
- * or 'key' if not found.
- */
- public static String getResourceString(String key) {
- ResourceBundle bundle = MylarTasksPlugin.getDefault().getResourceBundle();
- try {
- return (bundle != null) ? bundle.getString(key) : key;
- } catch (MissingResourceException e) {
- return key;
- }
- }
-
- /**
- * Returns the plugin's resource bundle,
- */
- public ResourceBundle getResourceBundle() {
- try {
- if (resourceBundle == null)
- resourceBundle = ResourceBundle.getBundle("taskListPlugin.TaskListPluginPluginResources");
- } catch (MissingResourceException x) {
- resourceBundle = null;
- }
- return resourceBundle;
- }
-
- public BugzillaContentProvider getBugzillaProvider() {
- return bugzillaProvider;
- }
-
- public void setBugzillaProvider(BugzillaContentProvider bugzillaProvider) {
- this.bugzillaProvider = bugzillaProvider;
- }
-
- public BugzillaStructureBridge getStructureBridge() {
- return structureBridge;
- }
-
- public static BugzillaReferencesProvider getReferenceProvider() {
- return referencesProvider;
-
- }
-
- public static IPreferenceStore getPrefs() {
- return MylarPlugin.getDefault().getPreferenceStore();
- }
-
- public static void setPriorityLevel(Priority_Level pl, boolean showPriority) {
- String key = "";
- switch(pl) {
- case P1: key = SHOW_P1_MODE; break;
- case P2: key = SHOW_P2_MODE; break;
- case P3: key = SHOW_P3_MODE; break;
- case P4: key = SHOW_P4_MODE; break;
- case P5: key = SHOW_P5_MODE; break;
- default: key = SHOW_P1_MODE; break;
- }
- getPrefs().setValue(key, showPriority);
- }
- public static boolean getPriorityLevel(Priority_Level pl) {
- String key = "";
- switch(pl) {
- case P1: key = SHOW_P1_MODE; break;
- case P2: key = SHOW_P2_MODE; break;
- case P3: key = SHOW_P3_MODE; break;
- case P4: key = SHOW_P4_MODE; break;
- case P5: key = SHOW_P5_MODE; break;
- default: key = SHOW_P1_MODE; break;
- }
- if(getPrefs().contains(key)) {
- return getPrefs().getBoolean(key);
- } else {
- return true;
- }
- }
- public static List<Priority_Level> getPriorityLevels() {
- List<Priority_Level> levels = new ArrayList<Priority_Level>();
- if (getPriorityLevel(Priority_Level.P1)) {
- levels.add(Priority_Level.P1);
- }
- if (getPriorityLevel(Priority_Level.P2)) {
- levels.add(Priority_Level.P2);
- }
- if (getPriorityLevel(Priority_Level.P3)) {
- levels.add(Priority_Level.P3);
- }
- if (getPriorityLevel(Priority_Level.P4)) {
- levels.add(Priority_Level.P4);
- }
- if (getPriorityLevel(Priority_Level.P5)) {
- levels.add(Priority_Level.P5);
- }
- return levels;
- }
- public void setFilterCompleteMode(boolean isFilterOn) {
- getPrefs().setValue(FILTER_COMPLETE_MODE, isFilterOn);
- }
-
- public boolean isFilterCompleteMode() {
- if (getPrefs().contains(FILTER_COMPLETE_MODE)) {
- return getPrefs().getBoolean(FILTER_COMPLETE_MODE);
- } else {
- return false;
- }
- }
-
- public void setFilterInCompleteMode(boolean isFilterOn) {
- getPrefs().setValue(FILTER_INCOMPLETE_MODE, isFilterOn);
- }
-
- public boolean isFilterInCompleteMode() {
- if (getPrefs().contains(FILTER_INCOMPLETE_MODE)) {
- return getPrefs().getBoolean(FILTER_INCOMPLETE_MODE);
- } else {
- return false;
- }
- }
-}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/RelatedLinks.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/RelatedLinks.java
deleted file mode 100644
index 1e11116dc..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/RelatedLinks.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-package org.eclipse.mylar.tasks;
-
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * Related links stored for each task used as input to the Table
- * used in the TaskSummaryEditor
- *
- * @author Ken Sueda
- */
-public class RelatedLinks {
- private List<String> links;
-
- public RelatedLinks() {
- links = new ArrayList<String>();
- }
- public void add(String link) {
- links.add(link);
- }
- public List<String> getLinks() {
- return links;
- }
- public void remove(String link) {
- links.remove(link);
- }
-}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/Task.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/Task.java
deleted file mode 100644
index e9509c4e8..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/Task.java
+++ /dev/null
@@ -1,298 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on Dec 22, 2004
- */
-package org.eclipse.mylar.tasks;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.mylar.core.MylarPlugin;
-import org.eclipse.mylar.tasks.ui.TaskEditorInput;
-import org.eclipse.mylar.tasks.ui.views.TaskListView;
-import org.eclipse.mylar.ui.MylarImages;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.ui.IEditorInput;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.internal.Workbench;
-
-
-/**
- * @author Mik Kersten
- */
-public class Task implements ITask, ITaskListElement {
-
- private static final long serialVersionUID = 3545518391537382197L;
- private boolean active = false;
- protected String handle = "-1";
- private boolean category = false;
-
-
- /**
- * Either to local resource or URL.
- * TODO: consider changing to java.net.URL
- */
- private String path;
- private String label;
- private String priority = "P3";
- private String notes = "";
- private String estimatedTime = "";
- private String elapsedTime = "";
- private boolean completed;
- private RelatedLinks links = new RelatedLinks();
- private TaskCategory parentCategory = null;
-
- /**
- * null if root
- */
- private transient ITask parent;
-
- private List<ITask> children = new ArrayList<ITask>();
-
- @Override
- public String toString() {
- return label;
- }
-
- public String getPath() {
- // returns relative path Mylar Directory
- return path;
- }
-
- public void setPath(String path) {
- if (path.startsWith(".mylar")) {
- this.path = path.substring(path.lastIndexOf('/')+1, path.length());
- } else if (!path.equals("")) {
- this.path = path;
- }
- }
-
- public Task(String handle, String label) {
- this.handle = handle;
- this.label = label;
- this.path = handle;
- }
-
- public String getHandle() {
- return handle;
- }
- public void setHandle(String id) {
- this.handle = id;
- }
- public String getLabel() {
- return label;
- }
- public void setLabel(String label) {
- this.label = label;
- }
-
- public ITask getParent() {
- return parent;
- }
-
- public void setParent(ITask parent) {
- this.parent = parent;
- }
- public Object getAdapter(Class adapter) {
- return null;
- }
-
- /**
- * Package visible in order to prevent sets that don't update the index.
- */
- public void setActive(boolean active) {
- this.active = active;
- }
-
- public boolean isActive() {
- return active;
- }
-
- public void openTaskInEditor() {
- Workbench.getInstance().getDisplay().asyncExec(new Runnable() {
- public void run() {
- openTaskEditor();
- }
- });
- }
-
- /**
- * Opens the task in an editor.
- * @return Resulting <code>IStatus</code> of the operation
- */
- protected void openTaskEditor() {
-
- // get the active page so that we can reuse it
- IWorkbenchPage page = MylarTasksPlugin.getDefault().getWorkbench().getActiveWorkbenchWindow().getActivePage();
-
- // if we couldn't get a page, get out
- if (page == null) {
- return;
- }
-
- IEditorInput input = new TaskEditorInput(this);
- try
- {
- // try to open an editor on the input task
- page.openEditor(input, MylarTasksPlugin.TASK_EDITOR_ID);
-
- }
- catch (PartInitException ex)
- {
- MylarPlugin.log(ex, "open failed");
- }
- }
-
- /**
- * Refreshes the tasklist viewer.
- */
- public void notifyTaskDataChange() {
- final Task task = this;
- Workbench.getInstance().getDisplay().asyncExec(new Runnable() {
- public void run() {
- if (TaskListView.getDefault() != null) TaskListView.getDefault().notifyTaskDataChanged(task);
- }
- });
- }
-
- public String getToolTipText() {
- // No tool-tip used for a general task as of yet.
- return null;
- }
-
- @Override
- public boolean equals(Object obj) {
- if (obj instanceof Task && obj != null) {
- return this.getHandle() == ((Task)obj).getHandle();
- } else {
- return false;
- }
- }
-
- @Override
- public int hashCode() {
- return this.getHandle().hashCode();
- }
- public boolean isCompleted() {
- return completed;
- }
- public void setCompleted(boolean completed) {
- this.completed = completed;
- }
-
- public boolean isCategory() {
- return category;
- }
-
- public void setIsCategory(boolean category) {
- this.category = category;
- }
-
- public String getPriority() {
- return priority;
- }
-
- public void setPriority(String priority) {
- this.priority = priority;
- }
-
- public RelatedLinks getRelatedLinks() {
- // TODO: removed check for null once xml updated.
- if (links == null) {
- links = new RelatedLinks();
- }
- return links;
- }
-
- public void setRelatedLinks(RelatedLinks relatedLinks) {
- this.links = relatedLinks;
- }
-
- public void addLink(String url) {
- links.add(url);
- }
-
- public void removeLink(String url) {
- links.remove(url);
- }
-
- public String getNotes() {
- // TODO: removed check for null once xml updated.
- if (notes == null) {
- notes = "";
- }
- return notes;
- }
-
- public void setNotes(String notes) {
- this.notes = notes;
- }
-
- public String getElapsedTime() {
- if (elapsedTime == null) {
- elapsedTime = "";
- }
- return elapsedTime;
- }
-
- public void setElapsedTime(String elapsed) {
- this.elapsedTime = elapsed;
- }
-
- public String getEstimatedTime() {
- if (estimatedTime == null) {
- estimatedTime = "";
- }
- return estimatedTime;
- }
-
- public void setEstimatedTime(String estimated) {
- this.estimatedTime = estimated;
- }
-
- public List<ITask> getChildren() {
- return children;
- }
-
- public void addSubTask(ITask t) {
- children.add(t);
- }
-
- public void removeSubTask(ITask t) {
- children.remove(t);
- }
-
- public void setCategory(TaskCategory cat) {
- this.parentCategory = cat;
- }
-
- public TaskCategory getCategory() {
- return parentCategory;
- }
-
- public Image getIcon() {
- return MylarImages.getImage(MylarImages.TASK);
- }
-
- public String getDescription(boolean label) {
- return getLabel();
- }
-
- public Image getStatusIcon() {
- if (isActive()) {
- return MylarImages.getImage(MylarImages.TASK_ACTIVE);
- } else {
- return MylarImages.getImage(MylarImages.TASK_INACTIVE);
- }
- }
-}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/TaskCategory.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/TaskCategory.java
deleted file mode 100644
index 5562381d1..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/TaskCategory.java
+++ /dev/null
@@ -1,72 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on Dec 26, 2004
- */
-package org.eclipse.mylar.tasks;
-
-import java.io.Serializable;
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.mylar.ui.MylarImages;
-import org.eclipse.swt.graphics.Image;
-
-
-/**
- * @author Mik Kersten
- */
-public class TaskCategory extends AbstractCategory implements Serializable {
-
- private static final long serialVersionUID = 3834024740813027380L;
-
- private List<ITask> tasks = new ArrayList<ITask>();
-
- public TaskCategory(String description) {
- super(description);
- }
-
- public Image getIcon() {
- return MylarImages.getImage(MylarImages.CATEGORY);
- }
-
- public void addTask(ITask task) {
- if(task instanceof BugzillaTask){
- BugzillaTask bugTask = MylarTasksPlugin.getTaskListManager().getTaskList().getFromBugzillaTaskRegistry(task.getHandle());
- if(bugTask == null){
- MylarTasksPlugin.getTaskListManager().getTaskList().addToBugzillaTaskRegistry((BugzillaTask)task);
- } else {
- task = bugTask;
- }
- }
- tasks.add(task);
-
- }
-
- public void removeTask(ITask task) {
- tasks.remove(task);
- }
-
- public List<ITask> getChildren() {
- return tasks;
- }
-
- @Override
- public boolean equals(Object object) {
- if (object == null) return false;
- if (object instanceof TaskCategory) {
- TaskCategory compare = (TaskCategory)object;
- return this.getDescription(false).equals(compare.getDescription(false));
- } else {
- return false;
- }
- }
-}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/TaskList.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/TaskList.java
deleted file mode 100644
index e7c525052..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/TaskList.java
+++ /dev/null
@@ -1,194 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on Dec 22, 2004
- */
-package org.eclipse.mylar.tasks;
-
-import java.io.Serializable;
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-
-/**
- * @author Mik Kersten
- */
-public class TaskList implements Serializable {
-
- private static final long serialVersionUID = 3618984485791021105L;
-
- private List<ITask> rootTasks = new ArrayList<ITask>();
- private List<AbstractCategory> categories = new ArrayList<AbstractCategory>();
- private transient List<ITask> activeTasks = new ArrayList<ITask>();
-
- // XXX we never delete anything from this registry
- private Map<String, BugzillaTask> bugzillaTaskRegistry = new HashMap<String, BugzillaTask>();
-
- public void addToBugzillaTaskRegistry(BugzillaTask task){
- if(bugzillaTaskRegistry.get(task.getHandle()) == null){
- bugzillaTaskRegistry.put(task.getHandle(), task);
- }
- }
-
- public BugzillaTask getFromBugzillaTaskRegistry(String handle){
- return bugzillaTaskRegistry.get(handle);
- }
-
- public Map<String, BugzillaTask> getBugzillaTaskRegistry(){
- return bugzillaTaskRegistry;
- }
-
- public void addRootTask(ITask task) {
- if(task instanceof BugzillaTask){
- BugzillaTask bugTask = bugzillaTaskRegistry.get(task.getHandle());
- if(bugTask == null){
- bugzillaTaskRegistry.put(task.getHandle(), (BugzillaTask)task);
- rootTasks.add(task);
- } else {
- rootTasks.add(bugTask);
- }
- } else {
- rootTasks.add(task);
- }
- }
-
- public void addCategory(AbstractCategory cat) {
- categories.add(cat);
- }
-
- public void setActive(ITask task, boolean active) {
- task.setActive(active);
- if (active) {
- activeTasks.add(task);
- } else {
- activeTasks.remove(task);
- }
- }
-
- public void deleteTask(ITask task) {
- boolean deleted = deleteTaskHelper(rootTasks, task);
- if (!deleted) {
- for (TaskCategory cat : getTaskCategories()) {
- deleted = deleteTaskHelper(cat.getChildren(), task);
- if (deleted) {
- return;
- }
- }
- }
- }
-
- private boolean deleteTaskHelper(List<ITask> tasks, ITask t) {
- for (ITask task : tasks) {
- if (task.getHandle().equals(t.getHandle())) {
- tasks.remove(task);
- return true;
- } else {
- if (deleteTaskHelper(task.getChildren(), t))
- return true;
- }
- }
- return false;
- }
-
- public void deleteCategory(AbstractCategory category) {
- categories.remove(category);
- }
- /**
- * TODO: make data structure handle this traversal
- */
- public ITask getTaskForId(String id) {
- ITask t = null;
- for (TaskCategory cat : getTaskCategories()) {
- if ((t = findTaskHelper(cat.getChildren(), id)) != null) {
- return t;
- }
- }
- return findTaskHelper(rootTasks, id);
- }
-
- private ITask findTaskHelper(List<ITask> tasks, String id) {
- for (ITask task : tasks) {
- if (task.getHandle() == id) {
- return task;
- }
- ITask t = findTaskHelper(task.getChildren(), id);
- if (t != null) {
- return t;
- }
- }
- return null;
- }
-
- public List<ITask> getActiveTasks() {
- return activeTasks;
- }
-
- public List<ITask> getRootTasks() {
- return rootTasks;
- }
-
- public List<AbstractCategory> getCategories() {
- return categories;
- }
-
- public int findLargestTaskHandle() {
- int max = 0;
- max = Math.max(largestTaskHandleHelper(rootTasks), max);
- for (TaskCategory cat : getTaskCategories()) {
- max = Math.max(largestTaskHandleHelper(cat.getChildren()), max);
- }
- return max;
- }
-
- private int largestTaskHandleHelper(List<ITask> tasks) {
- int ihandle = 0;
- int max = 0;
- for (ITask t : tasks) {
- if (t instanceof BugzillaTask) {
- ihandle = 0;
- } else {
- ihandle = Integer.parseInt(t.getHandle().substring(t.getHandle().indexOf('-')+1, t.getHandle().length()));
- }
- max = Math.max(ihandle, max);
- ihandle = largestTaskHandleHelper(t.getChildren());
- max = Math.max(ihandle, max);
- }
- return max;
- }
-
- public List<Object> getRoots() {
- List<Object> roots = new ArrayList<Object>();
- for (ITask t : rootTasks) {
- roots.add(t);
- }
- for (AbstractCategory cat : categories) {
- roots.add(cat);
- }
- return roots;
- }
-
- public void createCategory(String description) {
- TaskCategory c = new TaskCategory(description);
- categories.add(c);
- }
-
- public List<TaskCategory> getTaskCategories() {
- List<TaskCategory> cats = new ArrayList<TaskCategory>();
- for (AbstractCategory cat : categories) {
- if (cat instanceof TaskCategory) {
- cats.add((TaskCategory)cat);
- }
- }
- return cats;
- }
-}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/TaskListManager.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/TaskListManager.java
deleted file mode 100644
index b1dd5f9b0..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/TaskListManager.java
+++ /dev/null
@@ -1,163 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on Dec 26, 2004
- */
-package org.eclipse.mylar.tasks;
-
-import java.io.File;
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.mylar.core.MylarPlugin;
-import org.eclipse.mylar.tasks.util.RelativePathUtil;
-import org.eclipse.mylar.tasks.util.XmlUtil;
-
-
-/**
- * @author Mik Kersten
- */
-public class TaskListManager {
-
- private File file;
- private TaskList taskList = new TaskList();
- private List<ITaskActivityListener> listeners = new ArrayList<ITaskActivityListener>();
- private int nextTaskId;
-
- public TaskListManager(File file) {
- this.file = file;
- if (MylarPlugin.getDefault().getPreferenceStore().contains(MylarTasksPlugin.TASK_ID)) { // TODO: fix to MylarTasksPlugin
- nextTaskId = MylarPlugin.getDefault().getPreferenceStore().getInt(MylarTasksPlugin.TASK_ID);
- } else {
- nextTaskId = 1;
- }
- }
-
- public TaskList createNewTaskList() {
- return taskList;
- }
-
- public String genUniqueTaskId() {
- return "task-" + nextTaskId++;
- }
-
- public boolean readTaskList() {
- try {
- if (file.exists()) {
- XmlUtil.readTaskList(taskList, file);
- int maxHandle = taskList.findLargestTaskHandle();
- if (maxHandle >= nextTaskId) {
- nextTaskId = maxHandle + 1;
- }
- for (ITaskActivityListener listener : listeners) listener.tasksActivated(taskList.getActiveTasks());
- }
- return true;
- } catch (Exception e) {
- MylarPlugin.log(e, "task read failed");
- return false;
- }
- }
-
- public void saveTaskList() {
- try {
- XmlUtil.writeTaskList(taskList, file);
- MylarPlugin.getDefault().getPreferenceStore().setValue(MylarTasksPlugin.TASK_ID, nextTaskId);
- } catch (Exception e) {
- e.printStackTrace(); // TODO: fix
-// MylarPlugin.fail(e, "Could not save task list", true);
- }
- }
-
- public TaskList getTaskList() {
- return taskList;
- }
-
- public void setTaskList(TaskList taskList) {
- this.taskList = taskList;
- }
-
- public void deleteTask(ITask task) {
- taskList.setActive(task, false);
- taskList.deleteTask(task);
- }
-
- public void deleteCategory(AbstractCategory cat) {
- taskList.deleteCategory(cat);
- }
-
- public void addListener(ITaskActivityListener listener) {
- listeners.add(listener);
- }
-
- public void removeListener(ITaskActivityListener listener) {
- listeners.remove(listener);
- }
-
- public void activateTask(ITask task) {
- taskList.setActive(task, true);
- for (ITaskActivityListener listener : listeners) listener.taskActivated(task);
- }
-
- public void deactivateTask(ITask task) {
- taskList.setActive(task, false);
- for (ITaskActivityListener listener : listeners) listener.taskDeactivated(task);
- }
-
- public void taskPropertyChanged(ITask task, String property) {
- for (ITaskActivityListener listener : listeners) listener.taskPropertyChanged(task, property);
- }
-
- public void updateTaskscapeReference(String prevDir) {
- List<ITask> rootTasks = this.getTaskList().getRootTasks();
- for (TaskCategory cat : taskList.getTaskCategories()) {
- updateTaskscapeReferenceHelper(cat.getChildren(), prevDir);
- }
- updateTaskscapeReferenceHelper(rootTasks, prevDir);
-
- }
- public void updateTaskscapeReferenceHelper(List<ITask> list, String prevDir) {
- for (ITask task : list) {
- if (!task.getPath().startsWith("task-")) {
- if (task.getPath().startsWith("..")) {
- String path = task.getPath();
- File d = new File(prevDir);
- while (path.startsWith("..")) {
- d = d.getParentFile();
- path = path.substring(3, path.length());
- }
-
- String absPath = d.getPath() + "/" + path + MylarTasksPlugin.FILE_EXTENSION;
- absPath = absPath.replaceAll("\\\\", "/");
- String rel = RelativePathUtil.findRelativePath(MylarPlugin.getDefault().getUserDataDirectory() + "/", absPath);
- task.setPath(rel);
- taskPropertyChanged(task, "Path");
- } else {
- String absPath = prevDir + "/" + task.getPath() + MylarTasksPlugin.FILE_EXTENSION;
- absPath = absPath.replaceAll("\\\\", "/");
- String rel = RelativePathUtil.findRelativePath(MylarPlugin.getDefault().getUserDataDirectory(), absPath);
- task.setPath(rel);
- taskPropertyChanged(task, "Path");
- }
- }
-// updateTaskscapeReferenceHelper(task.getChildren(), prevDir);
- }
- }
- public void setFile(File f) {
- if (this.file.exists()) {
- this.file.delete();
- }
- this.file = f;
- }
-
- public void activateHit(BugzillaHit hit) {
-
- }
-}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaCacheFile.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaCacheFile.java
deleted file mode 100644
index 7da0be56e..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaCacheFile.java
+++ /dev/null
@@ -1,131 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-package org.eclipse.mylar.tasks.bugzilla;
-
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.io.ObjectInputStream;
-import java.io.ObjectOutputStream;
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.mylar.bugzilla.BugzillaPlugin;
-import org.eclipse.mylar.bugzilla.core.IBugzillaBug;
-
-/**
- * COPIED FROM @see org.eclipse.mylar.bugzilla.offlineReports.OfflineReportsFile
- *
- * @author Shawn Minto
- */
-public class BugzillaCacheFile {
-
- private File file;
-
- private ArrayList<IBugzillaBug> list = new ArrayList<IBugzillaBug>();
-
- protected int latestNewBugId = 0;
-
- public BugzillaCacheFile(File file) throws ClassNotFoundException, IOException {
- this.file = file;
- if (file.exists()) {
- readFile();
- }
- }
-
- public void add(IBugzillaBug entry) {
- // add the entry to the list and write the file to disk
- list.add(entry);
- writeFile();
- }
-
- public void update() {
- writeFile();
- }
-
- public int getNextOfflineBugId() {
- latestNewBugId++;
- return latestNewBugId;
- }
-
- public int find(int id) {
- for (int i = 0; i < list.size(); i++) {
- IBugzillaBug currBug = list.get(i);
- if (currBug != null && (currBug.getId() == id) && !currBug.isLocallyCreated())
- return i;
- }
- return -1;
- }
-
- public ArrayList<IBugzillaBug> elements() {
- return list;
- }
-
- private void writeFile() {
- try {
- ObjectOutputStream out = new ObjectOutputStream(new FileOutputStream(file));
-
- // Write the size of the list so that we can read it back in easier
- out.writeInt(list.size());
-
- out.writeInt(latestNewBugId);
-
- // write each element in the array list
- for (int i = 0; i < list.size(); i++) {
- Object item = list.get(i);
- out.writeObject(item);
- }
- out.close();
- }
- catch (IOException e) {
- // put up a message and log the error if there is a problem writing to the file
- MessageDialog.openError(null,
- "I/O Error",
- "Bugzilla could not write to offline reports file.");
- BugzillaPlugin.log(e);
- }
- }
-
- private void readFile() throws ClassNotFoundException, IOException {
- ObjectInputStream in = new ObjectInputStream(new FileInputStream(file));
-
- // get the number of offline reports in the file
- int size = in.readInt();
-
- // get the bug id of the most recently created offline report
- latestNewBugId = in.readInt();
-
- // read in each of the offline reports in the file
- for (int nX = 0; nX < size; nX++) {
- IBugzillaBug item = (IBugzillaBug) in.readObject();
- // add the offline report to the offlineReports list
- list.add(item);
- }
- in.close();
- }
-
- public void remove(List<IBugzillaBug> sel) {
- list.removeAll(sel);
-
- // rewrite the file so that the data is persistant
- writeFile();
- }
-
- public void removeAll() {
- list.clear();
-
- // rewrite the file so that the data is persistant
- writeFile();
- }
-}
-
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaContentProvider.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaContentProvider.java
deleted file mode 100644
index 4a0b4a40e..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaContentProvider.java
+++ /dev/null
@@ -1,59 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on Jan 13, 2005
- */
-package org.eclipse.mylar.tasks.bugzilla;
-
-import org.eclipse.mylar.bugzilla.core.BugReport;
-import org.eclipse.mylar.tasks.BugzillaTask;
-
-
-/**
- * @author Mik Kersten
- * @author Eric Booth
- */
-public class BugzillaContentProvider {
-
- public BugzillaContentProvider() {
- // don't have any initialization to do
- }
-
- /**
- * @return String containing bug priority and label, e.g. "[12345] P2: fix failing test"
- */
- public String getBugzillaDescription(BugzillaTask bugTask) {
- if (bugTask == null) return "<no info>";
-
- String prefix = //((bugTask.isDirty()) ? ">" : "") +
- BugzillaTask.getBugId(bugTask.getHandle()) + ": ";
-
- if (bugTask.getState() == BugzillaTask.BugTaskState.DOWNLOADING) {
- return prefix + ": <Downloading bug report from server...>";
- } else if (bugTask.getState() == BugzillaTask.BugTaskState.OPENING) {
- return prefix + ": <Opening bug report in editor...>";
- } else if (bugTask.getState() == BugzillaTask.BugTaskState.COMPARING) {
- return prefix + ": <Comparing bug report with server...>";
- } else if (bugTask.getState() == BugzillaTask.BugTaskState.WAITING) {
- return prefix + ": <Waiting to check server...>";
- }
-
- // generate the label
- if (bugTask.isBugDownloaded()) {
- BugReport report = bugTask.getBugReport();
- return prefix + report.getSummary();
- }
- else {
- return prefix + ": <could not find bug>";
- }
- }
-
-}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaEditingMonitor.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaEditingMonitor.java
deleted file mode 100644
index 8eadb4e55..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaEditingMonitor.java
+++ /dev/null
@@ -1,46 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on Apr 27, 2005
- */
-package org.eclipse.mylar.tasks.bugzilla;
-
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.mylar.bugzilla.ui.editor.AbstractBugEditor;
-import org.eclipse.mylar.bugzilla.ui.outline.BugzillaReportSelection;
-import org.eclipse.mylar.core.AbstractSelectionMonitor;
-import org.eclipse.mylar.tasks.ui.BugzillaTaskEditor;
-import org.eclipse.ui.IWorkbenchPart;
-
-
-/**
- * @author Mik Kersten
- */
-public class BugzillaEditingMonitor extends AbstractSelectionMonitor {
-
- public BugzillaEditingMonitor() {
- super();
- }
-
- @Override
- protected void handleWorkbenchPartSelection(IWorkbenchPart part, ISelection selection) {
- if(!(part instanceof AbstractBugEditor) && !(part instanceof BugzillaTaskEditor))
- return;
-
- if(selection instanceof StructuredSelection){
- StructuredSelection ss = (StructuredSelection)selection;
- Object object = ss.getFirstElement();
- if(object instanceof BugzillaReportSelection) super.handleElementSelection(part, object);
- }
- }
-
-}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaMylarBridge.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaMylarBridge.java
deleted file mode 100644
index 6dc4033b9..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaMylarBridge.java
+++ /dev/null
@@ -1,142 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on Oct 1, 2004
- */
-package org.eclipse.mylar.tasks.bugzilla;
-
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.jdt.core.IJavaElement;
-import org.eclipse.jdt.core.IMember;
-
-
-/**
- * Class to handle the bridge between mylar and bugzilla
- *
- * @author Shawn Minto
- */
-public class BugzillaMylarBridge {
-
- /** The hash of all of the landmarks and their related search hits */
- private HashMap<String, Map<Integer, List<BugzillaReportNode>>> landmarksHash;
- /**
- * The currently running search jobs so that we can cancel it if necessary <br> KEY: IMember VALUE: Job
- */
- public static HashMap<String, Job> runningJobs = new HashMap<String, Job>();
-
- /**
- * Constructor
- */
- public BugzillaMylarBridge() {
- landmarksHash = new HashMap<String, Map<Integer, List<BugzillaReportNode>>>();
- }
-
-
- /**
- * Remove a landmark from the hash
- *
- * @param removed
- * This landmark to remove (IJavaElement)
- */
- public void removeFromLandmarksHash(IJavaElement removed) {
- landmarksHash.remove(removed.getHandleIdentifier());
- }
-
- /**
- * Remove all of the landmarks from the hash that are in the list
- *
- * @param removed
- * This list of landmarks to remove (IJavaElements)
- */
- public void removeFromLandmarksHash(List<IJavaElement> removed) {
-
- for(IJavaElement je : removed) {
- landmarksHash.remove(je.getHandleIdentifier());
- }
- }
-
- /**
- * Add data to the landmarks hash
- *
- * @param doiList
- * The list of BugzillaSearchHitDoiInfo
- * @param m
- * The member that this list is for
- */
- public void addToLandmarksHash(List<BugzillaReportNode> doiList, IMember m, int scope) {
- Map<Integer, List<BugzillaReportNode>> searches = landmarksHash.get(m.getHandleIdentifier());
-
- if(searches == null){
- searches = new HashMap<Integer, List<BugzillaReportNode>>();
- }
- searches.put(scope, doiList);
- landmarksHash.put(m.getHandleIdentifier(), searches);
- }
-
- /**
- * Get the doiList for the given IMember from the landmarks hash
- *
- * @param m
- * The member to get the doiList for
- * @return The doiList or null if it doesn't exist
- */
- public List<BugzillaReportNode> getFromLandmarksHash(IMember m, int scope) {
- Map<Integer, List<BugzillaReportNode>> scopes = landmarksHash.get(m.getHandleIdentifier());
- if(scopes == null)
- return null;
- else
- return scopes.get(scope);
- }
-
- /**
- * Determine whether the current element has a search job running for it
- *
- * @param e
- * The element that we want to know whether there is a search job
- * or not
- * @return <code>true</code> if it does else <code>false</code>
- */
- public static boolean doesJobExist(String handle) {
- return runningJobs.containsKey(handle);
- }
-
- /**
- * Remove search job for the given element
- *
- * @param m
- * The element that we want to make sure that the search is
- * canceled for
- */
- public static void removeSearchJob(String handle) {
-
- // make sure that there wasn't a previous search job that we know
- // of. If there was, cancel it
- if (doesJobExist(handle)) {
- // get the search job and wait until it is cancelled
- Job prevJob = runningJobs.get(handle);
- prevJob.cancel();
- runningJobs.remove(handle);
- }
- }
-
- /**
- * Add a search job to our list
- * @param handle The handle of the element that we are searching for
- * @param searchJob The job that represents the search
- */
- public static void addJob(String handle, Job searchJob) {
- runningJobs.put(handle, searchJob);
- }
-} \ No newline at end of file
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaReferencesProvider.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaReferencesProvider.java
deleted file mode 100644
index 6b810f142..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaReferencesProvider.java
+++ /dev/null
@@ -1,142 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on Feb 2, 2005
- */
-package org.eclipse.mylar.tasks.bugzilla;
-
-import java.util.Collection;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-
-import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.jdt.core.IJavaElement;
-import org.eclipse.jdt.core.IMember;
-import org.eclipse.jdt.core.IType;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.mylar.core.model.ITaskscapeNode;
-import org.eclipse.mylar.core.search.IActiveSearchListener;
-import org.eclipse.mylar.core.search.IMylarSearchOperation;
-import org.eclipse.mylar.core.search.RelationshipProvider;
-import org.eclipse.mylar.tasks.MylarTasksPlugin;
-import org.eclipse.mylar.tasks.bugzilla.search.BugzillaMylarSearch;
-
-
-/**
- * @author Shawn Minto
- */
-public class BugzillaReferencesProvider extends RelationshipProvider {
-
- public static final String ID = "org.eclipse.mylar.bugzilla.search.references";
- public static final String NAME = "Bugilla report references";
-
- public BugzillaReferencesProvider() {
- super(BugzillaStructureBridge.EXTENSION, ID);
- }
-
- protected boolean acceptElement(IJavaElement javaElement) {
- return javaElement != null
- && (javaElement instanceof IMember || javaElement instanceof IType);
- }
-
- /**
- * HACK: checking kind as string - don't want the dependancy to mylar.java
- */
- @Override
- protected void findRelated(final ITaskscapeNode node, int degreeOfSeparation) {
- if (!node.getStructureKind().equals("java")) return;
- IJavaElement javaElement = JavaCore.create(node.getElementHandle());
- if (!acceptElement(javaElement)) {
- return;
- }
- runJob(node, degreeOfSeparation);
-
- //XXX what if degreeOfSeparation is 5?
- }
-
- @Override
- public IMylarSearchOperation getSearchOperation(ITaskscapeNode node, int limitTo, int degreeOfSepatation) {
- IJavaElement javaElement = JavaCore.create(node.getElementHandle());
- return new BugzillaMylarSearch(degreeOfSepatation, javaElement);
- }
-
- private void runJob(final ITaskscapeNode node, final int degreeOfSeparation) {
- BugzillaMylarSearch search = (BugzillaMylarSearch)getSearchOperation(node, 0, degreeOfSeparation);
-
- search.addListener(new IActiveSearchListener(){
-
- private boolean gathered = false;
-
- public void searchCompleted(List<?> nodes) {
- Iterator<?> itr = nodes.iterator();
-
- BugzillaStructureBridge bridge = MylarTasksPlugin.getDefault().getStructureBridge();
-
- while(itr.hasNext()) {
- Object o = itr.next();
- if(o instanceof BugzillaReportNode){
- BugzillaReportNode bugzillaNode = (BugzillaReportNode)o;
- String handle = bugzillaNode.getElementHandle();
- if(bridge.getCached(handle) == null)
- cache(handle, bugzillaNode);
- incrementInterest(degreeOfSeparation, BugzillaStructureBridge.EXTENSION, handle);
- }
- }
- gathered = true;
- }
-
- public boolean resultsGathered() {
- return gathered;
- }
-
- });
- search.run(new NullProgressMonitor());
- }
-
- @Override
- protected String getSourceId() {
- return ID;
- }
-
- @Override
- public String getName() {
- return NAME;
- }
-
- /*
- *
- * STUFF FOR TEMPORARILY CACHING A PROXY REPORT
- *
- * TODO remove the proxys and update the BugzillaStructureBridge cache so that on restart,
- * we dont have to get all of the bugs
- *
- */
- private static final Map<String, BugzillaReportNode> reports = new HashMap<String, BugzillaReportNode>();
-
- public BugzillaReportNode getCached(String handle){
- return reports.get(handle);
- }
-
- protected void cache(String handle, BugzillaReportNode bugzillaNode) {
- reports.put(handle, bugzillaNode);
- }
-
- public void clearCachedReports(){
- reports.clear();
- }
-
- public Collection<? extends String> getCachedHandles() {
- return reports.keySet();
- }
-
-}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaReportNode.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaReportNode.java
deleted file mode 100644
index 6ac4c26a5..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaReportNode.java
+++ /dev/null
@@ -1,184 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on Oct 21, 2004
- */
-package org.eclipse.mylar.tasks.bugzilla;
-
-import java.io.IOException;
-import java.net.MalformedURLException;
-import java.util.ArrayList;
-import java.util.List;
-
-import javax.security.auth.login.LoginException;
-
-import org.eclipse.mylar.bugzilla.core.BugReport;
-import org.eclipse.mylar.bugzilla.core.BugzillaRepository;
-import org.eclipse.mylar.bugzilla.search.BugzillaSearchHit;
-
-
-/**
- * Class to store the DoiInfo of a BugzillaSearchHit
- *
- * @author Shawn Minto
- */
-public class BugzillaReportNode {
-
- private static final long serialVersionUID = 3257004367222419506L;
-
- /** The BugzillaSearchHit associated with this DoiInfo */
- private BugzillaSearchHit hit;
-
- /** Whether this search hit was from an exact search like a stack trace */
- private boolean isExact = false;
-
- /** List of all of the StackTrace's in the given bug */
- private List<StackTrace> stackTraces;
-
- /** The bug report associated with this DoiInfo */
- private BugReport bug;
-
- /**
- * Constructor
- *
- * @param initialValue
- * The initial Doi value
- * @param hit
- * The BugzillaSearchHit associated with this DoiInfo
- * @param isExact
- * Whether the search was exact or not
- */
- public BugzillaReportNode(float initialValue, BugzillaSearchHit hit,
- boolean isExact) {
- this.hit = hit;
- this.isExact = isExact;
- bug = null;
- stackTraces = new ArrayList<StackTrace>();
- }
-
- /**
- * Get the bugzilla search hit relating to this DoiInfo
- *
- * @return The BugzillaSearchHit related to this DoiInfo
- */
- public BugzillaSearchHit getHit() {
- return hit;
- }
-
- @Override
- public String toString() {
- return hit.toString();
- }
-
- /**
- * Determine if the search hit this represents is exact or not
- *
- * @return <code>true</code> if the search was exact otherwise
- * <code>false</code>
- */
- public boolean isExact() {
- return isExact;
- }
-
- /**
- * Set whether this bug has any exact elements in it - the search used was fully qualified
- *
- * @param isExact -
- * Whether there are any exact element matches in it
- */
- public void setExact(boolean isExact) {
- this.isExact = isExact;
- }
-
- /**
- * Get the bug report associated with this DoiInfo<br>
- * The bug is downloaded if it was not previously
- *
- * @return Returns the BugReport
- *
- * @throws IOException
- * @throws LoginException
- * @throws MalformedURLException
- */
- public BugReport getBug() throws MalformedURLException, LoginException, IOException {
- if(bug == null){
-
- // get the bug report
- bug = BugzillaRepository.getInstance().getBug(
- hit.getId());
- }
- return bug;
- }
-
- /**
- * Set the bug report associated with this DoiInfo
- *
- * @param bug -
- * BugReport that this is associated with
- */
- public void setBug(BugReport bug) {
- this.bug = bug;
- }
-
- /**
- * Get all of the stack traces contained in the bug
- *
- * @return Returns a list of StackTrace's
- */
- public List<StackTrace> getStackTraces() {
- return stackTraces;
- }
-
- /**
- * Determine whether the doi info has any stack traces associated with it
- * @return <code>true</code> if there are some stack traces else <code>false</code>
- */
- public boolean hasStackTraces(){
- return !stackTraces.isEmpty();
- }
-
- /**
- * Add a stack trace to this DoiInfo
- *
- * @param stackTrace -
- * The StackTrace to add
- */
- public void addStackTrace(StackTrace stackTrace) {
- this.stackTraces.add(stackTrace);
- }
-
- /**
- * Add an array of stack traces to this DoiInfo
- *
- * @param stackTracesToAdd -
- * The StackTraces to add
- */
- public void addStackTraces(StackTrace[] stackTracesToAdd) {
- for (int i = 0; i < stackTracesToAdd.length; i++)
- this.stackTraces.add(stackTracesToAdd[i]);
- }
-
- /**
- * Get the name of the bug report
- * @return The name of the bug report, max 20 characters
- */
- public String getName() {
- final int MAX_LENGTH = 100;
- String description = hit.getDescription();
- int length = description.length();
- if (length > MAX_LENGTH) description = description.substring(0, MAX_LENGTH) + "..";
- return "bug " + hit.getId() + ": " + description;
- }
-
- public String getElementHandle() {
- return hit.getServer() + ";" + hit.getId();
- }
-} \ No newline at end of file
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaStructureBridge.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaStructureBridge.java
deleted file mode 100644
index b3b62224d..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/BugzillaStructureBridge.java
+++ /dev/null
@@ -1,278 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on May 2, 2005
- */
-package org.eclipse.mylar.tasks.bugzilla;
-
-import java.lang.reflect.InvocationTargetException;
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.Map;
-import java.util.Set;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.Platform;
-import org.eclipse.mylar.bugzilla.core.BugReport;
-import org.eclipse.mylar.bugzilla.core.BugzillaRepository;
-import org.eclipse.mylar.bugzilla.core.IBugzillaBug;
-import org.eclipse.mylar.bugzilla.search.BugzillaSearchHit;
-import org.eclipse.mylar.bugzilla.ui.editor.AbstractBugEditor;
-import org.eclipse.mylar.bugzilla.ui.outline.BugzillaOutlineNode;
-import org.eclipse.mylar.bugzilla.ui.outline.BugzillaReportSelection;
-import org.eclipse.mylar.bugzilla.ui.outline.BugzillaTools;
-import org.eclipse.mylar.core.IMylarStructureBridge;
-import org.eclipse.mylar.core.MylarPlugin;
-import org.eclipse.mylar.tasks.MylarTasksPlugin;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.actions.WorkspaceModifyOperation;
-import org.eclipse.ui.progress.IProgressService;
-import org.eclipse.ui.views.markers.internal.ProblemMarker;
-
-
-public class BugzillaStructureBridge implements IMylarStructureBridge {
-
- public final static String EXTENSION = "bugzilla";
-
- public String getResourceExtension() {
- return EXTENSION;
- }
-
- public BugzillaStructureBridge() {
- super();
- readCacheFile();
- }
-
- /**
- * Handle format: <server-name:port>;<bug-id>;<comment#>
- *
- * Use: BugzillaTools ???
- */
- public String getHandleIdentifier(Object object) {
- if(object instanceof BugzillaOutlineNode){
- BugzillaOutlineNode n = (BugzillaOutlineNode)object;
- return BugzillaTools.getHandle(n);
- }
- else if(object instanceof BugzillaReportSelection){
- BugzillaReportSelection n = (BugzillaReportSelection)object;
- return BugzillaTools.getHandle(n);
- }
- return null;
- }
-
- private BugReport result;
-
- public Object getObjectForHandle(final String handle) {
- result = null;
-
- String [] parts = handle.split(";");
- if (parts.length >= 2){
- String server = parts[0];
- final int id = Integer.parseInt(parts[1]);
-
- String bugHandle = server + ";" + id;
-
- int commentNumber = -1;
- if(parts.length == 3){
- commentNumber = Integer.parseInt(parts[2]);
- }
-
- // get the bugzillaOutlineNode for the element
- IEditorPart editorPart = null;
- try{
- editorPart = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage().getActiveEditor();
- }catch(NullPointerException e){
- // do nothing, this just means that there is no active page
- }
- if(editorPart != null && editorPart instanceof AbstractBugEditor){
- AbstractBugEditor abe = ((AbstractBugEditor)editorPart);
- BugzillaOutlineNode node = abe.getModel();
- return findNode(node, commentNumber);
- }
-
- // try to get from the cache, if it doesn't exist, startup an operation to get it
- result = getFromCache(bugHandle);
- if(result == null){
- WorkspaceModifyOperation op = new WorkspaceModifyOperation() {
- protected void execute(IProgressMonitor monitor) throws CoreException {
- monitor.beginTask("Downloading Bug# " + id, IProgressMonitor.UNKNOWN);
- try {
- result = BugzillaRepository.getInstance().getCurrentBug(id);
- }catch(Exception e){
- result = null;
- }
- }};
-
- // Use the progess service to execute the runnable
- IProgressService service = PlatformUI.getWorkbench().getProgressService();
- try {
- service.run(false, false, op);
- } catch (InvocationTargetException e) {
- // Operation was canceled
- } catch (InterruptedException e) {
- // Handle the wrapped exception
- }
-
- if(result != null)
- cache(bugHandle, result);
- }
-
- BugzillaOutlineNode node = BugzillaOutlineNode.parseBugReport(result);
- return findNode(node, commentNumber);
- }
- else{
- return null;
- }
- }
-
- private BugzillaOutlineNode findNode(BugzillaOutlineNode startNode, int commentNumber){
-
- if(commentNumber == -1){
- return startNode;
- }else if(startNode.getComment() != null && startNode.getComment().getNumber() == commentNumber -1){
- return startNode;
- } else if(startNode.isCommentHeader() && commentNumber == 1){
- return startNode;
- }else if(startNode.isDescription() && commentNumber == 0){
- return startNode;
- }
-
- BugzillaOutlineNode[] children = startNode.getChildren();
- for(int i = 0; i < children.length; i++){
- BugzillaOutlineNode n = findNode(children[i], commentNumber);
- if(n != null)
- return n;
- }
- return null;
- }
-
- public String getParentHandle(String handle) {
-
- //check so that we don't need to try to get the parent if we are already at the bug report
- if(!handle.matches(".*;.*;.*"))
- return null;
-
- BugzillaOutlineNode bon = (BugzillaOutlineNode)getObjectForHandle(handle);
- if(bon != null && bon.getParent() != null)
- return BugzillaTools.getHandle(bon.getParent());
- else
- return null;
-// String [] parts = handle.split(";");
-// if (parts.length == 1){
-// return null;
-// }else if (parts.length > 2) {
-// String newHandle = "";
-// for(int i = 0; i < parts.length - 1; i++)
-// newHandle += parts[i] + ";";
-// return newHandle.substring(0, newHandle.length() - 1);
-//// return handle.substring(0, handle.lastIndexOf(";"));
-// }
-// return null;
- }
-
- public String getName(Object object) {
- if(object instanceof BugzillaOutlineNode){
- BugzillaOutlineNode b = (BugzillaOutlineNode)object;
- return BugzillaTools.getName(b);
- } else if (object instanceof BugzillaReportNode){
- BugzillaSearchHit hit = ((BugzillaReportNode)object).getHit();
- return hit.getServer() + ": Bug#: " + hit.getId() + ": " + hit.getDescription();
- }
- return "";
- }
-
- public boolean canBeLandmark(Object element) {
- return false;
- }
-
- public boolean acceptsObject(Object object) {
- return object instanceof BugzillaOutlineNode || object instanceof BugzillaReportSelection;
- }
-
- public boolean canFilter(Object element) {
- return true;
- }
-
- public boolean isDocument(String handle) {
- return (handle.indexOf(';') == handle.lastIndexOf(';') && handle.indexOf(";") != -1);
- }
-
- public String getHandleForMarker(ProblemMarker marker) {
- return null;
- }
-
- public IProject getProjectForObject(Object object) {
- // bugzilla objects do not yet sit in a project
- return null;
- }
-
- public String getResourceExtension(String elementHandle) {
- return getResourceExtension();
- }
-
- /*
- *
- * STUFF FOR CACHING BUG REPORTS
- *
- */
-
- // bug report cache
- private Map<String, BugReport> cache = new HashMap<String, BugReport>();
-
- public void cache(String handle, BugReport report) {
- cache.put(handle, report);
- cacheFile.add(report);
- }
-
- public void clearCache(){
- cache.clear();
- cacheFile.removeAll();
- }
-
- private BugReport getFromCache(String bugHandle) {
- return cache.get(bugHandle);
- }
-
- public Set<String> getCachedHandles(){
- return cache.keySet();
- }
-
- private BugzillaCacheFile cacheFile;
-
- private IPath getCacheFile() {
- IPath stateLocation = Platform.getPluginStateLocation(MylarTasksPlugin.getDefault());
- IPath configFile = stateLocation.append("offlineReports");
- return configFile;
- }
-
- private void readCacheFile() {
- IPath cachPath = getCacheFile();
-
- try {
- cacheFile = new BugzillaCacheFile(cachPath.toFile());
- ArrayList<IBugzillaBug> cached = cacheFile.elements();
- for(IBugzillaBug bug: cached){
- if(bug instanceof BugReport)
- cache.put(BugzillaTools.getHandle(bug), (BugReport)bug);
- }
- } catch (Exception e) {
- MylarPlugin.log(e, "occurred while restoring saved offline Bugzilla reports.");
- }
- }
-
- public BugReport getCached(String handle) {
- return cache.get(handle);
- }
-}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/StackTrace.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/StackTrace.java
deleted file mode 100644
index 096c0c732..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/StackTrace.java
+++ /dev/null
@@ -1,375 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on Dec 8, 2004
- */
-package org.eclipse.mylar.tasks.bugzilla;
-
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * Class to hold all of the information about a stack trace
- *
- * @author Shawn Minto
- */
-public class StackTrace {
-
- /** The length of the stack trace in the original string */
- private int length;
-
- /** The offset of the stack trace in the orignal string */
- private int offset;
-
- /** The string of the stack trace */
- private String stackTrace;
-
- /** This is the comment that the stack trace appeared in. String if desciption else Comment */
- private Object comment;
-
- /**
- * Constructor
- *
- * @param stackTrace
- * The stack trace string
- * @param offset
- * The offset of the stack trace in the original string
- * @param length
- * The length of the stack trace in the original string
- * @param comment
- * The comment that the stack trace came from
- */
- public StackTrace(String stackTrace, int offset, int length, Object comment) {
- this.stackTrace = stackTrace;
- this.offset = offset;
- this.length = length;
- this.comment = comment;
- }
-
- /**
- * Get the offset for the stack trace
- *
- * @return Returns the offset.
- */
- public int getOffset() {
- return offset;
- }
-
- /**
- * Get the stack trace for the bug
- *
- * @return Returns the stackTrace.
- */
- public String getStackTrace() {
- return stackTrace;
- }
-
- /**
- * Get the length of the bug
- *
- * @return Returns the length.
- */
- public int getLength() {
- return length;
- }
-
- /**
- * Get the Comment that this stack trace came from
- *
- * @return Returns the Comment if it was a comment else a String if it was the description
- */
- public Object getComment() {
- return comment;
- }
-
- /**
- * Find a standard java stack trace in the given string
- *
- *
- * @param s
- * The string to search for stack traces
- * @param comment
- * The comment that the text came from.<br>
- * Comment if a comment else a String
- * @return String[] of stack traces - each element is 1 trace
- */
- public static StackTrace[] getStackTrace(String s, Object comment) {
-
- // setup the regex used to determine if it looks like we are at a
- // stack trace and whether it is something that should be skipped
- String regexExceptionType = "^(.*\\.)+.+(Exception|Error|Throwable).*";
- String regexSkip = ".*\\.\\..*";
-
- // get all of the individual lines for the string
- String[] lines = s.split("\r\n");
-
- // the character start of the current stack trace
- int charStackStart = 0;
-
- // the current character in the string - used for the start and the
- // offset
- int[] charPos = { 0 }; // array so pass by reference
-
- boolean inStackTrace = false;
- List<String> stackTrace = null;
- List<StackTrace> stackTraces = new ArrayList<StackTrace>();
-
- // go through each of the lines of the string
- for (int i = 0; i < lines.length; i++) {
-
- if (lines[i].matches(regexSkip)){
-
- // update the current character position
- charPos[0] += lines[i].length() + 2;
-
- }else if (lines[i].trim().matches(regexExceptionType) && !inStackTrace) {
-
- // we have matched the stack trace and we are not already in one
-
- // add the old stack trace to the list of stack traces
- if (stackTrace != null && stackTrace.size() > 1) {
- stackTraces.add(getStackTrace(stackTrace, charStackStart,
- charPos[0] - charStackStart, comment));
- }
-
- // prepare for a new stack trace
- stackTrace = new ArrayList<String>();
- inStackTrace = true;
-
- // the current line is the start of our stack trace
- stackTrace.add(lines[i]);
- charStackStart = charPos[0];
- charPos[0] += lines[i].length() + 2;
- } else if (inStackTrace) {
- // we are in a stack trace
-
- int[] pos = { i }; // array so pass by reference
-
- // get the next at clause of the stack trace
- String stack = getNextAt(lines, pos, charPos);
-
- // check if there was an at
- if (stack == null) {
-
- // there wasn't so we are done this stack trace
- inStackTrace = false;
- if (stackTrace != null && stackTrace.size() > 1) {
- stackTraces.add(getStackTrace(stackTrace,
- charStackStart, charPos[0] - charStackStart, comment));
- }
- stackTrace = null;
- } else {
-
- // we had one, so add it to this stack trace
- stackTrace.add(stack);
- }
-
- // update the position
- i = pos[0];
- } else {
- // update the current character position
- charPos[0] += lines[i].length() + 2;
- }
- }
-
- // make sure to add the stack trace if it was the last in the string
- if (stackTrace != null && stackTrace.size() > 1) {
- stackTraces.add(getStackTrace(stackTrace, charStackStart,
- charPos[0] - charStackStart, comment));
- }
-
- if (stackTraces.size() == 0)
- return null;
-
- // get the string values of the stack traces and return it
- return getTracesFromList(stackTraces);
- }
-
- /**
- * Get the next at clause from a potential stack trace -- looks ahead 4
- * lines
- *
- * @param lines
- * The array of all of the lines in the bug
- * @param i
- * The current position to start at
- * @param charPos
- * The current character position in the original string
- * @return The next at clause, or <code>null</code><br>
- * If an at line is matched, but the end isn't within the 4 lines,
- * only the first line is returned. Also, charPos is updated as well
- * as i
- */
- private static String getNextAt(String[] lines, int[] i, int[] charPos) {
- String regexAtString = "^at.*";
- String regexEndString = ".*:\\d+\\)$";
- int index = i[0];
- String l1, l2, l3, l4;
- l1 = l2 = l3 = l4 = null;
- String res = null;
-
- // get the first line to look at
- if (lines.length > index) {
- l1 = lines[index];
- } else {
- // if the first line doesn't exist, we are done and should
- // return
- return null;
- }
-
- // get the next 3 lines
- if (lines.length > index + 1) {
- l2 = lines[index + 1];
- }
- if (lines.length > index + 2) {
- l3 = lines[index + 2];
- }
- if (lines.length > index + 3) {
- l4 = lines[index + 3];
- }
-
- // make sure that the first line is the start of an at
- // if not, return null
- if (l1.trim().matches(regexAtString)) {
- charPos[0] += l1.length() + 2;
- res = l1;
- } else
- return null;
-
- // now determine where the end is if it wasn't on 1 line
- if (!res.trim().matches(regexEndString)) {
-
- if (l2 != null && l2.trim().matches(regexEndString)) {
-
- // it was on the second line
- // update the current position and the result string
- i[0] = index + 1;
- charPos[0] += l2.length() + 2;
- res += l2.trim();
- } else if (l3 != null && l3.trim().matches(regexEndString)) {
-
- // it was on the third line
- // update the current position and the result string
- i[0] = index + 2;
- charPos[0] += l2.length() + l3.length() + 4;
- res += l2.trim();
- res += l3.trim();
- } else if (l4 != null && l4.trim().matches(regexEndString)) {
-
- // it was on the fourth line
- // update the current position and the result string
- i[0] = index + 3;
- charPos[0] += l2.length() + l3.length() + l4.length() + 6;
- res += l2.trim();
- res += l3.trim();
- res += l4.trim();
- }
- }
-
- // return the result
- return res;
- }
-
- /**
- * Get the StackTrace
- *
- * @param l
- * the list of lines that contain the trace
- * @param start
- * the start of the stack trace
- * @param offset
- * the offset of the stack trace
- * @param comment
- * The comment that the stack trace came from
- * @return The StackTrace for the given data
- */
- private static StackTrace getStackTrace(List<String> l, int offset, int length, Object comment) {
- String s = "";
- for(String s2 : l) {
- s += s2 + "\r\n";
- }
-
- return new StackTrace(s, offset, length, comment);
- }
-
- /**
- * Convert a List StackTraces to a StackTrace[] <br>
- *
- * @param l
- * The List of StackTraces
- * @return StackTrace[] of the List
- */
- private static StackTrace[] getTracesFromList(List<StackTrace> l) {
-
- // make sure that there is something to convert, else return null
- if (l == null || l.size() == 0)
- return null;
-
- // convert the list of strings to an array of strings
- int i = 0;
- StackTrace[] s = new StackTrace[l.size()];
-
- for(StackTrace st : l) {
- s[i] = st;
- i++;
- }
-
- // return the string array
- return s;
- }
-
- /**
- * Escape all of the special regex characters from the string
- *
- * @param s
- * The string to escape the characters for
- * @return A string with all of the special characters escaped <br>
- * <code>
- * . => \.<br>
- * $ => \$<br>
- * ? => \?<br>
- * { => \{<br>
- * } => \}<br>
- * ( => \(<br>
- * ) => \)<br>
- * [ => \[<br>
- * ] => \]<br>
- * + => \+<br>
- * * => \*<br>
- * | => \|<br>
- * ^ => \^<br>
- * \ => \\<br>
- * / => \/<br>
- * </code>
- */
- public static String escapeForRegex(String s) {
- String sFixed = s;
-
- // replace all special regex characters
- sFixed = sFixed.replaceAll("\\\\", "\\\\\\\\");
- sFixed = sFixed.replaceAll("\\$", "\\\\\\$");
- sFixed = sFixed.replaceAll("\\.", "\\\\.");
- sFixed = sFixed.replaceAll("\\?", "\\\\?");
- sFixed = sFixed.replaceAll("\\{", "\\\\{");
- sFixed = sFixed.replaceAll("\\}", "\\\\}");
- sFixed = sFixed.replaceAll("\\(", "\\\\(");
- sFixed = sFixed.replaceAll("\\)", "\\\\)");
- sFixed = sFixed.replaceAll("\\[", "\\\\[");
- sFixed = sFixed.replaceAll("\\]", "\\\\]");
- sFixed = sFixed.replaceAll("\\+", "\\\\+");
- sFixed = sFixed.replaceAll("\\*", "\\\\*");
- sFixed = sFixed.replaceAll("\\|", "\\\\|");
- sFixed = sFixed.replaceAll("\\^", "\\\\^");
- sFixed = sFixed.replaceAll("\\/", "\\\\/");
-
- return sFixed;
- }
-} \ No newline at end of file
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/Util.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/Util.java
deleted file mode 100644
index fb26f0500..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/Util.java
+++ /dev/null
@@ -1,226 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on Nov 19, 2004
- */
-package org.eclipse.mylar.tasks.bugzilla;
-
-import java.io.UnsupportedEncodingException;
-import java.net.URLEncoder;
-import java.nio.charset.Charset;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-
-import org.eclipse.jdt.core.IJavaElement;
-import org.eclipse.jdt.core.IMember;
-import org.eclipse.jdt.core.IType;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.mylar.bugzilla.BugzillaPlugin;
-import org.eclipse.mylar.bugzilla.BugzillaPreferences;
-import org.eclipse.mylar.bugzilla.IBugzillaConstants;
-import org.eclipse.mylar.core.model.InterestComparator;
-import org.eclipse.mylar.tasks.bugzilla.search.BugzillaMylarSearchOperation;
-
-
-/**
- * Utilities methods for the BugzillaMylarBridge
- *
- * @author Shawn Minto
- */
-public class Util {
-
- /**
- * List of all of the search operations that can be done <br> all words, any words, regex
- */
- private static final String[] patternOperationValues = { "allwordssubstr", "anywordssubstr", "regexp" };
- /**
- * Sugzilla preferences so that we can get the search params
- */
- private static IPreferenceStore prefs = BugzillaPlugin.getDefault().getPreferenceStore();
- /**
- * List of all of the resolutions that we can have <br> FIXED, INVALID, WONTFIX, LATER, REMIND, DUPLICATE, WORKSFORME, MOVED, ---
- */
- private static String[] resolutionValues = BugzillaPreferences.queryOptionsToArray(prefs.getString(IBugzillaConstants.RESOLUTION_VALUES));
- /**
- * List of all of the statuses that we can have <br> UNCONFIRMED, NEW, ASSIGNED, REOPENED, RESOLVED, VERIFIED, CLOSED
- */
- private static String[] statusValues = BugzillaPreferences.queryOptionsToArray(prefs.getString(IBugzillaConstants.STATUS_VALUES));
-
- /**
- * Get only the landmarks that are IMember and sort them according to their
- * DOI value (highest to lowest)
- *
- * @param landmarks
- * The landmarks to check
- * @return List of IMember landmarks sorted by DOI value
- */
- public static List<IMember> getMemberLandmarks(List<IJavaElement> landmarks) {
- List<IMember> memberLandmarks = new ArrayList<IMember>();
-
- for(IJavaElement je : landmarks) {
-
- // keep only the IMember landmarks
- if (je instanceof IMember) {
- memberLandmarks.add((IMember)je);
- }
- }
-
- // sort the landmarks
- Collections.sort(memberLandmarks, new InterestComparator<IMember>());
-
- return memberLandmarks;
- }
-
- /**
- * Get the bugzilla url used for searching for exact matches
- *
- * @param je
- * The IMember to create the query string for
- * @return A url string for the search
- */
- public static String getExactSearchURL(IMember je) {
- StringBuffer sb = getQueryURLStart();
-
- String long_desc = "";
-
- // get the fully qualified name of the element
- long_desc += BugzillaMylarSearchOperation.getFullyQualifiedName(je);
-
- try{
- // encode the string to be used as a url
- sb.append(URLEncoder.encode(long_desc, Charset.defaultCharset().toString()));
- } catch (UnsupportedEncodingException e)
- {
- // should never get here since we are using the default encoding
- }
- sb.append(getQueryURLEnd());
-
- return sb.toString();
- }
-
- /**
- * Get the bugzilla url used for searching for inexact matches
- *
- * @param je
- * The IMember to create the query string for
- * @return A url string for the search
- */
- public static String getInexactSearchURL(IMember je) {
- StringBuffer sb = getQueryURLStart();
-
-
- String long_desc = "";
-
- // add the member, qualified with just its parents name
- if (!(je instanceof IType))
- long_desc += je.getParent().getElementName()+".";
- long_desc += je.getElementName();
-
- try{
- // encode the string to be used as a url
- sb.append(URLEncoder.encode(long_desc, Charset.defaultCharset().toString()));
- } catch (UnsupportedEncodingException e)
- {
- // should never get here since we are using the default encoding
- }
- sb.append(getQueryURLEnd());
-
- return sb.toString();
- }
-
- /**
- * Create the end of the bugzilla query URL with all of the status' and resolutions that we want
- * @return StringBuffer with the end of the query URL in it
- */
- public static StringBuffer getQueryURLEnd(){
-
- StringBuffer sb = new StringBuffer();
-
- // add the status and resolutions that we care about
- sb.append("&bug_status=" + statusValues[0]); // UNCONFIRMED
- sb.append("&bug_status=" + statusValues[1]); // NEW
- sb.append("&bug_status=" + statusValues[2]); // ASSIGNED
- sb.append("&bug_status=" + statusValues[3]); // REOPENED
- sb.append("&bug_status=" + statusValues[4]); // RESOLVED
- sb.append("&bug_status=" + statusValues[5]); // VERIFIED
- sb.append("&bug_status=" + statusValues[6]); // CLOSED
-
- sb.append("&resolution=" + resolutionValues[0]); // FIXED
- sb.append("&resolution=" + resolutionValues[3]); // LATER
- sb.append("&resolution=" + "---"); // ---
- return sb;
- }
-
- /**
- * Create the bugzilla query URL start.
- *
- * @return The start of the query url as a StringBuffer <br>
- * Example: https://bugs.eclipse.org/bugs/buglist.cgi?long_desc_type=allwordssubstr&long_desc=
- */
- public static StringBuffer getQueryURLStart() {
- StringBuffer sb = new StringBuffer(BugzillaPlugin.getDefault()
- .getServerName());
-
- if (sb.charAt(sb.length() - 1) != '/') {
- sb.append('/');
- }
- sb.append("buglist.cgi?");
-
- // use the username and password if we have it
- if (BugzillaPreferences.getUserName() != null
- && !BugzillaPreferences.getUserName().equals("")
- && BugzillaPreferences.getPassword() != null
- && !BugzillaPreferences.getPassword().equals("")) {
- try{
- sb.append("GoAheadAndLogIn=1&Bugzilla_login="
- + URLEncoder.encode(BugzillaPreferences.getUserName(), Charset.defaultCharset().toString())
- + "&Bugzilla_password="
- + URLEncoder.encode(BugzillaPreferences.getPassword(), Charset.defaultCharset().toString())
- + "&");
- } catch (UnsupportedEncodingException e)
- {
- // should never get here since we are using the default encoding
- }
- }
-
- // add the description search type
- sb.append("long_desc_type=");
- sb.append(patternOperationValues[0]); // search for all words
- sb.append("&long_desc=");
-
- return sb;
- }
-
- /**
- * Search the given string for another string
- * @param elementName The name of the element that we are looking for
- * @param comment The text to search for this element name
- * @return <code>true</code> if the element is found in the text else <code>false</code>
- */
- public static boolean hasElementName(String elementName, String comment) {
-
- // setup a regex for the element name
- String regexElement = ".*"+elementName+".*";
-
- // get all of the individual lines for the string
- String[] lines = comment.split("\n");
-
- // go through each of the lines of the string
- for (int i = 0; i < lines.length; i++) {
-
- if (lines[i].matches(regexElement)){
- return true;
- }
- }
- return false;
- }
-} \ No newline at end of file
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/search/BugzillaCategorySearchOperation.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/search/BugzillaCategorySearchOperation.java
deleted file mode 100644
index 5fd74e240..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/search/BugzillaCategorySearchOperation.java
+++ /dev/null
@@ -1,138 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on Oct 14, 2004
- */
-package org.eclipse.mylar.tasks.bugzilla.search;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import javax.security.auth.login.LoginException;
-
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.mylar.bugzilla.search.BugzillaSearchEngine;
-import org.eclipse.mylar.bugzilla.search.BugzillaSearchQuery;
-import org.eclipse.mylar.bugzilla.search.IBugzillaSearchOperation;
-import org.eclipse.mylar.core.MylarPlugin;
-import org.eclipse.ui.actions.WorkspaceModifyOperation;
-
-
-/**
- * Bugzilla search operation for Mylar
- *
- * @author Shawn Minto
- */
-public class BugzillaCategorySearchOperation extends WorkspaceModifyOperation
- implements IBugzillaSearchOperation {
- /** The IMember we are doing the search for */
-
- public interface ICategorySearchListener {
- public void searchCompleted(BugzillaResultCollector collector);
- }
-
- /** The bugzilla collector for the search */
- private BugzillaResultCollector collector = null;
-
- /** The status of the search operation */
- private IStatus status;
-
- /** The LoginException that was thrown when trying to do the search */
- private LoginException loginException = null;
-
- private String url;
-
- /**
- * Constructor
- *
- * @param m
- * The member that we are doing the search for
- */
- public BugzillaCategorySearchOperation(String url) {
- this.url = url;
- }
-
- @Override
- public void execute(IProgressMonitor monitor) {
- collector = new BugzillaResultCollector();
- collector.setOperation(this);
- collector.setProgressMonitor(monitor);
- search(url, monitor);
- for(ICategorySearchListener listener: listeners)
- listener.searchCompleted(collector);
- }
-
- /**
- * Perform the actual search on the Bugzilla server
- * @param url The url to use for the search
- * @param searchCollector The collector to put the search results into
- * @param monitor The progress monitor to use for the search
- * @return The BugzillaResultCollector with the search results
- */
- private BugzillaResultCollector search(String url, IProgressMonitor monitor){
-
- // set the initial number of matches to 0
- int matches = 0;
- // setup the progress monitor and start the search
- collector.setProgressMonitor(monitor);
- BugzillaSearchEngine engine = new BugzillaSearchEngine(url);
- try {
-
- // perform the search
- status = engine.search(collector, matches);
-
- // check the status so that we don't keep searching if there
- // is a problem
- if (status.getCode() == IStatus.CANCEL) {
- MylarPlugin.log("search cancelled", this);
- return null;
- } else if (!status.isOK()) {
- MylarPlugin.log("search error", this);
- MylarPlugin.log(status);
- return null;
- }
- return collector;
- } catch (LoginException e) {
- //save this exception to throw later
- this.loginException = e;
- }
- return null;
- }
-
- /**
- * @see org.eclipse.mylar.bugzilla.search.IBugzillaSearchOperation#getStatus()
- */
- public IStatus getStatus() throws LoginException {
- // if a LoginException was thrown while trying to search, throw this
- if (loginException == null)
- return status;
- else
- throw loginException;
- }
-
- public ImageDescriptor getImageDescriptor() {
- return null;
- }
-
- public BugzillaSearchQuery getQuery() {
- return null;
- }
-
- public void setQuery(BugzillaSearchQuery newQuery) {}
-
- private List<ICategorySearchListener> listeners = new ArrayList<ICategorySearchListener>();
-
- public void addResultsListener(ICategorySearchListener listener){
- listeners.add(listener);
- }
-}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/search/BugzillaMylarSearch.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/search/BugzillaMylarSearch.java
deleted file mode 100644
index dea6339ee..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/search/BugzillaMylarSearch.java
+++ /dev/null
@@ -1,148 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on Oct 13, 2004
- */
-package org.eclipse.mylar.tasks.bugzilla.search;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.jdt.core.IJavaElement;
-import org.eclipse.jdt.core.IMember;
-import org.eclipse.mylar.core.search.IActiveSearchListener;
-import org.eclipse.mylar.core.search.IMylarSearchOperation;
-import org.eclipse.mylar.tasks.bugzilla.BugzillaMylarBridge;
-import org.eclipse.mylar.tasks.bugzilla.BugzillaReportNode;
-import org.eclipse.mylar.tasks.bugzilla.Util;
-
-
-/**
- * Used to facilitate bugzilla searches based on IJavaElements
- *
- * @author Shawn Minto
- */
-public class BugzillaMylarSearch implements IMylarSearchOperation {
-
- // scope identifiers
- public static final int LOCAL_QUAL = 1; // local implies a bugzilla task, not just an offline report
- public static final int LOCAL_UNQUAL = 2;
- public static final int FULLY_QUAL = 3;
- public static final int UNQUAL = 4;
-
- private int scope;
-
- private IJavaElement element;
-
- private String handle = "";
-
- /**
- * Constructor
- * @param scope The scope of this search
- */
- public BugzillaMylarSearch(int scope, IJavaElement element) {
- this.scope = scope;
- this.element = element;
- }
-
- public IStatus run(IProgressMonitor monitor) {
- handle = element.getHandleIdentifier() + " " + scope;
- List<IJavaElement> landmarks = new ArrayList<IJavaElement>();
- landmarks.add(element);
-
- if (!BugzillaMylarBridge.doesJobExist(handle)) {
-
- // perform the bugzilla search
- // get only the useful landmarks (IMember)
- List<IMember> members = Util.getMemberLandmarks(landmarks);
-
- // go through all of the landmarks that we are given and perform a
- // search on them
- for(IMember m : members){
-
- // FIXME: decide whether to do leave the caching of searches in for now or not
- // check if we have the info cached
-// List<BugzillaReportNode> landmarkDoi = MylarTasksPlugin.getBridge()
-// .getFromLandmarksHash(m, scope);
-
-// if (landmarkDoi != null) {
-// //TODO decide when to queue up and do a refresh search
-// notifySearchCompleted(landmarkDoi);
-// continue;
-// }
-
- // create a search operation so that we can search
- BugzillaMylarSearchOperation op = new BugzillaMylarSearchOperation(
- this, m, scope);
-
- // create a new search job so that it can be scheduled and
- // run as a background thread
- Job searchJob = new BugzillaMylarSearchJob(
- "Querying Bugzilla Server - Mylar - "
- + op.getSearchMemberName(), op);
-
- // schedule the new search job
- searchJob.schedule();
-
- // save this searchJobs handle so that we can cancel it if need be
- BugzillaMylarBridge.addJob(handle, searchJob);
- }
- }
- return Status.OK_STATUS;
- }
-
- /** List of listeners wanting to know about the searches */
- private List<IActiveSearchListener> listeners = new ArrayList<IActiveSearchListener>();
-
- /**
- * Add a listener for when the bugzilla search is completed
- *
- * @param l
- * The listener to add
- */
- public void addListener(IActiveSearchListener l) {
- // add the listener to the list
- listeners.add(l);
- }
-
- /**
- * Remove a listener for when the bugzilla search is completed
- *
- * @param l
- * The listener to remove
- */
- public void removeListener(IActiveSearchListener l) {
- // remove the listener from the list
- listeners.remove(l);
- }
-
- /**
- * Notify all of the listeners that the bugzilla search is completed
- *
- * @param doiList
- * A list of BugzillaSearchHitDoiInfo
- * @param member
- * The IMember that the search was performed on
- */
- public void notifySearchCompleted(List<BugzillaReportNode> doiList) {
- // go through all of the listeners and call searchCompleted(colelctor,
- // member)
- BugzillaMylarBridge.removeSearchJob(handle);
- for (IActiveSearchListener listener : listeners) {
- listener.searchCompleted(doiList);
- }
- }
-
-} \ No newline at end of file
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/search/BugzillaMylarSearchJob.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/search/BugzillaMylarSearchJob.java
deleted file mode 100644
index 209d17434..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/search/BugzillaMylarSearchJob.java
+++ /dev/null
@@ -1,109 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on Oct 6, 2004
- */
-package org.eclipse.mylar.tasks.bugzilla.search;
-
-import javax.security.auth.login.LoginException;
-
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.jface.dialogs.ErrorDialog;
-import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.mylar.bugzilla.BugzillaPlugin;
-import org.eclipse.mylar.bugzilla.IBugzillaConstants;
-import org.eclipse.mylar.tasks.bugzilla.BugzillaMylarBridge;
-import org.eclipse.ui.PlatformUI;
-
-
-/**
- * The bugzilla search job used to search a bugzilla site
- *
- * @author Shawn Minto
- */
-public class BugzillaMylarSearchJob extends Job {
-
- /** The search operation used to perform the query */
- private BugzillaMylarSearchOperation operation;
-
- /**
- * Constructor
- *
- * @param name
- * Job name
- * @param operation
- * The operation to perform the search query
- */
- public BugzillaMylarSearchJob(String name,
- BugzillaMylarSearchOperation operation) {
- super(name);
- this.operation = operation;
- }
-
- @Override
- protected IStatus run(IProgressMonitor monitor) {
- // create a new status
- final IStatus[] status = new IStatus[1];
-
- try {
- // execute the search operation
- operation.execute(monitor);
-
- // get the status of the search operation
- status[0] = operation.getStatus();
-
- // determine if there was an error, if it was cancelled, or if it is
- // ok
- if ( status[0].getCode() == IStatus.CANCEL) {
- // it was cancelled, so just return
- status[0] = Status.OK_STATUS;
-
- // make sure that we know this job is not running anymore
- BugzillaMylarBridge.removeSearchJob(operation.getSearchMember().getHandleIdentifier()+" "+operation.getScope());//runningJobs.remove(operation.getSearchMember());
- return status[0];
- } else if (!status[0].isOK()) {
- // there was an error, so display an error message
- PlatformUI.getWorkbench().getDisplay().asyncExec(
- new Runnable() {
- public void run() {
- ErrorDialog.openError(null,
- "Bugzilla Search Error", null,
- status[0]);
- }
- });
- status[0] = Status.OK_STATUS;
-
- // make sure we know that this job is not running anymore
- BugzillaMylarBridge.removeSearchJob(operation.getSearchMember().getHandleIdentifier()+" "+operation.getScope());//runningJobs.remove(operation.getSearchMember());
- return status[0];
- }
- } catch (LoginException e) {
- // we had a problem while searching that seems like a login info
- // problem
- // thrown in BugzillaSearchOperation
- MessageDialog
- .openError(
- null,
- "Login Error",
- "Bugzilla could not log you in to get the information you requested since login name or password is incorrect.\nPlease check your settings in the bugzilla preferences. ");
- BugzillaPlugin.log(new Status(IStatus.ERROR,
- IBugzillaConstants.PLUGIN_ID, IStatus.OK, "", e));
- } finally {
- // make sure that we know that this job is not running anymore
- BugzillaMylarBridge.removeSearchJob(operation.getSearchMember().getHandleIdentifier()+" "+operation.getScope());//.runningJobs.remove(operation.getSearchMember());
- }
-
- return status[0];
- }
-} \ No newline at end of file
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/search/BugzillaMylarSearchOperation.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/search/BugzillaMylarSearchOperation.java
deleted file mode 100644
index f1396a849..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/search/BugzillaMylarSearchOperation.java
+++ /dev/null
@@ -1,526 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on Oct 14, 2004
- */
-package org.eclipse.mylar.tasks.bugzilla.search;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import javax.security.auth.login.LoginException;
-
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.jdt.core.IJavaElement;
-import org.eclipse.jdt.core.IMember;
-import org.eclipse.jdt.core.IType;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.mylar.bugzilla.core.BugReport;
-import org.eclipse.mylar.bugzilla.core.Comment;
-import org.eclipse.mylar.bugzilla.search.BugzillaSearchEngine;
-import org.eclipse.mylar.bugzilla.search.BugzillaSearchHit;
-import org.eclipse.mylar.bugzilla.search.BugzillaSearchQuery;
-import org.eclipse.mylar.bugzilla.search.IBugzillaSearchOperation;
-import org.eclipse.mylar.core.MylarPlugin;
-import org.eclipse.mylar.tasks.BugzillaTask;
-import org.eclipse.mylar.tasks.ITask;
-import org.eclipse.mylar.tasks.TaskCategory;
-import org.eclipse.mylar.tasks.MylarTasksPlugin;
-import org.eclipse.mylar.tasks.bugzilla.BugzillaReportNode;
-import org.eclipse.mylar.tasks.bugzilla.StackTrace;
-import org.eclipse.mylar.tasks.bugzilla.Util;
-import org.eclipse.ui.actions.WorkspaceModifyOperation;
-
-
-/**
- * Bugzilla search operation for Mylar
- *
- * @author Shawn Minto
- */
-public class BugzillaMylarSearchOperation extends WorkspaceModifyOperation
- implements IBugzillaSearchOperation {
- /** The IMember we are doing the search for */
- private IMember javaElement;
-
- /** The bugzilla collector for the search */
- private BugzillaResultCollector collector = null;
-
- /** The status of the search operation */
- private IStatus status;
-
- /** The LoginException that was thrown when trying to do the search */
- private LoginException loginException = null;
-
- /** The fully qualified name of the member we are searching for */
- private String name;
-
- /** The bugzilla search query */
- private BugzillaSearchQuery query;
-
- private BugzillaMylarSearch search;
-
- private int scope;
-
- /**
- * Constructor
- *
- * @param m
- * The member that we are doing the search for
- */
- public BugzillaMylarSearchOperation(BugzillaMylarSearch search, IMember m, int scope) {
- this.javaElement = m;
- this.search = search;
- this.scope = scope;
- name = getFullyQualifiedName(m);
- }
-
- /**
- * Get the fully qualified name of a IMember
- * TODO: move to a more central location so that others can use this, but don't want to add unecessary coupling
- *
- * @return String representing the fully qualified name
- */
- public static String getFullyQualifiedName(IJavaElement je) {
- if(!(je instanceof IMember)) return null;
-
- IMember m = (IMember)je;
- if (m.getDeclaringType() == null)
- return ((IType) m).getFullyQualifiedName();
- else
- return m.getDeclaringType().getFullyQualifiedName() + "."
- + m.getElementName();
- }
-
- @Override
- public void execute(IProgressMonitor monitor) {
-
- BugzillaResultCollector searchCollector = null;
-
- if(scope == BugzillaMylarSearch.FULLY_QUAL){
- searchCollector = searchQualified(monitor);
- }else if(scope == BugzillaMylarSearch.UNQUAL){
- searchCollector = searchUnqualified(monitor);
- }else if(scope == BugzillaMylarSearch.LOCAL_QUAL){
- searchCollector = searchLocalQual(monitor);
- }else if(scope == BugzillaMylarSearch.LOCAL_UNQUAL){
- searchCollector = searchLocalUnQual(monitor);
- }else{
- return;
- }
-
- if(searchCollector == null){
- search.notifySearchCompleted(
- new ArrayList<BugzillaReportNode>());
- return;
- }
-
- List<BugzillaSearchHit> l = searchCollector.getResults();
-
- // get the list of doi elements
- List<BugzillaReportNode> doiList = getDoiList(l);
-
- // we completed the search, so notify all of the listeners
- // that the search has been completed
- MylarTasksPlugin.getBridge()
- .addToLandmarksHash(doiList, javaElement, scope);
- search.notifySearchCompleted(
- doiList);
- // MIK: commmented out logging
-// MonitorPlugin.log(this, "There were " + doiList.size() + " items found");
- }
-
- /**
- * Search the local bugs for the member using the qualified name
- * @param monitor The progress monitor to search with
- * @return The BugzillaResultCollector with the results of the search
- */
- private BugzillaResultCollector searchLocalQual(IProgressMonitor monitor) {
-
- //get the fully qualified name for searching
- String elementName = getFullyQualifiedName(javaElement);
-
- // setup the search result collector
- collector = new BugzillaResultCollector();
- collector.setOperation(this);
- collector.setProgressMonitor(monitor);
-
- // get all of the root tasks and start the search
- List<ITask> tasks = MylarTasksPlugin.getTaskListManager().getTaskList().getRootTasks();
- searchLocal(tasks, collector, elementName, monitor);
- for (TaskCategory cat : MylarTasksPlugin.getTaskListManager().getTaskList().getTaskCategories()) {
- searchLocal(cat.getChildren(), collector, elementName, monitor);
- }
-
- // return the collector
- return collector;
- }
-
- /**
- * Search the local bugs for the member using the unqualified name
- * @param monitor The progress monitor to search with
- * @return The BugzillaResultCollector with the results of the search
- */
- private BugzillaResultCollector searchLocalUnQual(IProgressMonitor monitor) {
-
- // get the element name for searching
- String elementName = javaElement.getElementName();
-
- // setup the search result collector
- collector = new BugzillaResultCollector();
- collector.setOperation(this);
- collector.setProgressMonitor(monitor);
-
- // get all of the root tasks and start the search
- List<ITask> tasks = MylarTasksPlugin.getTaskListManager().getTaskList().getRootTasks();
- searchLocal(tasks, collector, elementName, monitor);
- for (TaskCategory cat : MylarTasksPlugin.getTaskListManager().getTaskList().getTaskCategories()) {
- searchLocal(cat.getChildren(), collector, elementName, monitor);
- }
- // return the collector
- return collector;
- }
-
- /**
- * Search the local bugs for the member
- * @param tasks The tasks to search
- * @param searchCollector The collector to add the results to
- * @param elementName The name of the element that we are looking for
- * @param monitor The progress monitor
- */
- private void searchLocal(List<ITask> tasks, BugzillaResultCollector searchCollector, String elementName, IProgressMonitor monitor) {
- if(tasks == null) return;
-
- // go through all of the tasks
- for(ITask task : tasks){
- monitor.worked(1);
-
- // check what kind of task it is
- if(task instanceof BugzillaTask){
-
- // we have a bugzilla task, so get the bug report
- BugzillaTask bugTask = (BugzillaTask)task;
- BugReport bug = bugTask.getBugReport();
-
- // parse the bug report for the element that we are searching for
- boolean isHit = search(elementName, bug);
-
- // determine if we have a hit or not
- if(isHit){
-
- // make a search hit from the bug and then add it to the collector
- BugzillaSearchHit hit = new BugzillaSearchHit(bug.getId(), bug.getDescription(), "","","","","","","", bug.getServer());
- try{
- searchCollector.accept(hit);
- }catch(CoreException e){
- MylarPlugin.log(e, "bug search failed");
- }
- }
- }
- }
- status = Status.OK_STATUS;
- }
-
- /**
- * Search the bug for the given element name
- * @param elementName The name of the element to search for
- * @param bug The bug to search in
- */
- private boolean search(String elementName, BugReport bug) {
-
- if (bug == null) return false; // MIK: added null check here
- String description = bug.getDescription();
- String summary = bug.getSummary();
- List<Comment> comments = bug.getComments();
-
- // search the description and the summary
- if(Util.hasElementName(elementName, summary))
- return true;
-
- if(Util.hasElementName(elementName, description))
- return true;
-
- Iterator<Comment> comItr = comments.iterator();
- while (comItr.hasNext()) {
- Comment comment = comItr.next();
- String commentText = comment.getText();
- // search the text for a reference to the element
- if(Util.hasElementName(elementName, commentText))
- return true;
- }
- return false;
- }
-
- /**
- * Perform the actual search on the Bugzilla server
- * @param url The url to use for the search
- * @param searchCollector The collector to put the search results into
- * @param monitor The progress monitor to use for the search
- * @return The BugzillaResultCollector with the search results
- */
- private BugzillaResultCollector search(String url, BugzillaResultCollector searchCollector, IProgressMonitor monitor){
-
- // set the initial number of matches to 0
- int matches = 0;
- // setup the progress monitor and start the search
- searchCollector.setProgressMonitor(monitor);
- BugzillaSearchEngine engine = new BugzillaSearchEngine(url);
- try {
-
- // perform the search
- status = engine.search(searchCollector, matches);
-
- // check the status so that we don't keep searching if there
- // is a problem
- if (status.getCode() == IStatus.CANCEL) {
- MylarPlugin.log("search cancelled", this);
- return null;
- } else if (!status.isOK()) {
- MylarPlugin.log("search error", this);
- MylarPlugin.log(status);
- return null;
- }
- return searchCollector;
- } catch (LoginException e) {
- //save this exception to throw later
- this.loginException = e;
- }
- return null;
- }
-
- /**
- * Perform a search for qualified instances of the member
- * @param monitor The progress monitor to use
- * @return The BugzillaResultCollector with the search results
- */
- private BugzillaResultCollector searchQualified(IProgressMonitor monitor)
- {
- // create a new collector for the results
- collector = new BugzillaResultCollector();
- collector.setOperation(this);
- collector.setProgressMonitor(monitor);
-
- // get the search url
- String url = Util.getExactSearchURL(javaElement);
-
- // log the url that we are searching with
- // MIK: commmented out logging
-// MonitorPlugin.log(this, url);
-
- return search(url, collector, monitor);
- }
-
- /**
- * Perform a search for unqualified instances of the member
- * @param monitor The progress monitor to use
- * @return The BugzillaResultCollector with the search results
- */
- private BugzillaResultCollector searchUnqualified(IProgressMonitor monitor)
- {
- // create a new collector for the results
- collector = new BugzillaResultCollector();
- collector.setOperation(this);
- collector.setProgressMonitor(monitor);
-
- // get the search url
- String url = Util.getInexactSearchURL(javaElement);
-
- // log the url that we are searching with
- // MIK: commmented out logging
-// MonitorPlugin.log(this, url);
-
- return search(url, collector, monitor);
- }
-
-// /**
-// * Remove all of the duplicates
-// * @param compare The List of BugzillaSearchHits to compare with
-// * @param base The List of BugzillaSearchHits to remove the duplicates from
-// */
-// private void removeDuplicates(List<BugzillaSearchHit> compare, List<BugzillaSearchHit> base){
-//
-// for(BugzillaSearchHit h1 : compare){
-// Iterator itr2 = base.iterator();
-// while(itr2.hasNext()){
-// BugzillaSearchHit h2 = (BugzillaSearchHit)itr2.next();
-// if(h2.getId() == h1.getId()){
-// // we found a duplicate so remove it
-// itr2.remove();
-// break;
-// }
-// }
-// }
-// }
-//
- /**
- * Perform a second pass parse to determine if there are any stack traces in
- * the bug - currently only used for the exact search results
- *
- * @param doiList -
- * the list of BugzillaSearchHitDOI elements to parse
- */
- public static void secondPassBugzillaParser(List<BugzillaReportNode> doiList) {
-
- // go through each of the items in the doiList
- for(BugzillaReportNode info : doiList) {
-
- // get the bug report so that we have all of the data
- // - descriptions, comments, etc
- BugReport b = null;
- try{
- b = info.getBug();
- }catch(Exception e){
- // don't care since null will be caught
- }
-
- // if the report could not be downloaded, try the next one
- if (b == null)
- continue;
-
- // see if the description has a stack trace in it
- StackTrace[] stackTrace = StackTrace.getStackTrace(b.getDescription(), b.getDescription());
- if (stackTrace != null) {
-
- // add the stack trace to the doi info
- info.setExact(true);
- info.addStackTraces(stackTrace);
- }
-
- // go through all of the comments for the bug
- Iterator<Comment> comItr = b.getComments().iterator();
- while (comItr.hasNext()) {
- Comment comment = comItr.next();
- String commentText = comment.getText();
-
- // see if the comment has a stack trace in it
- stackTrace = StackTrace.getStackTrace(commentText, comment);
- if (stackTrace != null) {
-
- // add the stack trace to the doi info
- info.setExact(true);
- info.addStackTraces(stackTrace);
- }
- }
- }
- }
-
- /**
- * Add the results returned to the Hash of landmarks
- *
- * @param results
- * The list of results
- * @param isExact
- * whether the search was exact or not
- */
- private List<BugzillaReportNode> getDoiList(List<BugzillaSearchHit> results) {
- List<BugzillaReportNode> doiList = new ArrayList<BugzillaReportNode>();
-
- boolean isExact = (scope==BugzillaMylarSearch.FULLY_QUAL || scope==BugzillaMylarSearch.LOCAL_QUAL)?true:false;
-
- BugzillaReportNode info = null;
- // go through all of the results and create a DoiInfo list
- for(BugzillaSearchHit hit : results){
-
- try {
- float value = 0;
- info = new BugzillaReportNode(
- value, hit, isExact);
-
- // only download the bug for the exact matches
- //downloading bugs kills the time - can we do this elsewhere? - different thread? persistant?
-// if(isExact){
-// // get the bug report for the doi info item
-// BugReport b = BugzillaRepository.getInstance().getBug(
-// hit.getId());
-// // add the bug to the doi info for future use
-// info.setBug(b);
-// }
-
- } catch (Exception e) {
- MylarPlugin.log(e, "search failed");
- }
- finally{
- doiList.add(info);
- }
- }
- return doiList;
- }
-
- /**
- * @see org.eclipse.mylar.bugzilla.search.IBugzillaSearchOperation#getStatus()
- */
- public IStatus getStatus() throws LoginException {
- // if a LoginException was thrown while trying to search, throw this
- if (loginException == null)
- return status;
- else
- throw loginException;
- }
-
- /**
- * @see org.eclipse.mylar.bugzilla.search.IBugzillaSearchOperation#getImageDescriptor()
- */
- public ImageDescriptor getImageDescriptor() {
- return null;
- }
-
- /**
- * Get the member that we are performing the search for
- *
- * @return The member this search is being performed for
- */
- public IMember getSearchMember() {
- return javaElement;
- }
-
- /**
- * Get the name of the member that we are searching for
- *
- * @return The fully qualified name of the member
- */
- public String getSearchMemberName() {
- return name;
- }
-
- /**
- * @see org.eclipse.mylar.bugzilla.search.IBugzillaSearchOperation#getQuery()
- */
- public BugzillaSearchQuery getQuery() {
- return query;
- }
-
- /**
- * @see org.eclipse.mylar.bugzilla.search.IBugzillaSearchOperation#setQuery(org.eclipse.mylar.bugzilla.search.BugzillaSearchQuery)
- */
- public void setQuery(BugzillaSearchQuery newQuery) {
- this.query = newQuery;
- }
-
- /**
- * Get the name of the element that we are searching for
- *
- * @return The name of the element
- */
- public String getName(){
- return name;
- }
-
- /**
- * Get the scope of the search operation
- * @return The scope - defined in BugzillaMylarSearch
- */
- public int getScope() {
- return scope;
- }
-} \ No newline at end of file
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/search/BugzillaResultCollector.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/search/BugzillaResultCollector.java
deleted file mode 100644
index 3bbc47c2b..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/search/BugzillaResultCollector.java
+++ /dev/null
@@ -1,182 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on Oct 4, 2004
- */
-package org.eclipse.mylar.tasks.bugzilla.search;
-
-import java.text.MessageFormat;
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.mylar.bugzilla.search.BugzillaSearchHit;
-import org.eclipse.mylar.bugzilla.search.IBugzillaSearchOperation;
-import org.eclipse.mylar.bugzilla.search.IBugzillaSearchResultCollector;
-
-
-/**
- * Collector for the bugzilla search results
- *
- * @author Shawn Minto
- */
-public class BugzillaResultCollector implements IBugzillaSearchResultCollector {
- /** A list of all of the search results found */
- private List<BugzillaSearchHit> results = new ArrayList<BugzillaSearchHit>();
-
- /** The progress monitor for the search operation */
- private IProgressMonitor monitor;
-
- /** The number of matches found */
- private int matchCount;
-
- /** The bugzilla search operation */
- private IBugzillaSearchOperation operation;
-
- /** The string to display to the user while querying */
- private static final String STARTING = "querying the server";
-
- /** The string to display to the user when the query is done */
- private static final String DONE = "done";
-
- /** The string to display when there is one match from the search */
- private static final String MATCH = "Bugzilla Mylar search - 1 match";
-
- /** The string to display when there is more than one match from the search */
- private static final String MATCHES = "Bugzilla Mylar search - {0} matches";
-
- /**
- * @see org.eclipse.mylar.bugzilla.search.IBugzillaSearchResultCollector#aboutToStart()
- */
- public void aboutToStart(int startMatchCount) throws CoreException {
- // initiailize the number of matches
- matchCount = startMatchCount;
-
- // set the progress monitor to say that we are querying the server
- monitor.setTaskName(STARTING);
- }
-
- /**
- * @see org.eclipse.mylar.bugzilla.search.IBugzillaSearchResultCollector#accept(org.eclipse.mylar.bugzilla.search.BugzillaSearchHit)
- */
- public void accept(BugzillaSearchHit hit) throws CoreException {
- // add the result to the list of results
- results.add(hit);
-
- // increment the match count
- matchCount++;
-
- if (getProgressMonitor() != null) {
- if (!getProgressMonitor().isCanceled()) {
- // if the operation is cancelled finish with whatever data was
- // already found
- getProgressMonitor().subTask(
- getFormattedMatchesString(matchCount));
- getProgressMonitor().worked(1);
- }
- }
- }
-
- /**
- * @see org.eclipse.mylar.bugzilla.search.IBugzillaSearchResultCollector#done()
- */
- public void done() {
- if (getProgressMonitor() != null) {
- if (!monitor.isCanceled()) {
- // if the operation is cancelled, finish with the data that we
- // already have
- String matchesString = getFormattedMatchesString(matchCount);
- monitor.setTaskName(MessageFormat.format(DONE,
- new Object[] { matchesString }));
- }
- }
-
- monitor = null;
- }
-
- /**
- * @see org.eclipse.mylar.bugzilla.search.IBugzillaSearchResultCollector#getProgressMonitor()
- */
- public IProgressMonitor getProgressMonitor() {
- return monitor;
- }
-
- /**
- * @see org.eclipse.mylar.bugzilla.search.IBugzillaSearchResultCollector#setProgressMonitor(org.eclipse.core.runtime.IProgressMonitor)
- */
- public void setProgressMonitor(IProgressMonitor monitor) {
- this.monitor = monitor;
- }
-
- /**
- * @see org.eclipse.mylar.bugzilla.search.IBugzillaSearchResultCollector#setOperation(org.eclipse.mylar.bugzilla.search.BugzillaSearchOperation)
- */
- public void setOperation(IBugzillaSearchOperation operation) {
- this.operation = operation;
- }
-
- /**
- * @see org.eclipse.mylar.bugzilla.search.IBugzillaSearchResultCollector#getOperation()
- */
- public IBugzillaSearchOperation getOperation() {
- return operation;
- }
-
- /**
- * Get the string specifying the number of matches found
- *
- * @param count
- * The number of matches found
- * @return The <code>String</code> specifying the number of matches found
- */
- private String getFormattedMatchesString(int count) {
- // if only 1 match, return the singular match string
- String name = "";
- if(operation instanceof BugzillaMylarSearchOperation)
- name = " - " + ((BugzillaMylarSearchOperation)operation).getName();
- if (count == 1)
- return MATCH + name;
-
- // format the matches string and return it
- Object[] messageFormatArgs = { new Integer(count) };
- return MessageFormat.format(MATCHES + name,
- messageFormatArgs);
- }
-
- /**
- * Get the list of results
- *
- * @return A List of BugzillaSearchHit
- */
- public List<BugzillaSearchHit> getResults() {
- return results;
- }
-
- /**
- * Get the number of matches from the operation
- *
- * @return Returns the matchCount.
- */
- public int getMatchCount() {
- return matchCount;
- }
-
- /**
- * Set the starting number of matches for the search operation
- *
- * @param matchCount
- * The matchCount to set.
- */
- public void setMatchCount(int matchCount) {
- this.matchCount = matchCount;
- }
-} \ No newline at end of file
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/ui/BugzillaNodeLabelProvider.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/ui/BugzillaNodeLabelProvider.java
deleted file mode 100644
index 01a2f5791..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/ui/BugzillaNodeLabelProvider.java
+++ /dev/null
@@ -1,67 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on Apr 18, 2005
- */
-package org.eclipse.mylar.tasks.bugzilla.ui;
-
-import org.eclipse.jface.viewers.ILabelProvider;
-import org.eclipse.jface.viewers.ILabelProviderListener;
-import org.eclipse.mylar.bugzilla.core.BugReport;
-import org.eclipse.mylar.core.model.ITaskscapeNode;
-import org.eclipse.mylar.tasks.MylarTasksPlugin;
-import org.eclipse.mylar.tasks.bugzilla.BugzillaReportNode;
-import org.eclipse.mylar.ui.MylarImages;
-import org.eclipse.swt.graphics.Image;
-
-/**
- * @author Mik Kersten
- */
-public class BugzillaNodeLabelProvider implements ILabelProvider {
-
- public Image getImage(Object element) {
- return MylarImages.getImage(MylarImages.BUG);
- }
-
- /**
- * TODO: slow?
- */
- public String getText(Object element) {
- ITaskscapeNode node = (ITaskscapeNode)element;
-
- // try to get from the cache before downloading
- Object report;
- BugzillaReportNode reportNode = MylarTasksPlugin.getReferenceProvider().getCached(node.getElementHandle());
- BugReport cachedReport = MylarTasksPlugin.getDefault().getStructureBridge().getCached(node.getElementHandle());
- if(reportNode != null && cachedReport == null){
- report = reportNode;
- } else{
- report = MylarTasksPlugin.getDefault().getStructureBridge().getObjectForHandle(node.getElementHandle());
- }
- return MylarTasksPlugin.getDefault().getStructureBridge().getName(report);
- }
-
- public void addListener(ILabelProviderListener listener) {
- // don't need to worry about listeners
- }
-
- public void dispose() {
- // don't care about dispose
- }
-
- public boolean isLabelProperty(Object element, String property) {
- return false;
- }
-
- public void removeListener(ILabelProviderListener listener) {
- // don't need to worry about listeners
- }
-}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/ui/BugzillaUiBridge.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/ui/BugzillaUiBridge.java
deleted file mode 100644
index 406566baa..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/bugzilla/ui/BugzillaUiBridge.java
+++ /dev/null
@@ -1,141 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on Apr 6, 2005
- */
-package org.eclipse.mylar.tasks.bugzilla.ui;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.jface.viewers.ILabelProvider;
-import org.eclipse.jface.viewers.TreeViewer;
-import org.eclipse.mylar.bugzilla.ui.BugzillaOpenStructure;
-import org.eclipse.mylar.bugzilla.ui.ViewBugzillaAction;
-import org.eclipse.mylar.bugzilla.ui.editor.AbstractBugEditor;
-import org.eclipse.mylar.bugzilla.ui.outline.BugzillaOutlinePage;
-import org.eclipse.mylar.core.model.ITaskscapeNode;
-import org.eclipse.mylar.tasks.BugzillaTask;
-import org.eclipse.mylar.tasks.ITask;
-import org.eclipse.mylar.tasks.MylarTasksPlugin;
-import org.eclipse.mylar.tasks.bugzilla.BugzillaReferencesProvider;
-import org.eclipse.mylar.tasks.ui.BugzillaTaskEditor;
-import org.eclipse.mylar.ui.IMylarUiBridge;
-import org.eclipse.mylar.ui.MylarImages;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.IEditorReference;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.internal.Workbench;
-
-public class BugzillaUiBridge implements IMylarUiBridge {
-
- protected BugzillaNodeLabelProvider labelProvider = new BugzillaNodeLabelProvider();
-
- public void open(ITaskscapeNode node) {
- String handle = node.getElementHandle();
- String bugHandle = handle;
- String server =handle.substring(0, handle.indexOf(";"));
-
- handle = handle.substring(handle.indexOf(";") + 1);
- int next = handle.indexOf(";");
-
- int bugId;
- int commentNumer = -1;
- if(next == -1){
- bugId = Integer.parseInt(handle);
- }
- else{
- bugId = Integer.parseInt(handle.substring(0, handle.indexOf(";")));
- commentNumer = Integer.parseInt(handle.substring(handle.indexOf(";") + 1));
- bugHandle = bugHandle.substring(0, next);
- }
-
- List<BugzillaOpenStructure> l = new ArrayList<BugzillaOpenStructure>(1);
- l.add(new BugzillaOpenStructure(server, bugId, commentNumer));
-
- ITask task= MylarTasksPlugin.getTaskListManager().getTaskList().getTaskForId(bugHandle);
- if (task != null && task instanceof BugzillaTask) {
- BugzillaTask bugzillaTask = (BugzillaTask)task;
- bugzillaTask.openTask(commentNumer);
- } else {
- // open the bug in the editor
- ViewBugzillaAction viewBugs = new ViewBugzillaAction("Display bugs in editor", l);
- viewBugs.schedule();
- }
- }
-
- public ILabelProvider getLabelProvider() {
- return labelProvider;
- }
-
- public void close(ITaskscapeNode node) {
- IWorkbenchPage page = Workbench.getInstance().getActiveWorkbenchWindow().getActivePage();
- if (page != null) {
- IEditorReference[] references = page.getEditorReferences();
- for (int i = 0; i < references.length; i++) {
- IEditorPart part = references[i].getEditor(false);
- if (part != null) {
- if (part instanceof AbstractBugEditor) {
- ((AbstractBugEditor)part).close();
- } else if(part instanceof BugzillaTaskEditor){
- ((BugzillaTaskEditor)part).close();
- }
- }
- }
- }
- }
-
- public boolean acceptsEditor(IEditorPart editorPart) {
- return editorPart instanceof AbstractBugEditor;
- }
-
- public List<TreeViewer> getTreeViewers(IEditorPart editor) {
- ArrayList<TreeViewer> outlines = new ArrayList<TreeViewer>(1);
- TreeViewer outline = getOutlineTreeViewer(editor);
- if (outline != null) {
- outlines.add(outline);
- return outlines;
- } else {
- return Collections.emptyList();
- }
- }
-
- protected TreeViewer getOutlineTreeViewer(IEditorPart editor) {
- if(editor instanceof AbstractBugEditor){
- AbstractBugEditor abe = (AbstractBugEditor)editor;
- BugzillaOutlinePage outline = abe.getOutline();
- if(outline != null) return outline.getOutlineTreeViewer();
- }
- return null;
- }
-
- public void refreshOutline(Object element, boolean updateLabels) {
- IEditorPart editorPart = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage().getActiveEditor();
- TreeViewer treeViewer = getOutlineTreeViewer(editorPart);
- if (treeViewer != null) {
- treeViewer.refresh(true);
-
- treeViewer.expandAll();
- }
- }
-
- public ImageDescriptor getIconForRelationship(String relationshipHandle) {
- return MylarImages.EDGE_REF_BUGZILLA;
-
- }
-
- public String getNameForRelationship(String relationshipHandle) {
- return BugzillaReferencesProvider.NAME;
- }
-}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/BugzillaTaskEditor.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/BugzillaTaskEditor.java
deleted file mode 100644
index bc450ce42..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/BugzillaTaskEditor.java
+++ /dev/null
@@ -1,291 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on 31-Jan-2005
- */
-package org.eclipse.mylar.tasks.ui;
-
-import org.eclipse.core.resources.IMarker;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.mylar.bugzilla.IBugzillaAttributeListener;
-import org.eclipse.mylar.bugzilla.core.BugReport;
-import org.eclipse.mylar.bugzilla.ui.editor.AbstractBugEditor;
-import org.eclipse.mylar.bugzilla.ui.editor.ExistingBugEditor;
-import org.eclipse.mylar.bugzilla.ui.editor.ExistingBugEditorInput;
-import org.eclipse.mylar.core.MylarPlugin;
-import org.eclipse.mylar.tasks.BugzillaTask;
-import org.eclipse.mylar.tasks.MylarTasksPlugin;
-import org.eclipse.mylar.tasks.ui.views.TaskListView;
-import org.eclipse.mylar.ui.MylarImages;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.ui.IEditorInput;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.IEditorSite;
-import org.eclipse.ui.IPartListener;
-import org.eclipse.ui.IWorkbench;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.IWorkbenchPart;
-import org.eclipse.ui.IWorkbenchWindow;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.internal.Workbench;
-import org.eclipse.ui.part.MultiPageEditorPart;
-import org.eclipse.ui.views.contentoutline.IContentOutlinePage;
-
-/**
- * @author Eric Booth
- */
-public class BugzillaTaskEditor extends MultiPageEditorPart {
-
- /** The task that created this editor */
- protected BugzillaTask bugTask;
-
- /** This bug report can be modified by the user and saved offline. */
- protected BugReport offlineBug;
-
- private ExistingBugEditor bugzillaEditor;
-
- private BugzillaTaskEditorInput bugzillaEditorInput;
-
- private TaskSummaryEditor taskSummaryEditor = new TaskSummaryEditor();
-
- protected IContentOutlinePage outlinePage = null;
-
- private IBugzillaAttributeListener ATTRIBUTE_LISTENER = new IBugzillaAttributeListener() {
- public void attributeChanged(String attribute, String value) {
- if (attribute.equals("Priority")) {
- bugTask.setPriority(value);
- if (TaskListView.getDefault() != null) TaskListView.getDefault().notifyTaskDataChanged(bugTask);
- }
- }
- };
-
-
- public BugzillaTaskEditor() {
- super();
-
- // get the workbench page and add a listener so we can detect when it closes
- IWorkbench wb = MylarTasksPlugin.getDefault().getWorkbench();
- IWorkbenchWindow aw = wb.getActiveWorkbenchWindow();
- IWorkbenchPage ap = aw.getActivePage();
- BugzillaTaskEditorListener listener = new BugzillaTaskEditorListener();
- ap.addPartListener(listener);
-
- bugzillaEditor = new ExistingBugEditor();
- bugzillaEditor.addAttributeListener(ATTRIBUTE_LISTENER);
- taskSummaryEditor = new TaskSummaryEditor();
- }
-
- public AbstractBugEditor getBugzillaEditor(){
- return bugzillaEditor;
- }
-
- public TaskSummaryEditor getTaskEditor(){
- return taskSummaryEditor;
- }
-
-
- public void gotoMarker(IMarker marker) {
- // don't do anything
- }
-
- /**
- * Creates page 1 of the multi-page editor,
- * which allows you to change the font used in page 2.
- */
- private void createBugzillaSubmitPage() {
- bugzillaEditor.createPartControl(getContainer());
- Composite composite = bugzillaEditor.getEditorComposite();
- int index = addPage(composite);
- setPageText(index, "Bugzilla");
- }
-
-
- private void createSummaryPage() {
- try{
- int index = addPage(taskSummaryEditor, new TaskEditorInput(bugTask));
- setPageText(index, "Summary");
- }catch(Exception e){
- MylarPlugin.log(e, "summary failed");
- }
- }
-
- /**
- * Creates the pages of the multi-page editor.
- */
- @Override
- protected void createPages() {
- createBugzillaSubmitPage();
- createSummaryPage();
- }
-
- /**
- * Saves the multi-page editor's document.
- */
- @Override
- public void doSave(IProgressMonitor monitor) {
- getEditor(0).doSave(monitor);
- }
-
- /**
- * Saves the multi-page editor's document as another file.
- * Also updates the text for page 0's tab, and updates this multi-page editor's input
- * to correspond to the nested editor's.
- */
- @Override
- public void doSaveAs() {
- IEditorPart editor = getEditor(0);
- editor.doSaveAs();
- setPageText(0, editor.getTitle());
- setInput(editor.getEditorInput());
- }
-
- @Override
- public void init(IEditorSite site, IEditorInput editorInput) throws PartInitException {
- if (!(editorInput instanceof BugzillaTaskEditorInput))
- throw new PartInitException("Invalid Input: Must be BugzillaTaskEditorInput");
- bugzillaEditorInput = (BugzillaTaskEditorInput) editorInput;
- bugTask = bugzillaEditorInput.getBugTask();
-
- offlineBug = bugzillaEditorInput.getOfflineBug();
- super.init(site, editorInput);
- super.setSite(site);
- super.setInput(editorInput);
-
- try {
- bugzillaEditor.init(this.getEditorSite(), this.getEditorInput());
- }
- catch (Exception e) {
- throw new PartInitException(e.getMessage());
- }
-
- // Set the title on the editor's tab
- this.setPartName("Bug #" + bugzillaEditorInput.getBugId());
- this.setTitleImage(MylarImages.getImage(MylarImages.TASK_BUGZILLA));
- }
-
- @Override
- public boolean isSaveAsAllowed() {
- return false;
- }
-
- /**
- * Calculates the contents of page 2 when the it is activated.
- */
- @Override
- protected void pageChange(int newPageIndex) {
- super.pageChange(newPageIndex);
- }
-
- /**
- * Sets the font related data to be applied to the text in page 2.
- */
- @Override
- public void setFocus() {
- // The default focus for this editor is the submit page
- bugzillaEditor.setFocus();
- }
-
- /**
- * @return Returns the bugTask.
- */
- public BugzillaTask getBugTask() {
- return bugTask;
- }
-
- /**
- * @return Returns the offlineBug.
- */
- public BugReport getOfflineBug() {
- return offlineBug;
- }
-
- /**
- * Updates the title of the editor to reflect dirty status.
- * If the bug report has been modified but not saved, then
- * an indicator will appear in the title.
- * @param isDirty
- * is true when the bug report has been modified but not saved
- */
- public void showDirtyStatus(boolean isDirty) {
- String prefix = (isDirty) ? "*" : "" ;
- setPartName(prefix + "Bug #" + bugzillaEditorInput.getBugId());
- }
-
- /**
- * Class to listen for editor events
- */
- private class BugzillaTaskEditorListener implements IPartListener
- {
-
- public void partActivated(IWorkbenchPart part) {
- // don't care about this event
- }
-
- public void partBroughtToTop(IWorkbenchPart part) {
- // don't care about this event
- }
-
- public void partClosed(IWorkbenchPart part) {
-
- // if we are closing a bug editor
- if (part instanceof BugzillaTaskEditor) {
- BugzillaTaskEditor taskEditor = (BugzillaTaskEditor)part;
-
- // check if it needs to be saved
- if (taskEditor.bugzillaEditor.isDirty) {
- // ask the user whether they want to save it or not and perform the appropriate action
- taskEditor.bugzillaEditor.changeDirtyStatus(false);
- boolean response = MessageDialog.openQuestion(null, "Save Changes",
- "You have made some changes to the bug, do you want to save them?");
- if (response) {
- taskEditor.bugzillaEditor.saveBug();
- } else {
- ExistingBugEditorInput input = (ExistingBugEditorInput)taskEditor.bugzillaEditor.getEditorInput();
- bugTask.setPriority(input.getBug().getAttribute("Priority").getValue());
- }
- }
- }
- }
-
- public void partDeactivated(IWorkbenchPart part) {
- // don't care about this event
- }
-
- public void partOpened(IWorkbenchPart part) {
- // don't care about this event
- }
- }
-
- public void makeNewPage(BugReport serverBug, String newCommentText) {
- if (serverBug == null) {
- MessageDialog.openInformation(Workbench.getInstance().getActiveWorkbenchWindow().getShell(),
- "Could not open bug.", "Bug #" + offlineBug.getId()
- + " could not be read from the server. Try refreshing the bug task.");
- return;
- }
- }
-
- @Override
- public Object getAdapter(Class adapter) {
- return bugzillaEditor.getAdapter(adapter);
- }
-
- public void close() {
- Display display= getSite().getShell().getDisplay();
- display.asyncExec(new Runnable() {
- public void run() {
- getSite().getPage().closeEditor(BugzillaTaskEditor.this, false);
- }
- });
- }
-}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/BugzillaTaskEditorInput.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/BugzillaTaskEditorInput.java
deleted file mode 100644
index af9e7f5e9..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/BugzillaTaskEditorInput.java
+++ /dev/null
@@ -1,135 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on 1-Feb-2005
- */
-package org.eclipse.mylar.tasks.ui;
-
-import java.io.IOException;
-
-import javax.security.auth.login.LoginException;
-
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.mylar.bugzilla.core.BugReport;
-import org.eclipse.mylar.bugzilla.ui.editor.ExistingBugEditorInput;
-import org.eclipse.mylar.tasks.BugzillaTask;
-import org.eclipse.ui.IPersistableElement;
-
-
-/**
- * @author Eric Booth
- */
-public class BugzillaTaskEditorInput extends ExistingBugEditorInput {
-
-
- private String bugTitle;
-
- private BugReport offlineBug;
-
- private BugzillaTask bugTask;
-
- public BugzillaTaskEditorInput(BugzillaTask bugTask) throws LoginException, IOException {
- super(BugzillaTask.getBugId(bugTask.getHandle()));
- this.bugTask = bugTask;
- offlineBug = bugTask.getBugReport();
- bugId = BugzillaTask.getBugId(bugTask.getHandle());
- bugTitle = "";
- }
-
- protected void setBugTitle(String str) {
- // 03-20-03 Allows editor to store title (once it is known)
- bugTitle = str;
- }
-
- @Override
- public boolean exists() {
- return true;
- }
-
- @Override
- public ImageDescriptor getImageDescriptor() {
- return null;
- }
-
- @Override
- public String getName() {
- return "Bug #" + bugId;
- }
-
- @Override
- public IPersistableElement getPersistable() {
- return null;
- }
-
- @Override
- public String getToolTipText() {
- return bugTitle;
- }
-
- @Override
- public Object getAdapter(Class adapter) {
- return null;
- }
-
- @Override
- public int getBugId() {
- return bugId;
- }
-
- /**
- * Returns the online server bug for this input
- *
- * @see BugzillaRepository
- * @see BugReport
- */
-// public BugReport getServerBug() {
-// return serverBug;
-// }
-
- /**
- * Returns the offline bug for this input's Bugzilla task
- */
- public BugReport getOfflineBug() {
- return offlineBug;
- }
-
- /**
- * Gets the bug page input stream
- */
-// public InputStream getInputStream() throws IOException {
-// try {
-// return url.openStream();
-// }
-// catch (Exception e) {
-// throw new IOException(e.getMessage());
-// }
-//
-// }
-
- /**
- * 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 BugzillaTaskEditorInput) {
- BugzillaTaskEditorInput input = (BugzillaTaskEditorInput) o;
- return getBugId() == input.getBugId();
- }
- return false;
- }
-
- /**
- * @return Returns the <code>BugzillaTask</code>
- */
- public BugzillaTask getBugTask() {
- return bugTask;
- }
-}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/TaskEditor.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/TaskEditor.java
deleted file mode 100644
index dc196f992..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/TaskEditor.java
+++ /dev/null
@@ -1,161 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on 19-Jan-2005
- */
-package org.eclipse.mylar.tasks.ui;
-
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.mylar.tasks.ITask;
-import org.eclipse.mylar.tasks.MylarTasksPlugin;
-import org.eclipse.ui.IEditorInput;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.IEditorSite;
-import org.eclipse.ui.IPartListener;
-import org.eclipse.ui.IWorkbench;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.IWorkbenchPart;
-import org.eclipse.ui.IWorkbenchWindow;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.part.MultiPageEditorPart;
-
-
-/**
- * @author Eric Booth
- */
-public class TaskEditor extends MultiPageEditorPart {
-
- protected ITask task;
- private TaskSummaryEditor taskSummaryEditor;
- private TaskEditorInput taskEditorInput;
-
- public TaskEditor() {
- super();
-
- // get the workbench page and add a listener so we can detect when it closes
- IWorkbench wb = MylarTasksPlugin.getDefault().getWorkbench();
- IWorkbenchWindow aw = wb.getActiveWorkbenchWindow();
- IWorkbenchPage ap = aw.getActivePage();
- TaskEditorListener listener = new TaskEditorListener();
- ap.addPartListener(listener);
-
- taskSummaryEditor = new TaskSummaryEditor();
- }
-
- /**
- * Creates page 1 of the multi-page editor,
- * which displays the task for viewing.
- */
- private void createTaskSummaryPage() {
- taskSummaryEditor.createPartControl(getContainer());
- int index = addPage(taskSummaryEditor.getControl());
- setPageText(index, "Summary");
- }
-
- /**
- * Creates the pages of the multi-page editor.
- */
- @Override
- protected void createPages() {
- createTaskSummaryPage();
- }
-
- @Override
- public void doSave(IProgressMonitor monitor) {
- getEditor(0).doSave(monitor);
- }
-
- /**
- * Saves the multi-page editor's document as another file.
- * Also updates the text for page 0's tab, and updates this multi-page editor's input
- * to correspond to the nested editor's.
- *
- * @see org.eclipse.ui.ISaveablePart#doSaveAs()
- */
- @Override
- public void doSaveAs() {
- IEditorPart editor = getEditor(0);
- editor.doSaveAs();
- setPageText(0, editor.getTitle());
- setInput(editor.getEditorInput());
- }
-
- @Override
- public void init(IEditorSite site, IEditorInput input) throws PartInitException {
-
- if (!(input instanceof TaskEditorInput))
- throw new PartInitException("Invalid Input: Must be TaskEditorInput");
- taskEditorInput = (TaskEditorInput)input;
- super.init(site, input);
-
- /*
- * The task data is saved only once, at the initialization of the editor. This is
- * then passed to each of the child editors. This way, only one instance of
- * the task data is stored for each editor opened.
- */
- task = taskEditorInput.getTask();
- try {
- taskSummaryEditor.init(this.getEditorSite(), this.getEditorInput());
- taskSummaryEditor.setTask(task);
- // Set the title on the editor's tab
- this.setPartName(taskEditorInput.getLabel());
- } catch (Exception e) {
- throw new PartInitException(e.getMessage());
- }
- }
-
- @Override
- public boolean isSaveAsAllowed() {
- return false;
- }
-
- /**
- * Class to listen for editor events
- */
- private class TaskEditorListener implements IPartListener
- {
-
- /**
- * @see org.eclipse.ui.IPartListener#partActivated(org.eclipse.ui.IWorkbenchPart)
- */
- public void partActivated(IWorkbenchPart part) {
- // don't care about this event
- }
-
- /**
- * @see org.eclipse.ui.IPartListener#partBroughtToTop(org.eclipse.ui.IWorkbenchPart)
- */
- public void partBroughtToTop(IWorkbenchPart part) {
- // don't care about this event
- }
-
- /**
- * @see org.eclipse.ui.IPartListener#partClosed(org.eclipse.ui.IWorkbenchPart)
- */
- public void partClosed(IWorkbenchPart part) {
- // don't care about this event
- }
-
- /**
- * @see org.eclipse.ui.IPartListener#partDeactivated(org.eclipse.ui.IWorkbenchPart)
- */
- public void partDeactivated(IWorkbenchPart part) {
- // don't care about this event
- }
-
- /**
- * @see org.eclipse.ui.IPartListener#partOpened(org.eclipse.ui.IWorkbenchPart)
- */
- public void partOpened(IWorkbenchPart part) {
- // don't care about this event
- }
- }
-}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/TaskEditorCopyAction.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/TaskEditorCopyAction.java
deleted file mode 100644
index 90af072f7..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/TaskEditorCopyAction.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on 20-Jan-2005
- */
-package org.eclipse.mylar.tasks.ui;
-
-import org.eclipse.jface.action.Action;
-
-/**
- * TODO: delete?
- */
-public class TaskEditorCopyAction extends Action {
-
- public TaskEditorCopyAction() {
- setText("TaskSummaryEditor.copy.text");
- }
-
- @Override
- public void run() {
-// if (editorPart instanceof TaskSummaryEditor)
-// ((TaskSummaryEditor)editorPart).getCurrentText().copy();
- }
-
-}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/TaskEditorInput.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/TaskEditorInput.java
deleted file mode 100644
index 8c6e04b33..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/TaskEditorInput.java
+++ /dev/null
@@ -1,113 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on 19-Jan-2005
- */
-package org.eclipse.mylar.tasks.ui;
-
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.mylar.tasks.ITask;
-import org.eclipse.ui.IEditorInput;
-import org.eclipse.ui.IPersistableElement;
-
-
-/**
- * @author Eric Booth
- */
-public class TaskEditorInput implements IEditorInput {
-
- private ITask task;
-
- private String id;
-
- private String label;
-
- public TaskEditorInput(ITask task) {
- this.task = task;
- id = task.getHandle();
- label = task.getLabel();
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.ui.IEditorInput#exists()
- */
- public boolean exists() {
- return true;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.ui.IEditorInput#getImageDescriptor()
- */
- public ImageDescriptor getImageDescriptor() {
- return null;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.ui.IEditorInput#getName()
- */
- public String getName() {
- return "Task #" + id;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.ui.IEditorInput#getPersistable()
- */
- public IPersistableElement getPersistable() {
- return null;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.ui.IEditorInput#getToolTipText()
- */
- public String getToolTipText() {
- return label;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.core.runtime.IAdaptable#getAdapter(java.lang.Class)
- */
- public Object getAdapter(Class adapter) {
- return null;
- }
-
- /**
- * @return Returns the task.
- */
- public ITask getTask() {
- return task;
- }
-
- /**
- * @return Returns the id.
- */
- public String getId() {
- return id;
- }
-
- /**
- * @return Returns the label.
- */
- public String getLabel() {
- 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() == input.getId();
- }
- return false;
- }
-}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/TaskSummaryEditor.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/TaskSummaryEditor.java
deleted file mode 100644
index 1b1e5f5ad..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/TaskSummaryEditor.java
+++ /dev/null
@@ -1,1261 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on 19-Jan-2005
- *
- * TODO To change the template for this generated file go to
- * Window - Preferences - Java - Code Style - Code Templates
- */
-package org.eclipse.mylar.tasks.ui;
-
-import java.net.MalformedURLException;
-import java.net.URL;
-import java.util.List;
-
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.jface.action.Action;
-import org.eclipse.jface.action.IMenuListener;
-import org.eclipse.jface.action.IMenuManager;
-import org.eclipse.jface.action.MenuManager;
-import org.eclipse.jface.dialogs.InputDialog;
-import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.jface.viewers.CellEditor;
-import org.eclipse.jface.viewers.ColumnWeightData;
-import org.eclipse.jface.viewers.ICellModifier;
-import org.eclipse.jface.viewers.IColorProvider;
-import org.eclipse.jface.viewers.IStructuredContentProvider;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.ITableLabelProvider;
-import org.eclipse.jface.viewers.LabelProvider;
-import org.eclipse.jface.viewers.TableLayout;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.jface.viewers.TextCellEditor;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerSorter;
-import org.eclipse.mylar.core.MylarPlugin;
-import org.eclipse.mylar.tasks.ITask;
-import org.eclipse.mylar.tasks.ITaskActivityListener;
-import org.eclipse.mylar.tasks.MylarTasksPlugin;
-import org.eclipse.mylar.tasks.RelatedLinks;
-import org.eclipse.mylar.tasks.ui.views.TaskListView;
-import org.eclipse.mylar.tasks.util.RelativePathUtil;
-import org.eclipse.mylar.ui.MylarImages;
-import org.eclipse.mylar.ui.MylarUiPlugin;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.SWTException;
-import org.eclipse.swt.events.FocusEvent;
-import org.eclipse.swt.events.FocusListener;
-import org.eclipse.swt.events.MouseEvent;
-import org.eclipse.swt.events.MouseTrackListener;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.Cursor;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.FileDialog;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Menu;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableColumn;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.ui.IEditorInput;
-import org.eclipse.ui.IEditorSite;
-import org.eclipse.ui.ISharedImages;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.actions.ActionFactory;
-import org.eclipse.ui.actions.RetargetAction;
-import org.eclipse.ui.browser.IWebBrowser;
-import org.eclipse.ui.forms.FormColors;
-import org.eclipse.ui.forms.events.ExpansionEvent;
-import org.eclipse.ui.forms.events.IExpansionListener;
-import org.eclipse.ui.forms.widgets.ExpandableComposite;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.forms.widgets.ScrolledForm;
-import org.eclipse.ui.forms.widgets.Section;
-import org.eclipse.ui.forms.widgets.TableWrapData;
-import org.eclipse.ui.forms.widgets.TableWrapLayout;
-import org.eclipse.ui.internal.WorkbenchImages;
-import org.eclipse.ui.internal.WorkbenchMessages;
-import org.eclipse.ui.internal.browser.WorkbenchBrowserSupport;
-import org.eclipse.ui.part.EditorPart;
-
-/**
- * For details on forms, go to:
- * http://dev.eclipse.org/viewcvs/index.cgi/%7Echeckout%7E/pde-ui-home/working/EclipseForms/EclipseForms.html
- * @author Ken Sueda
- */
-public class TaskSummaryEditor extends EditorPart {
- private ITask task;
- private TaskEditorInput editorInput;
- private Composite editorComposite;
- private TaskEditorCopyAction copyAction;
- private RetargetAction pasteAction;
- private RetargetAction cutAction;
- private static final String cutActionDefId = "org.eclipse.ui.edit.cut";
- private static final String pasteActionDefId = "org.eclipse.ui.edit.paste";
- private Table table;
- private TableViewer tableViewer;
- private RelatedLinks links;
- private RelatedLinksContentProvider contentProvider;
-
- private Button browse;
- private Text pathText;
- private ScrolledForm sform;
- private Action add;
- private Action delete;
- private Text description;
-
- private ITaskActivityListener TASK_LIST_LISTENER = new ITaskActivityListener() {
- public void taskActivated(ITask activeTask) {
- if (task != null && !browse.isDisposed() && activeTask.getHandle().equals(task.getHandle())) {
- browse.setEnabled(false);
- }
- }
-
- public void tasksActivated(List<ITask> tasks) {
- for (ITask t : tasks) {
- taskActivated(t);
- }
- }
-
- public void taskDeactivated(ITask deactiveTask) {
- if (task != null && !browse.isDisposed() && deactiveTask.getHandle().equals(task.getHandle())) {
- browse.setEnabled(true);
- }
- }
-
- public void taskPropertyChanged(ITask updatedTask, String property) {
- if (task != null && updatedTask.getHandle().equals(task.getHandle())) {
- if (property.equals("Description") && !description.isDisposed()) {
- description.setText(task.getLabel());
- } else if (property.equals("Path") && !pathText.isDisposed()) {
- pathText.setText("<Mylar_Dir>/" + task.getPath());
- }
- }
- }
- };
- /**
- *
- */
- public TaskSummaryEditor() {
- super();
-
- cutAction = new RetargetAction(ActionFactory.CUT.getId(),
- WorkbenchMessages.Workbench_cut);
- cutAction.setToolTipText(
- WorkbenchMessages.Workbench_cutToolTip);
- cutAction.setImageDescriptor(WorkbenchImages.getImageDescriptor(
- ISharedImages.IMG_TOOL_CUT));
- cutAction.setHoverImageDescriptor(WorkbenchImages.getImageDescriptor(
- ISharedImages.IMG_TOOL_CUT));
- cutAction.setDisabledImageDescriptor(WorkbenchImages.getImageDescriptor(
- ISharedImages.IMG_TOOL_CUT_DISABLED));
- cutAction.setAccelerator(SWT.CTRL | 'x');
- cutAction.setActionDefinitionId(cutActionDefId);
-
- pasteAction = new RetargetAction(ActionFactory.PASTE.getId(),
- WorkbenchMessages.Workbench_paste);
- pasteAction.setToolTipText(
- WorkbenchMessages.Workbench_pasteToolTip);
- pasteAction.setImageDescriptor(WorkbenchImages.getImageDescriptor(
- ISharedImages.IMG_TOOL_PASTE));
- pasteAction.setHoverImageDescriptor(WorkbenchImages.getImageDescriptor(
- ISharedImages.IMG_TOOL_PASTE));
- pasteAction.setDisabledImageDescriptor(WorkbenchImages.getImageDescriptor(
- ISharedImages.IMG_TOOL_PASTE_DISABLED));
- pasteAction.setAccelerator(SWT.CTRL | 'v');
- pasteAction.setActionDefinitionId(pasteActionDefId);
-
- copyAction = new TaskEditorCopyAction();
- copyAction.setText(
- WorkbenchMessages.Workbench_copy);
- copyAction.setImageDescriptor(WorkbenchImages.getImageDescriptor(
- ISharedImages.IMG_TOOL_COPY));
- copyAction.setHoverImageDescriptor(WorkbenchImages.getImageDescriptor(
- ISharedImages.IMG_TOOL_COPY));
- copyAction.setDisabledImageDescriptor(WorkbenchImages.getImageDescriptor(
- ISharedImages.IMG_TOOL_COPY_DISABLED));
- copyAction.setAccelerator(SWT.CTRL | 'c');
-
- copyAction.setEnabled(false);
- MylarTasksPlugin.getTaskListManager().addListener(TASK_LIST_LISTENER);
- }
- @Override
- public void doSave(IProgressMonitor monitor) {
- // don't support saving
- }
- @Override
- public void doSaveAs() {
- // don't support saving
- }
- @Override
- public void init(IEditorSite site, IEditorInput input) throws PartInitException {
- if (!(input instanceof TaskEditorInput)) {
- throw new PartInitException("Invalid Input: Must be TaskEditorInput");
- }
- setSite(site);
- setInput(input);
- editorInput = (TaskEditorInput)input;
- setPartName(editorInput.getLabel());
- }
- @Override
- public boolean isDirty() {
- return false;
- }
- @Override
- public boolean isSaveAsAllowed() {
- return false;
- }
-
- @Override
- public void createPartControl(Composite parent) {
-// ManagedForm form = new ManagedForm(parent);
-// FormToolkit toolkit = form.getToolkit();
-// editorComposite = form.getForm();
- FormToolkit toolkit = new FormToolkit(parent.getDisplay());
- sform = toolkit.createScrolledForm(parent);
- sform.getBody().setLayout(new TableWrapLayout());
- editorComposite = sform.getBody();
-
-
- TableWrapLayout layout = new TableWrapLayout();
- layout.bottomMargin = 10;
- layout.topMargin = 10;
- layout.leftMargin = 10;
- layout.rightMargin = 10;
- layout.numColumns = 1;
- layout.makeColumnsEqualWidth = true;
- layout.verticalSpacing = 20;
- layout.horizontalSpacing = 10;
- editorComposite.setLayout(layout);
- //editorComposite.setLayoutData(new TableWrapData(TableWrapData.FILL_GRAB));
-
- // Put the info onto the editor
- createContent(editorComposite, toolkit);
- }
-
- @Override
- public void setFocus() {
- // don't care when the focus is set
- }
-
- /**
- * @return Returns the editorComposite.
- */
- public Composite getEditorComposite() {
- return editorComposite;
- }
-
- public Control getControl() {
- return sform;
- }
-
- public void setTask(ITask task) throws Exception {
- if (task == null)
- throw new Exception("ITask object is null.");
- this.task = task;
- }
-
- private Composite createContent(Composite parent, FormToolkit toolkit) {
- TaskEditorInput taskEditorInput = (TaskEditorInput)getEditorInput();
-
- task = taskEditorInput.getTask();
- if (task == null) {
- MessageDialog.openError(parent.getShell(), "No such task", "No task exists with this id");
- return null;
- }
-
- try {
- createTaskSection(parent, toolkit);
- createNotesSection(parent, toolkit);
- createPlanningGameSection(parent, toolkit);
- createRelatedLinksSection(parent, toolkit);
- createDetailsSection(parent, toolkit);
- } catch (SWTException e) {
- MylarPlugin.log(e, "content failed");
- }
- return null;
- }
-
- private void createTaskSection(Composite parent, FormToolkit toolkit) {
- Section section = toolkit.createSection(parent, ExpandableComposite.TITLE_BAR);
- section.setText("Mylar Task Description");
- section.setLayout(new TableWrapLayout());
- section.setLayoutData(new TableWrapData(TableWrapData.FILL_GRAB));
- section.addExpansionListener(new IExpansionListener() {
- public void expansionStateChanging(ExpansionEvent e) {
- sform.reflow(true);
- }
- public void expansionStateChanged(ExpansionEvent e) {
- sform.reflow(true);
- }
- });
-
- Composite container = toolkit.createComposite(section);
- section.setClient(container);
- TableWrapLayout layout = new TableWrapLayout();
- layout.numColumns = 3;
- container.setLayout(layout);
-
- Label l = toolkit.createLabel(container, "Description:");
- l.setForeground(toolkit.getColors().getColor(FormColors.TITLE));
- description = toolkit.createText(container,task.getLabel(), SWT.BORDER);
- TableWrapData td = new TableWrapData(TableWrapData.FILL_GRAB);
- td.colspan = 2;
- description.setLayoutData(td);
- description.addFocusListener(new FocusListener() {
- public void focusGained(FocusEvent e) {
- // don't care about focus gained
- }
-
- public void focusLost(FocusEvent e) {
- String label = description.getText();
- task.setLabel(label);
- refreshTaskListView(task);
- }
- });
- }
-
-// private String formatPath(String path) {
-// if (path == null) return "";
-// StringBuffer result = new StringBuffer(path.length() + 10);
-// for (int i = 0; i < path.length(); i++) {
-// if (path.charAt(i) == '\\'){
-// result.append('/');
-// } else {
-// result.append(path.charAt(i));
-// }
-// }
-//
-// return result.toString();
-// }
-
- private void createNotesSection(Composite parent, FormToolkit toolkit) {
- Section section = toolkit.createSection(parent, ExpandableComposite.TITLE_BAR);
- section.setText("Notes");
- section.setLayout(new TableWrapLayout());
- section.setLayoutData(new TableWrapData(TableWrapData.FILL_GRAB));
- section.addExpansionListener(new IExpansionListener() {
- public void expansionStateChanging(ExpansionEvent e) {
- sform.reflow(true);
- }
-
- public void expansionStateChanged(ExpansionEvent e) {
- sform.reflow(true);
- }
- });
- Composite container = toolkit.createComposite(section);
- section.setClient(container);
- TableWrapLayout layout = new TableWrapLayout();
- layout.numColumns = 2;
- container.setLayout(layout);
-
- final Text text = toolkit.createText(container, task.getNotes(), SWT.BORDER | SWT.MULTI);
- TableWrapData tablewrap = new TableWrapData(TableWrapData.FILL_GRAB);
- tablewrap.heightHint = 100;
- text.setLayoutData(tablewrap);
- text.addFocusListener(new FocusListener() {
- public void focusGained(FocusEvent e) {
- // don't care about focus gained
- }
-
- public void focusLost(FocusEvent e) {
- String notes = text.getText();
- task.setNotes(notes);
- }
- });
- }
-
- private void createPlanningGameSection(Composite parent, FormToolkit toolkit) {
- Section section = toolkit.createSection(parent, ExpandableComposite.TITLE_BAR | Section.TWISTIE);
- section.setText("Planning Game");
- section.setLayout(new TableWrapLayout());
- section.setLayoutData(new TableWrapData(TableWrapData.FILL_GRAB));
- section.addExpansionListener(new IExpansionListener() {
- public void expansionStateChanging(ExpansionEvent e) {
- sform.reflow(true);
- }
-
- public void expansionStateChanged(ExpansionEvent e) {
- sform.reflow(true);
- }
- });
- Composite container = toolkit.createComposite(section);
- section.setClient(container);
- TableWrapLayout layout = new TableWrapLayout();
- layout.numColumns = 2;
- container.setLayout(layout);
-
- Label l = toolkit.createLabel(container, "Estimated Time:");
- l.setForeground(toolkit.getColors().getColor(FormColors.TITLE));
- final Text text = toolkit.createText(container,task.getEstimatedTime(), SWT.BORDER);
- text.setLayoutData(new TableWrapData(TableWrapData.FILL_GRAB));
-
- text.addFocusListener(new FocusListener() {
- public void focusGained(FocusEvent e) {
- // don't care about focus gained
- }
-
- public void focusLost(FocusEvent e) {
- String estimate = text.getText();
- task.setEstimatedTime(estimate);
- }
- });
-
- l = toolkit.createLabel(container, "Elapsed Time:");
- l.setForeground(toolkit.getColors().getColor(FormColors.TITLE));
- Text text2 = toolkit.createText(container,task.getElapsedTime(), SWT.BORDER);
- text2.setLayoutData(new TableWrapData(TableWrapData.FILL_GRAB));
- text2.setEditable(false);
- text2.setEnabled(false);
- //text2.setForeground(background);
- }
-
- private void createRelatedLinksSection(Composite parent, FormToolkit toolkit) {
- Section section = toolkit.createSection(parent, ExpandableComposite.TITLE_BAR | Section.TWISTIE);
- section.setText("Related Links");
- section.setLayout(new TableWrapLayout());
- section.setLayoutData(new TableWrapData(TableWrapData.FILL_GRAB));
- section.addExpansionListener(new IExpansionListener() {
- public void expansionStateChanging(ExpansionEvent e) {
- sform.reflow(true);
- }
-
- public void expansionStateChanged(ExpansionEvent e) {
- sform.reflow(true);
- }
- });
- Composite container = toolkit.createComposite(section);
- section.setClient(container);
- TableWrapLayout layout = new TableWrapLayout();
- layout.numColumns = 2;
- container.setLayout(layout);
-
- Label l = toolkit.createLabel(container, "Related Links:");
- l.setForeground(toolkit.getColors().getColor(FormColors.TITLE));
- toolkit.createLabel(container, "");
-
- createTable(container, toolkit);
- createTableViewer(container, toolkit);
- toolkit.paintBordersFor(container);
- createAddDeleteButtons(container, toolkit);
- }
-
- private void createTable(Composite parent, FormToolkit toolkit) {
- table = toolkit.createTable(parent, SWT.NONE );
- TableColumn col1 = new TableColumn(table, SWT.NULL);
- TableLayout tlayout = new TableLayout();
- tlayout.addColumnData(new ColumnWeightData(0,0,false));
- table.setLayout(tlayout);
- TableWrapData wd = new TableWrapData(TableWrapData.FILL_GRAB);
- wd.heightHint = 100;
- wd.grabVertical = true;
- table.setLayoutData(wd);
- table.setHeaderVisible(false);
- col1.addSelectionListener(new SelectionAdapter() {
- @Override
- public void widgetSelected(SelectionEvent e) {
- tableViewer.setSorter(new RelatedLinksTableSorter(
- RelatedLinksTableSorter.LABEL));
- }
- });
- table.addMouseTrackListener(new MouseTrackListener() {
- public void mouseEnter(MouseEvent e) {
- if(!((RelatedLinksContentProvider)tableViewer.getContentProvider()).isEmpty()) {
- Cursor hyperlinkCursor = new Cursor(Display.getCurrent(), SWT.CURSOR_HAND);
- Display.getCurrent().getCursorControl().setCursor(hyperlinkCursor);
- }
- }
-
- public void mouseExit(MouseEvent e) {
- Cursor pointer = new Cursor(Display.getCurrent(), SWT.CURSOR_ARROW);
- Display.getCurrent().getCursorControl().setCursor(pointer);
- }
-
- public void mouseHover(MouseEvent e){
- if(!((RelatedLinksContentProvider)tableViewer.getContentProvider()).isEmpty()) {
- Cursor hyperlinkCursor = new Cursor(Display.getCurrent(), SWT.CURSOR_HAND);
- Display.getCurrent().getCursorControl().setCursor(hyperlinkCursor);
- }
- }
- });
- }
-
- private void createTableViewer(Composite parent, FormToolkit toolkit) {
- String[] columnNames = {"Links"};
- tableViewer = new TableViewer(table);
- tableViewer.setColumnProperties(columnNames);
-
- CellEditor[] editors = new CellEditor[columnNames.length];
-
- TextCellEditor textEditor = new TextCellEditor(table);
- ((Text) textEditor.getControl()).setTextLimit(50);
- ((Text) textEditor.getControl()).setOrientation(SWT.LEFT_TO_RIGHT);
- editors[0] = textEditor;
-
- tableViewer.setCellEditors(editors);
- tableViewer.setCellModifier(new RelatedLinksCellModifier());
- contentProvider = new RelatedLinksContentProvider();
- tableViewer.setContentProvider(contentProvider);
- tableViewer.setLabelProvider(new RelatedLinksLabelProvider());
- links = task.getRelatedLinks();
- tableViewer.setInput(links);
- defineActions();
- hookContextMenu();
- }
- private void createAddDeleteButtons(Composite parent, FormToolkit toolkit) {
- Composite container = toolkit.createComposite(parent);
- container.setLayout(new GridLayout(1, true));
- Button addButton = toolkit.createButton(container, " Add ", SWT.PUSH | SWT.CENTER);
- //add.setLayoutData(new TableWrapData(TableWrapData.FILL_GRAB));
- addButton.addSelectionListener(new SelectionAdapter() {
- @Override
- public void widgetSelected(SelectionEvent e) {
- addLink();
- }
- });
-
- Button deleteButton = toolkit.createButton(container, "Delete", SWT.PUSH | SWT.CENTER);
- deleteButton.setText("Delete");
- //delete.setLayoutData(new TableWrapData(TableWrapData.FILL_GRAB));
- deleteButton.addSelectionListener(new SelectionAdapter() {
-
- @Override
- public void widgetSelected(SelectionEvent e) {
- removeLink();
- }
- });
- }
-
- private void createDetailsSection(Composite parent, FormToolkit toolkit) {
- Section section = toolkit.createSection(parent, ExpandableComposite.TITLE_BAR | Section.TWISTIE);
- section.setText("Mylar Task Details");
- section.setLayout(new TableWrapLayout());
- section.setLayoutData(new TableWrapData(TableWrapData.FILL_GRAB));
- section.addExpansionListener(new IExpansionListener() {
- public void expansionStateChanging(ExpansionEvent e) {
- sform.reflow(true);
- }
- public void expansionStateChanged(ExpansionEvent e) {
- sform.reflow(true);
- }
- });
-
- Composite container = toolkit.createComposite(section);
- section.setClient(container);
- TableWrapLayout layout = new TableWrapLayout();
- layout.numColumns = 3;
- container.setLayout(layout);
-
- Label l = toolkit.createLabel(container, "Task Handle:");
- l.setForeground(toolkit.getColors().getColor(FormColors.TITLE));
- Text handle = toolkit.createText(container, task.getHandle(), SWT.BORDER);
- TableWrapData td = new TableWrapData(TableWrapData.FILL_GRAB);
- td.colspan = 2;
- handle.setLayoutData(td);
- handle.setEditable(false);
- handle.setEnabled(false);
-
-
- Label l2 = toolkit.createLabel(container, "Task context path:");
- l2.setForeground(toolkit.getColors().getColor(FormColors.TITLE));
- pathText = toolkit.createText(container, "<Mylar_Dir>/"+task.getPath()+".xml", SWT.BORDER);
- pathText.setLayoutData(new TableWrapData(TableWrapData.FILL_GRAB));
- pathText.setEditable(false);
- pathText.setEnabled(false);
-
- browse = toolkit.createButton(container, "Change", SWT.PUSH | SWT.CENTER);
- if (task.isActive()) {
- browse.setEnabled(false);
- } else {
- browse.setEnabled(true);
- }
- browse.addSelectionListener(new SelectionAdapter() {
- @Override
- public void widgetSelected(SelectionEvent e) {
-
- if (task.isActive()) {
- MessageDialog.openInformation(
- Display.getDefault().getActiveShell(),
- "Task Message",
- "Task can not be active when changing taskscape");
- } else {
- FileDialog dialog = new FileDialog(Display.getDefault()
- .getActiveShell(), SWT.OPEN);
- String[] ext = { "*.xml" };
- dialog.setFilterExtensions(ext);
-
- String mylarDir = MylarPlugin.getTaskscapeManager()
- .getMylarDir()
- + "/";
- mylarDir = mylarDir.replaceAll("\\\\", "/");
- // mylarDir = formatPath(mylarDir);
- dialog.setFilterPath(mylarDir);
-
- String res = dialog.open();
- if (res != null) {
- res = res.replaceAll("\\\\", "/");
- res = RelativePathUtil.findRelativePath(mylarDir, res);
- pathText.setText("<MylarDir>/" + res + ".xml");
- task.setPath(res);
- }
- }
- }
- });
- toolkit.createLabel(container, "");
- l = toolkit.createLabel(container, "Go to Mylar Preferences to change <Mylar_Dir>");
- l.setForeground(toolkit.getColors().getColor(FormColors.TITLE));
- }
-
- private void refreshTaskListView(ITask task) {
- if (TaskListView.getDefault() != null) TaskListView.getDefault().notifyTaskDataChanged(task);
- }
- private class RelatedLinksCellModifier implements ICellModifier, IColorProvider {
- RelatedLinksCellModifier() {
- super();
-
- }
- public boolean canModify(Object element, String property) {
- return true;
- }
- public Object getValue(Object element, String property) {
- Object res = null;
- if (element instanceof String) {
- String url = (String) element;
- try {
- IWebBrowser b = null;
- int flags = 0;
- if (WorkbenchBrowserSupport.getInstance()
- .isInternalWebBrowserAvailable()) {
- flags = WorkbenchBrowserSupport.AS_EDITOR
- | WorkbenchBrowserSupport.LOCATION_BAR
- | WorkbenchBrowserSupport.NAVIGATION_BAR;
-
- } else {
- flags = WorkbenchBrowserSupport.AS_EXTERNAL
- | WorkbenchBrowserSupport.LOCATION_BAR
- | WorkbenchBrowserSupport.NAVIGATION_BAR;
- }
- b = WorkbenchBrowserSupport.getInstance().createBrowser(
- flags, "org.eclipse.mylar.tasks", "Task", "tasktooltip");
- b.openURL(new URL((String) element));
- } catch (PartInitException e) {
- MessageDialog.openError( Display.getDefault().getActiveShell(),
- "URL not found", url + " could not be opened");
- } catch (MalformedURLException e) {
- MessageDialog.openError( Display.getDefault().getActiveShell(),
- "URL not found", url + " could not be opened");
- }
- res = (String) element;
- }
- return res;
- }
- public void modify(Object element, String property, Object value) {
- return;
- }
-
- public Color getForeground(Object element) {
- return MylarUiPlugin.getDefault().getColorMap().HYPERLINK;
- }
-
- public Color getBackground(Object element) {
- return null;
- }
- }
-
- private class RelatedLinksLabelProvider extends LabelProvider implements
- ITableLabelProvider, IColorProvider {
-
- public RelatedLinksLabelProvider() {
- // don't have any initialization to do
- }
- public String getColumnText(Object obj, int columnIndex) {
- String result = "";
- if (obj instanceof String) {
- switch (columnIndex) {
- case 0:
- result = (String) obj;
- break;
- default:
- break;
- }
- }
- return result;
- }
- public Image getColumnImage(Object obj, int columnIndex) {
- return null;
- }
- public Color getForeground(Object element) {
- return MylarUiPlugin.getDefault().getColorMap().HYPERLINK;
- }
-
- public Color getBackground(Object element) {
- return null;
- }
- }
-
- private class RelatedLinksContentProvider implements
- IStructuredContentProvider {
-
- public Object[] getElements(Object inputElement) {
- return links.getLinks().toArray();
- }
- public void dispose() {
- // don't care if we are disposed
- }
- public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
- // don't care if the input chages
- }
- public boolean isEmpty() {
- return links.getLinks().isEmpty();
- }
- }
-
- private class RelatedLinksTableSorter extends ViewerSorter {
-
- public final static int LABEL = 1;
- private int criteria;
-
- public RelatedLinksTableSorter(int criteria) {
- super();
- this.criteria = criteria;
- }
-
- @Override
- public int compare(Viewer viewer, Object o1, Object o2) {
- String s1 = (String) o1;
- String s2 = (String) o2;
- switch (criteria) {
- case LABEL:
- return compareLabel(s1, s2);
- default:
- return 0;
- }
- }
- protected int compareLabel(String s1, String s2) {
- return s1.compareTo(s2);
- }
- public int getCriteria() {
- return criteria;
- }
- }
-
- private void addLink() {
- InputDialog dialog = new InputDialog(Display.getDefault().getActiveShell(), "New related link",
- "Enter new related link for this task", "", null);
- dialog.open();
- String url = null;
- String link = dialog.getValue();
- if (!(link.startsWith("http://") || link.startsWith("https://"))) {
- url = "http://" + link;
- } else {
- url = link;
- }
- links.add(url);
- tableViewer.add(url);
- }
-
- private void removeLink() {
- String url = (String) ((IStructuredSelection) tableViewer
- .getSelection()).getFirstElement();
- if (url != null) {
- links.remove(url);
- tableViewer.remove(url);
- }
- }
- private void defineActions() {
- delete = new Action() {
- @Override
- public void run() {
- removeLink();
- }
- };
- delete.setText("Delete");
- delete.setToolTipText("Delete");
- delete.setImageDescriptor(MylarImages.REMOVE);
-
- add = new Action() {
- @Override
- public void run() {
- addLink();
- }
- };
- add.setText("Add");
- add.setToolTipText("Add");
- //add.setImageDescriptor(MylarImages.REMOVE);
- }
-
- private void hookContextMenu() {
- MenuManager menuMgr = new MenuManager("#PopupMenu");
- menuMgr.setRemoveAllWhenShown(true);
- menuMgr.addMenuListener(new IMenuListener() {
- public void menuAboutToShow(IMenuManager manager) {
- manager.add(add);
- manager.add(delete);
- }
- });
- Menu menu = menuMgr.createContextMenu(tableViewer.getControl());
- tableViewer.getControl().setMenu(menu);
- //getSite().registerContextMenu(menuMgr, tableViewer);
- }
-
-
-
-
-
-
- // Eric's Old Code...
- //
-
- //private StringBuffer sb;
- //private MenuManager contextMenuManager;
- //private final String VALUE = "VALUE";
- //private final String PROPERTY = "PROPERTY";
- //private final String HEADER = "HEADER";
- //private Color foreground;
- //private StringBuffer commentBuffer;
- //private int index;
- //private ArrayList<StyledText> texts = new ArrayList<StyledText>();
- //private StyledText currentSelectedText;
- //private Font titleFont;
- //private Font textFont;
- //private int scrollIncrement;
- //private int scrollVertPageIncrement;
- //private int scrollHorzPageIncrement;
- //private ScrolledComposite scrolledComposite;
- //private Display display;
- //private CLabel titleLabel;
- //private Composite infoArea;
- //private final int HORZ_INDENT = 0;
- //private final int HORZ_TABLE_SPACING = 10;
-
-//
-// private void focusOn(StyledText newText, int caretOffset) {
-// if (newText == null)
-// return;
-// newText.setFocus();
-// newText.setCaretOffset(caretOffset);
-// scrolledComposite.setOrigin(0, newText.getLocation().y);
-// }
-//
-// /**
-// * Find the next text
-// */
-// private StyledText nextText(StyledText text) {
-// int index = 0;
-// if (text == null)
-// return texts.get(0);
-// else
-// index = texts.indexOf(text);
-//
-// //If we are not at the end....
-// if (index < texts.size() - 1)
-// return texts.get(index + 1);
-// else
-// return texts.get(index);
-// }
-//
-// /**
-// * Find the previous text
-// */
-// private StyledText previousText(StyledText text) {
-// int index = 0;
-// if (text == null)
-// return texts.get(0);
-// else
-// index = texts.indexOf(text);
-//
-// //If we are not at the end....
-// if (index == 0)
-// return texts.get(0);
-// else
-// return texts.get(index - 1);
-// }
-//
-// protected StyledText getCurrentText() {
-// return currentSelectedText;
-// }
-//
-// protected TaskEditorCopyAction getCopyAction() {
-// return copyAction;
-// }
-//
-// private void addTextListeners(StyledText styledText) {
-// styledText.addTraverseListener(new TraverseListener() {
-// public void keyTraversed(TraverseEvent e) {
-// StyledText text = (StyledText) e.widget;
-//
-// switch (e.detail) {
-// case SWT.TRAVERSE_ESCAPE :
-// e.doit = true;
-// break;
-// case SWT.TRAVERSE_TAB_NEXT :
-//
-// text.setSelection(0);
-// StyledText nextText = nextText(text);
-// focusOn(nextText, 0);
-//
-// e.detail = SWT.TRAVERSE_NONE;
-// e.doit = true;
-// break;
-//
-// case SWT.TRAVERSE_TAB_PREVIOUS :
-//
-// text.setSelection(text.getSelection());
-// StyledText previousText = previousText(text);
-// focusOn(previousText, 0);
-//
-// e.detail = SWT.TRAVERSE_NONE;
-// e.doit = true;
-// break;
-//
-// default:
-// break;
-// }
-// }
-// });
-//
-// styledText.addKeyListener(new KeyListener() {
-// public void keyReleased(KeyEvent e) {
-// //Ignore a key release
-// }
-//
-// public void keyPressed(KeyEvent event) {
-// StyledText text = (StyledText) event.widget;
-// if (event.character == ' ' || event.character == SWT.CR) {
-// return;
-// }
-//
-// if (event.keyCode == SWT.PAGE_DOWN) {
-//
-// scrolledComposite.setOrigin(0,
-// scrolledComposite.getOrigin().y
-// + scrollVertPageIncrement);
-// return;
-// }
-// if (event.keyCode == SWT.ARROW_DOWN) {
-// scrolledComposite.setOrigin(0,
-// scrolledComposite.getOrigin().y + scrollIncrement);
-// }
-// if (event.keyCode == SWT.PAGE_UP) {
-// int origin = scrolledComposite.getOrigin().y;
-// int scrollAmount = origin - scrollVertPageIncrement;
-// if (scrollAmount <= 0) {
-// scrolledComposite.setOrigin(0, 0);
-// } else {
-// scrolledComposite.setOrigin(0, scrollAmount);
-// }
-// return;
-// }
-// if (event.keyCode == SWT.ARROW_UP) {
-// scrolledComposite.setOrigin(0,
-// scrolledComposite.getOrigin().y - scrollIncrement);
-// }
-// }
-// });
-//
-// styledText.addFocusListener(new FocusAdapter() {
-//
-// @Override
-// public void focusLost(FocusEvent e) {
-// StyledText text = (StyledText) e.widget;
-// text.setSelection(text.getSelection().x);
-// }
-// });
-// }
-
-// public void createLayouts(Composite composite, ITask task) {
-// SimpleDateFormat df = new SimpleDateFormat("yyyy-MM-dd HH:mm");
-// String title = "Task #" + task.getId();
-// newLayout(composite, 4, title, HEADER);
-// titleLabel.setText(title);
-// }
-//
-// public void displayArtifact(Composite composite) {
-// TaskEditorInput editorInput = (TaskEditorInput) getEditorInput();
-// background = JFaceColors.getBannerBackground(composite.getParent()
-// .getParent().getDisplay());
-// composite.setBackground(background);
-//
-// // Get the background color for the info area
-// composite.setBackground(background);
-//
-// // The entire info area is 4 columns in width
-// // all headers take up all 4, values take up 1
-// GridLayout infoLayout = new GridLayout();
-// infoLayout.numColumns = 4;
-// infoLayout.marginHeight = 10;
-// infoLayout.verticalSpacing = 6;
-//
-// infoLayout.marginWidth = 5;
-// infoLayout.horizontalSpacing = HORZ_TABLE_SPACING;
-// composite.setLayout(infoLayout);
-// GridData infoData = new GridData(GridData.FILL_BOTH);
-// composite.setLayoutData(infoData);
-//
-// // Create the page with the task's contents
-// task = editorInput.getTask();
-// if (task != null) {
-// createLayouts(composite, task);
-// } else {
-// MessageDialog.openError(composite.getShell(), "No such task",
-// "No task exists with this id");
-// return;
-// }
-// }
-//
-// /**
-// * Make sure that a String that is <code>null</code> is changed to a null
-// * string
-// *
-// * @param text
-// * The text to check if it is null or not
-// * @return
-// */
-// public String checkText(String text) {
-// if (text == null)
-// return "";
-// else
-// return text;
-// }
-//
-//
-// //
-//// public void newLayout(Composite composite, int colSpan, String text, String style) {
-//// GridData data = new GridData(GridData.HORIZONTAL_ALIGN_BEGINNING);
-//// data.horizontalSpan = colSpan;
-//// if (style.equalsIgnoreCase(VALUE)) {
-//// StyledText styledText = new StyledText(composite, SWT.MULTI | SWT.READ_ONLY);
-//// styledText.setFont(textFont);
-//// styledText.setText(checkText(text));
-//// styledText.setBackground(background);
-//// data.horizontalIndent = HORZ_INDENT;
-////
-//// styledText.setLayoutData(data);
-//// styledText.addSelectionListener(new SelectionAdapter() {
-////
-//// @Override
-//// public void widgetSelected(SelectionEvent e) {
-//// StyledText c = (StyledText) e.widget;
-//// if (c != null && c.getSelectionCount() > 0) {
-//// if (currentSelectedText != null) {
-//// if (!c.equals(currentSelectedText)) {
-//// currentSelectedText.setSelectionRange(0, 0);
-//// }
-//// }
-//// }
-//// currentSelectedText = c;
-//// }
-//// });
-////
-//// styledText.setMenu(contextMenuManager.createContextMenu(styledText));
-////
-//// styledText.setEditable(false);
-////
-//// if (styledText.getText().trim().length() > 0) {
-//// texts.add(index, styledText);
-//// index++;
-//// addTextListeners(styledText);
-//// }
-//// } else if (style.equalsIgnoreCase(PROPERTY)) {
-//// StyledText styledText = new StyledText(composite, SWT.MULTI | SWT.READ_ONLY);
-//// styledText.setFont(textFont);
-//// styledText.setText(checkText(text));
-//// styledText.setBackground(background);
-//// data.horizontalIndent = HORZ_INDENT;
-//// styledText.setLayoutData(data);
-//// StyleRange sr = new StyleRange(
-//// styledText.getOffsetAtLine(0),
-//// text.length(),
-//// foreground,
-//// background,
-//// SWT.BOLD);
-//// styledText.setStyleRange(sr);
-//// styledText.setEnabled(false);
-//// styledText.setMenu(contextMenuManager.createContextMenu(styledText));
-//// } else {
-//// Composite generalTitleGroup = new Composite(composite, SWT.NONE);
-//// generalTitleGroup.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-// generalTitleGroup.setLayoutData(data);
-// GridLayout generalTitleLayout = new GridLayout();
-// generalTitleLayout.numColumns = 2;
-// generalTitleLayout.marginWidth = 0;
-// generalTitleLayout.marginHeight = 9;
-// generalTitleGroup.setLayout(generalTitleLayout);
-// generalTitleGroup.setBackground(background);
-//
-// Label image = new Label(generalTitleGroup, SWT.NONE);
-// image.setBackground(background);
-// image.setImage(
-// WorkbenchImages.getImage(IDEInternalWorkbenchImages.IMG_OBJS_WELCOME_ITEM));
-// GridData gd = new GridData(GridData.FILL_VERTICAL);
-// gd.verticalAlignment = GridData.VERTICAL_ALIGN_BEGINNING;
-// image.setLayoutData(gd);
-// StyledText generalTitleText = new StyledText(generalTitleGroup, SWT.MULTI | SWT.READ_ONLY);
-// generalTitleText.setText(checkText(text));
-// generalTitleText.setBackground(background);
-// StyleRange sr = new StyleRange(
-// generalTitleText.getOffsetAtLine(0),
-// text.length(),
-// foreground,
-// background,
-// SWT.BOLD);
-// generalTitleText.setStyleRange(sr);
-// generalTitleText.setEditable(false);
-//
-// generalTitleText.addSelectionListener(new SelectionAdapter() {
-//
-// @Override
-// public void widgetSelected(SelectionEvent e) {
-// StyledText c = (StyledText) e.widget;
-// if (c != null && c.getSelectionCount() > 0) {
-// if (currentSelectedText != null) {
-// if (!c.equals(currentSelectedText)) {
-// currentSelectedText.setSelectionRange(0, 0);
-// }
-// }
-// }
-// currentSelectedText = c;
-// }
-// });
-//
-// // create context menu
-// generalTitleGroup.setMenu(contextMenuManager.createContextMenu(generalTitleGroup));
-// generalTitleText.setMenu(contextMenuManager.createContextMenu(generalTitleText));
-// image.setMenu(contextMenuManager.createContextMenu(image));
-// }
-// }
-
-// private Composite createTitleArea(Composite parent) {
- //
-// // Get the background color for the title area
-// display = parent.getDisplay();
-// Color background = JFaceColors.getBannerBackground(display);
-// Color foreground = JFaceColors.getBannerForeground(display);
-//
-// // Create the title area which will contain
-// // a title, message, and image.
-// Composite titleArea = new Composite(parent, SWT.NO_FOCUS);
-// GridLayout layout = new GridLayout();
-// layout.marginHeight = 0;
-// layout.marginWidth = 0;
-// layout.verticalSpacing = 0;
-// layout.horizontalSpacing = 0;
-// layout.numColumns = 2;
-// titleArea.setLayout(layout);
-// titleArea.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-// titleArea.setBackground(background);
-//
-// // Message label
-// titleLabel = new CLabel(titleArea, SWT.LEFT);
-// JFaceColors.setColors(titleLabel, foreground, background);
-// titleLabel.setFont(titleFont);
-// final IPropertyChangeListener fontListener = new IPropertyChangeListener() {
-// public void propertyChange(PropertyChangeEvent event) {
-// if (JFaceResources.HEADER_FONT.equals(event.getProperty())) {
-// titleLabel.setFont(titleFont);
-// }
-// }
-// };
-// titleLabel.addDisposeListener(new DisposeListener() {
-// public void widgetDisposed(DisposeEvent event) {
-// JFaceResources.getFontRegistry().removeListener(fontListener);
-// }
-// });
-// JFaceResources.getFontRegistry().addListener(fontListener);
-// GridData gd = new GridData(GridData.FILL_BOTH);
-// titleLabel.setLayoutData(gd);
- //
-// // Title image
-// Label titleImage = new Label(titleArea, SWT.LEFT);
-// titleImage.setBackground(background);
-// titleImage.setImage(
-// WorkbenchImages.getImage(
-// IDEInternalWorkbenchImages.IMG_OBJS_WELCOME_BANNER));
-// gd = new GridData();
-// gd.horizontalAlignment = GridData.END;
-// titleImage.setLayoutData(gd);
-// return titleArea;
-// }
- //
-// private Composite createInfoArea(Composite parent) {
-// // Create the title area which will contain a title, message, and image.
-// scrolledComposite = new ScrolledComposite(parent, SWT.V_SCROLL | SWT.H_SCROLL);
-// scrolledComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
-// infoArea = new Composite(this.scrolledComposite, SWT.NONE);
-// scrolledComposite.setMinSize(infoArea.computeSize(SWT.DEFAULT, SWT.DEFAULT));
- //
-// contextMenuManager = new MenuManager("#TaskSummaryEditor");
-// contextMenuManager.setRemoveAllWhenShown(true);
-// contextMenuManager.addMenuListener(new IMenuListener() {
-// public void menuAboutToShow(IMenuManager manager) {
-// manager.add(cutAction);
-// manager.add(copyAction);
-// manager.add(pasteAction);
-// manager.add(new Separator());
-// manager.add(new GroupMarker(IWorkbenchActionConstants.MB_ADDITIONS));
-// if (currentSelectedText == null ||
-// currentSelectedText.getSelectionText().length() == 0) {
-// copyAction.setEnabled(false);
-// }
-// else {
-// copyAction.setEnabled(true);
-// }
-// }
-// });
-// getSite().registerContextMenu(
-// "#TaskSummaryEditor",
-// contextMenuManager,
-// getSite().getSelectionProvider());
- //
-// displayArtifact(infoArea);
-// this.scrolledComposite.setContent(infoArea);
-// Point p = infoArea.computeSize(SWT.DEFAULT, SWT.DEFAULT, true);
-// this.scrolledComposite.setMinHeight(p.y);
-// this.scrolledComposite.setMinWidth(p.x);
-// this.scrolledComposite.setExpandHorizontal(true);
-// this.scrolledComposite.setExpandVertical(true);
- //
-// // Add the focus listener to the scrolled composite
-// scrolledComposite.addMouseListener(new MouseAdapter() {
-//
-// @Override
-// public void mouseUp(MouseEvent e) {
-// if (!texts.isEmpty()) {
-// StyledText target = texts.get(0);
-// target.setFocus();
-// } else {
-// scrolledComposite.setFocus();
-// }
-// }
-// });
- //
-// scrolledComposite.addControlListener(new ControlListener() {
-// public void controlMoved(ControlEvent e) {
-// // don't care if a control is moved
-// }
-// public void controlResized(ControlEvent e) {
-// scrolledComposite.getVerticalBar().setIncrement(scrollIncrement);
-// scrolledComposite.getHorizontalBar().setIncrement(scrollIncrement);
-// scrollVertPageIncrement = scrolledComposite.getClientArea().height;
-// scrollHorzPageIncrement = scrolledComposite.getClientArea().width;
-// scrolledComposite.getVerticalBar().setPageIncrement(scrollVertPageIncrement);
-// scrolledComposite.getHorizontalBar().setPageIncrement(scrollHorzPageIncrement);
-// }
-// });
-// return infoArea;
-// }
-}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/ClearContextAction.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/ClearContextAction.java
deleted file mode 100644
index a22ab1538..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/ClearContextAction.java
+++ /dev/null
@@ -1,55 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.mylar.tasks.ui.actions;
-
-import org.eclipse.jface.action.Action;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.mylar.core.MylarPlugin;
-import org.eclipse.mylar.tasks.BugzillaHit;
-import org.eclipse.mylar.tasks.BugzillaTask;
-import org.eclipse.mylar.tasks.ITask;
-import org.eclipse.mylar.tasks.Task;
-import org.eclipse.mylar.tasks.ui.views.TaskListView;
-import org.eclipse.mylar.ui.MylarImages;
-
-/**
- * @author Mik Kersten and Ken Sueda
- */
-public class ClearContextAction extends Action {
-
- public static final String ID = "org.eclipse.mylar.tasks.actions.context.clear";
-
- private final TaskListView view;
-
- public ClearContextAction(TaskListView view) {
- this.view = view;
- setText("Clear Task Context");
- setToolTipText("Clear Task Context");
- setId(ID);
- setImageDescriptor(MylarImages.ERASE_TASKSCAPE);
- }
- @Override
- public void run() {
- MylarPlugin.getDefault().actionObserved(this);
- Object selectedObject = ((IStructuredSelection)this.view.getViewer().getSelection()).getFirstElement();
- if (selectedObject != null && selectedObject instanceof ITask) {
- MylarPlugin.getTaskscapeManager().taskDeleted(((ITask)selectedObject).getHandle(), ((Task)selectedObject).getPath());
- this.view.getViewer().refresh();
- } else if (selectedObject != null && selectedObject instanceof BugzillaHit) {
- BugzillaTask task = ((BugzillaHit)selectedObject).getAssociatedTask();
- if(task != null){
- MylarPlugin.getTaskscapeManager().taskDeleted(task.getHandle(), task.getPath());
- }
- this.view.getViewer().refresh();
- }
- }
-} \ No newline at end of file
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/CreateBugzillaQueryCategoryAction.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/CreateBugzillaQueryCategoryAction.java
deleted file mode 100644
index 1faac748a..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/CreateBugzillaQueryCategoryAction.java
+++ /dev/null
@@ -1,71 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.mylar.tasks.ui.actions;
-
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.jface.action.Action;
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.mylar.core.MylarPlugin;
-import org.eclipse.mylar.tasks.BugzillaQueryCategory;
-import org.eclipse.mylar.tasks.MylarTasksPlugin;
-import org.eclipse.mylar.tasks.ui.views.BugzillaQueryDialog;
-import org.eclipse.mylar.tasks.ui.views.TaskListView;
-import org.eclipse.mylar.ui.MylarImages;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.actions.WorkspaceModifyOperation;
-import org.eclipse.ui.progress.IProgressService;
-
-/**
- * @author Mik Kersten and Ken Sueda
- */
-public class CreateBugzillaQueryCategoryAction extends Action {
-
- public static final String ID = "org.eclipse.mylar.tasks.actions.create.bug.query";
-
- private final TaskListView view;
-
- public CreateBugzillaQueryCategoryAction(TaskListView view) {
- this.view = view;
- setText("Add Bugzilla Query");
- setToolTipText("Add Bugzilla Query");
- setId(ID);
- setImageDescriptor(MylarImages.CATEGORY_QUERY_NEW);
- }
-
- @Override
- public void run() {
-
- // ask the user for the query string and a name
- MylarPlugin.getDefault().actionObserved(this);
- BugzillaQueryDialog sqd = new BugzillaQueryDialog(Display.getCurrent().getActiveShell());
- if(sqd.open() == Dialog.OK){
- final BugzillaQueryCategory queryCategory = new BugzillaQueryCategory(sqd.getName(), sqd.getUrl());
-
- MylarTasksPlugin.getTaskListManager().getTaskList().addCategory(queryCategory);
- WorkspaceModifyOperation op = new WorkspaceModifyOperation() {
- protected void execute(IProgressMonitor monitor) throws CoreException {
- queryCategory.refreshBugs();
- }
- };
-
- IProgressService service = PlatformUI.getWorkbench().getProgressService();
- try {
- service.run(true, true, op);
- } catch (Exception e) {
- MylarPlugin.log(e, "There was a problem executing the query refresh");
- }
- this.view.getViewer().refresh();
- }
- }
-} \ No newline at end of file
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/CreateBugzillaTaskAction.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/CreateBugzillaTaskAction.java
deleted file mode 100644
index 8005d4a1c..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/CreateBugzillaTaskAction.java
+++ /dev/null
@@ -1,77 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.mylar.tasks.ui.actions;
-
-import org.eclipse.jface.action.Action;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.mylar.core.MylarPlugin;
-import org.eclipse.mylar.tasks.BugzillaTask;
-import org.eclipse.mylar.tasks.ITask;
-import org.eclipse.mylar.tasks.MylarTasksPlugin;
-import org.eclipse.mylar.tasks.TaskCategory;
-import org.eclipse.mylar.tasks.ui.views.TaskListView;
-import org.eclipse.mylar.ui.MylarImages;
-
-/**
- * @author Mik Kersten and Ken Sueda
- */
-public class CreateBugzillaTaskAction extends Action {
-
- public static final String ID = "org.eclipse.mylar.tasks.actions.create.bug";
-
- private final TaskListView view;
-
- public CreateBugzillaTaskAction(TaskListView view) {
- this.view = view;
- setText("Add Bugzilla Report");
- setToolTipText("Add Bugzilla Report");
- setId(ID);
- setImageDescriptor(MylarImages.TASK_BUGZILLA_NEW);
- }
-
- @Override
- public void run() {
- MylarPlugin.getDefault().actionObserved(this);
- String bugIdString = this.view.getBugIdFromUser();
- int bugId = -1;
- try {
- if (bugIdString != null) {
- bugId = Integer.parseInt(bugIdString);
- } else {
- return;
- }
- } catch (NumberFormatException nfe) {
- this.view.showMessage("Please enter a valid report number");
- return;
- }
-
- // XXX we don't care about duplicates since we use a registrey
- // Check the existing tasks to see if the id is used already.
- // This is to prevent the creation of mutliple Bugzilla tasks
- // for the same Bugzilla report.
-// boolean doesIdExistAlready = false;
-// doesIdExistAlready = lookForId("Bugzilla-" + bugId);
-// if (doesIdExistAlready) {
-// showMessage("A Bugzilla task with ID Bugzilla-" + bugId + " already exists.");
-// return;
-// }
-
- ITask newTask = new BugzillaTask("Bugzilla-"+bugId, "<bugzilla info>");
- Object selectedObject = ((IStructuredSelection)this.view.getViewer().getSelection()).getFirstElement();
- if (selectedObject instanceof TaskCategory){
- ((TaskCategory)selectedObject).addTask(newTask);
- } else {
- MylarTasksPlugin.getTaskListManager().getTaskList().addRootTask(newTask);
- }
- this.view.getViewer().refresh();
- }
-} \ No newline at end of file
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/CreateCategoryAction.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/CreateCategoryAction.java
deleted file mode 100644
index 7c56fe2f1..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/CreateCategoryAction.java
+++ /dev/null
@@ -1,47 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.mylar.tasks.ui.actions;
-
-import org.eclipse.jface.action.Action;
-import org.eclipse.mylar.core.MylarPlugin;
-import org.eclipse.mylar.tasks.MylarTasksPlugin;
-import org.eclipse.mylar.tasks.TaskCategory;
-import org.eclipse.mylar.tasks.ui.views.TaskListView;
-import org.eclipse.mylar.ui.MylarImages;
-
-/**
- * @author Mik Kersten and Ken Sueda
- */
-public class CreateCategoryAction extends Action {
-
- public static final String ID = "org.eclipse.mylar.tasks.actions.create.category";
-
- private final TaskListView view;
-
- public CreateCategoryAction(TaskListView view) {
- this.view = view;
- setText("Add Category");
- setToolTipText("Add Category");
- setId(ID);
- setImageDescriptor(MylarImages.CATEGORY_NEW);
- }
-
- @Override
- public void run() {
- MylarPlugin.getDefault().actionObserved(this);
- String label = this.view.getLabelNameFromUser("Category");
- if(label == null) return;
- TaskCategory cat = new TaskCategory(label);
- MylarTasksPlugin.getTaskListManager().getTaskList().addCategory(cat);
- this.view.getViewer().refresh();
- }
-} \ No newline at end of file
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/CreateTaskAction.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/CreateTaskAction.java
deleted file mode 100644
index eb849dcbd..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/CreateTaskAction.java
+++ /dev/null
@@ -1,66 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.mylar.tasks.ui.actions;
-
-import org.eclipse.jface.action.Action;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.mylar.core.MylarPlugin;
-import org.eclipse.mylar.tasks.MylarTasksPlugin;
-import org.eclipse.mylar.tasks.Task;
-import org.eclipse.mylar.tasks.TaskCategory;
-import org.eclipse.mylar.tasks.ui.views.TaskListView;
-import org.eclipse.mylar.ui.MylarImages;
-import org.eclipse.mylar.ui.MylarUiPlugin;
-
-/**
- * @author Mik Kersten and Ken Sueda
- */
-public class CreateTaskAction extends Action {
-
- public static final String ID = "org.eclipse.mylar.tasks.actions.create.task";
-
- private final TaskListView view;
-
- public CreateTaskAction(TaskListView view) {
- this.view = view;
- setText("Add Task");
- setToolTipText("Add Task");
- setId(ID);
- setImageDescriptor(MylarImages.TASK_NEW);
- }
-
- @Override
- public void run() {
- MylarPlugin.getDefault().actionObserved(this);
- String label = this.view.getLabelNameFromUser("task");
- if(label == null) return;
- Task newTask = new Task(MylarTasksPlugin.getTaskListManager().genUniqueTaskId(), label);
-
- Object selectedObject = ((IStructuredSelection)this.view.getViewer().getSelection()).getFirstElement();
- if (selectedObject instanceof TaskCategory){
- newTask.setCategory((TaskCategory)selectedObject);
- ((TaskCategory)selectedObject).addTask(newTask);
- }
-// else if (selectedObject instanceof Task) {
-// ITask t = (ITask) selectedObject;
-// newTask.setParent(t);
-// t.addSubTask(newTask);
-// }
- else {
- MylarTasksPlugin.getTaskListManager().getTaskList().addRootTask(newTask);
- }
- MylarUiPlugin.getDefault().setHighlighterMapping(
- newTask.getHandle(),
- MylarUiPlugin.getDefault().getDefaultHighlighter().getName());
- this.view.getViewer().refresh();
- }
-} \ No newline at end of file
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/DeleteAction.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/DeleteAction.java
deleted file mode 100644
index 56248b78e..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/DeleteAction.java
+++ /dev/null
@@ -1,89 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.mylar.tasks.ui.actions;
-
-import org.eclipse.jface.action.Action;
-import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.mylar.core.MylarPlugin;
-import org.eclipse.mylar.tasks.BugzillaQueryCategory;
-import org.eclipse.mylar.tasks.ITask;
-import org.eclipse.mylar.tasks.MylarTasksPlugin;
-import org.eclipse.mylar.tasks.Task;
-import org.eclipse.mylar.tasks.TaskCategory;
-import org.eclipse.mylar.tasks.ui.views.TaskListView;
-import org.eclipse.mylar.ui.MylarImages;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.internal.Workbench;
-
-/**
- * @author Mik Kersten and Ken Sueda
- */
-public class DeleteAction extends Action {
-
- public static final String ID = "org.eclipse.mylar.tasks.actions.delete";
-
- private final TaskListView view;
-
- public DeleteAction(TaskListView view) {
- this.view = view;
- setText("Delete");
- setId(ID);
- setImageDescriptor(MylarImages.REMOVE);
- }
-
- @Override
- public void run() {
- MylarPlugin.getDefault().actionObserved(this);
- boolean deleteConfirmed = MessageDialog.openQuestion(
- Workbench.getInstance().getActiveWorkbenchWindow().getShell(),
- "Confirm delete",
- "Delete selected item?");
- if (!deleteConfirmed) {
- return;
- } else {
- Object selectedObject = ((IStructuredSelection)this.view.getViewer().getSelection()).getFirstElement();
- if (selectedObject instanceof Task) {
- MylarTasksPlugin.getTaskListManager().deleteTask((Task)selectedObject);
- MylarPlugin.getTaskscapeManager().taskDeleted(((Task)selectedObject).getHandle(), ((Task)selectedObject).getPath());
- IWorkbenchPage page = MylarTasksPlugin.getDefault().getWorkbench().getActiveWorkbenchWindow().getActivePage();
-
- // if we couldn't get the page, get out of here
- if (page == null)
- return;
- try{
- this.view.closeTaskEditors((ITask)selectedObject, page);
- }catch(Exception e){
- MylarPlugin.log(e, " deletion failed");
- }
- } else if (selectedObject instanceof TaskCategory) {
- TaskCategory cat = (TaskCategory) selectedObject;
- for (ITask task : cat.getChildren()) {
- MylarPlugin.getTaskscapeManager().taskDeleted(task.getHandle(), task.getPath());
- IWorkbenchPage page = MylarTasksPlugin.getDefault().getWorkbench().getActiveWorkbenchWindow().getActivePage();
- if (page == null)
- return;
- try{
- this.view.closeTaskEditors(task, page);
- }catch(Exception e){
- MylarPlugin.log(e, " deletion failed");
- }
- }
- MylarTasksPlugin.getTaskListManager().deleteCategory((TaskCategory)selectedObject);
- } else if (selectedObject instanceof BugzillaQueryCategory) {
- BugzillaQueryCategory cat = (BugzillaQueryCategory) selectedObject;
- MylarTasksPlugin.getTaskListManager().deleteCategory(cat);
- }
- }
- this.view.getViewer().refresh();
- }
-} \ No newline at end of file
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/FilterCompletedTasksAction.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/FilterCompletedTasksAction.java
deleted file mode 100644
index 598764552..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/FilterCompletedTasksAction.java
+++ /dev/null
@@ -1,50 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.mylar.tasks.ui.actions;
-
-import org.eclipse.jface.action.Action;
-import org.eclipse.mylar.core.MylarPlugin;
-import org.eclipse.mylar.tasks.MylarTasksPlugin;
-import org.eclipse.mylar.tasks.ui.views.TaskListView;
-import org.eclipse.mylar.ui.MylarImages;
-
-/**
- * @author Mik Kersten and Ken Sueda
- */
-public class FilterCompletedTasksAction extends Action {
-
- public static final String ID = "org.eclipse.mylar.tasks.actions.filter.completed";
-
- private final TaskListView view;
-
- public FilterCompletedTasksAction(TaskListView view) {
- this.view = view;
- setText("Filter Completed Tasks");
- setToolTipText("Filter Completed Tasks");
- setId(ID);
- setImageDescriptor(MylarImages.FILTER_COMPLETE);
- setChecked(MylarTasksPlugin.getDefault().isFilterCompleteMode());
- }
- @Override
- public void run() {
- MylarPlugin.getDefault().actionObserved(this);
- MylarTasksPlugin.getDefault().setFilterCompleteMode(isChecked());
- if (isChecked()) {
- this.view.getViewer().addFilter(this.view.getCompleteFilter());
-// filterInCompleteTask.setChecked(false);
-// viewer.removeFilter(inCompleteFilter);
- } else {
- this.view.getViewer().removeFilter(this.view.getCompleteFilter());
- }
- this.view.getViewer().refresh();
- }
-} \ No newline at end of file
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/MarkTaskCompleteAction.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/MarkTaskCompleteAction.java
deleted file mode 100644
index 19dc18e6d..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/MarkTaskCompleteAction.java
+++ /dev/null
@@ -1,47 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.mylar.tasks.ui.actions;
-
-import org.eclipse.jface.action.Action;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.mylar.core.MylarPlugin;
-import org.eclipse.mylar.tasks.Task;
-import org.eclipse.mylar.tasks.ui.views.TaskListView;
-import org.eclipse.mylar.ui.MylarImages;
-
-/**
- * @author Mik Kersten and Ken Sueda
- */
-public class MarkTaskCompleteAction extends Action {
-
- public static final String ID = "org.eclipse.mylar.tasks.actions.mark.completed";
-
- private final TaskListView view;
-
- public MarkTaskCompleteAction(TaskListView view) {
- this.view = view;
- setText("Mark Complete");
- setToolTipText("Mark Complete");
- setId(ID);
- setImageDescriptor(MylarImages.TASK_COMPLETE);
- }
- @Override
- public void run() {
- MylarPlugin.getDefault().actionObserved(this);
- Object selectedObject = ((IStructuredSelection)this.view.getViewer().getSelection()).getFirstElement();
- if (selectedObject instanceof Task){
- ((Task)selectedObject).setCompleted(true);
-
- }
- this.view.getViewer().refresh();
- }
-} \ No newline at end of file
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/MarkTaskIncompleteAction.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/MarkTaskIncompleteAction.java
deleted file mode 100644
index ac0562c54..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/MarkTaskIncompleteAction.java
+++ /dev/null
@@ -1,46 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.mylar.tasks.ui.actions;
-
-import org.eclipse.jface.action.Action;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.mylar.core.MylarPlugin;
-import org.eclipse.mylar.tasks.Task;
-import org.eclipse.mylar.tasks.ui.views.TaskListView;
-import org.eclipse.mylar.ui.MylarImages;
-
-/**
- * @author Mik Kersten and Ken Sueda
- */
-public class MarkTaskIncompleteAction extends Action {
-
- public static final String ID = "org.eclipse.mylar.tasks.actions.mark.incomplete";
-
- private final TaskListView view;
-
- public MarkTaskIncompleteAction(TaskListView view) {
- this.view = view;
- setText("Mark Incomplete");
- setToolTipText("Mark Incomplete");
- setId(ID);
- setImageDescriptor(MylarImages.TASK_INCOMPLETE);
- }
- @Override
- public void run() {
- MylarPlugin.getDefault().actionObserved(this);
- Object selectedObject = ((IStructuredSelection)this.view.getViewer().getSelection()).getFirstElement();
- if (selectedObject instanceof Task){
- ((Task)selectedObject).setCompleted(false);
- }
- this.view.getViewer().refresh();
- }
-} \ No newline at end of file
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/MoveTaskToRootAction.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/MoveTaskToRootAction.java
deleted file mode 100644
index cb49a7c8e..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/MoveTaskToRootAction.java
+++ /dev/null
@@ -1,57 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.mylar.tasks.ui.actions;
-
-import org.eclipse.jface.action.Action;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.mylar.tasks.ITask;
-import org.eclipse.mylar.tasks.MylarTasksPlugin;
-import org.eclipse.mylar.tasks.TaskCategory;
-import org.eclipse.mylar.tasks.ui.views.TaskListView;
-
-/**
- * @author Mik Kersten and Ken Sueda
- */
-public class MoveTaskToRootAction extends Action {
-
- public static final String ID = "org.eclipse.mylar.tasks.actions.move.toroot";
-
- private final TaskListView view;
- public MoveTaskToRootAction(TaskListView view) {
- this.view = view;
- setText("Move Task to Root");
- setToolTipText("Move Task to Root");
- setId(ID);
- }
- @Override
- public void run() {
- ISelection selection = this.view.getViewer().getSelection();
- Object obj = ((IStructuredSelection)selection).getFirstElement();
- if (obj instanceof ITask) {
- ITask t = (ITask) obj;
- TaskCategory cat = t.getCategory();
- if (cat != null) {
- cat.removeTask(t);
- t.setCategory(null);
- t.setParent(null);
- MylarTasksPlugin.getTaskListManager().getTaskList().addRootTask(t);
- this.view.getViewer().refresh();
- } else if (t.getParent() != null) {
- t.getParent().removeSubTask(t);
- t.setParent(null);
- MylarTasksPlugin.getTaskListManager().getTaskList().addRootTask(t);
- this.view.getViewer().refresh();
- }
- }
- }
-} \ No newline at end of file
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/OpenTaskEditorAction.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/OpenTaskEditorAction.java
deleted file mode 100644
index 1d891c504..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/OpenTaskEditorAction.java
+++ /dev/null
@@ -1,80 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.mylar.tasks.ui.actions;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.jface.action.Action;
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.mylar.bugzilla.ui.BugzillaOpenStructure;
-import org.eclipse.mylar.bugzilla.ui.ViewBugzillaAction;
-import org.eclipse.mylar.core.MylarPlugin;
-import org.eclipse.mylar.tasks.BugzillaHit;
-import org.eclipse.mylar.tasks.BugzillaQueryCategory;
-import org.eclipse.mylar.tasks.ITask;
-import org.eclipse.mylar.tasks.ui.views.BugzillaQueryDialog;
-import org.eclipse.mylar.tasks.ui.views.TaskListView;
-import org.eclipse.swt.widgets.Display;
-
-/**
- * @author Mik Kersten and Ken Sueda
- */
-public class OpenTaskEditorAction extends Action {
-
- public static final String ID = "org.eclipse.mylar.tasks.actions.open";
-
- private final TaskListView view;
-
- /**
- * @param view
- */
- public OpenTaskEditorAction(TaskListView view) {
- this.view = view;
- setId(ID);
- }
-
- @Override
- public void run() {
- MylarPlugin.getDefault().actionObserved(this);
- ISelection selection = this.view.getViewer().getSelection();
- Object obj = ((IStructuredSelection)selection).getFirstElement();
- if (obj instanceof ITask) {
- ((ITask)obj).openTaskInEditor();
- } else if (obj instanceof BugzillaQueryCategory){
-
- BugzillaQueryDialog sqd = new BugzillaQueryDialog(Display.getCurrent().getActiveShell());
- if(sqd.open() == Dialog.OK){
- BugzillaQueryCategory queryCategory = (BugzillaQueryCategory)obj;
- queryCategory.setDescription(sqd.getName());
- queryCategory.setUrl(sqd.getUrl());
-
- queryCategory.refreshBugs();
- this.view.getViewer().refresh();
- }
- } else if(obj instanceof BugzillaHit){
- BugzillaHit hit = (BugzillaHit)obj;
- if(hit.isTask()){
- hit.getAssociatedTask().openTaskInEditor();
- } else {
- BugzillaOpenStructure open = new BugzillaOpenStructure(((BugzillaHit)obj).getServerName(), ((BugzillaHit)obj).getID(),-1);
- List<BugzillaOpenStructure> selectedBugs = new ArrayList<BugzillaOpenStructure>();
- selectedBugs.add(open);
- ViewBugzillaAction viewBugs = new ViewBugzillaAction("Display bugs in editor", selectedBugs);
- viewBugs.schedule();
- }
- }
- this.view.getViewer().refresh(obj);
- }
-} \ No newline at end of file
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/RefreshBugzillaReportsAction.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/RefreshBugzillaReportsAction.java
deleted file mode 100644
index 794519baf..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/RefreshBugzillaReportsAction.java
+++ /dev/null
@@ -1,127 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.mylar.tasks.ui.actions;
-
-import java.lang.reflect.InvocationTargetException;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Set;
-
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.jface.action.Action;
-import org.eclipse.mylar.bugzilla.core.BugReport;
-import org.eclipse.mylar.bugzilla.core.BugzillaRepository;
-import org.eclipse.mylar.core.MylarPlugin;
-import org.eclipse.mylar.tasks.AbstractCategory;
-import org.eclipse.mylar.tasks.BugzillaQueryCategory;
-import org.eclipse.mylar.tasks.BugzillaTask;
-import org.eclipse.mylar.tasks.ITask;
-import org.eclipse.mylar.tasks.MylarTasksPlugin;
-import org.eclipse.mylar.tasks.TaskCategory;
-import org.eclipse.mylar.tasks.bugzilla.BugzillaStructureBridge;
-import org.eclipse.mylar.tasks.ui.views.TaskListView;
-import org.eclipse.mylar.ui.MylarImages;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.actions.WorkspaceModifyOperation;
-import org.eclipse.ui.progress.IProgressService;
-
-/**
- * @author Mik Kersten and Ken Sueda
- */
-public class RefreshBugzillaReportsAction extends Action {
-
- public static final String ID = "org.eclipse.mylar.tasks.actions.refresh.bugdb";
-
- private final TaskListView view;
-
- public RefreshBugzillaReportsAction(TaskListView view) {
- this.view = view;
- setText("Refresh Bugzilla reports");
- setToolTipText("Refresh Bugzilla reports");
- setId(ID);
- setImageDescriptor(MylarImages.TASK_BUG_REFRESH);
- }
-
- @Override
- public void run() {
- MylarPlugin.getDefault().actionObserved(this);
- // TODO background?
- // perform the update in an operation so that we get a progress monitor
- // update the structure bridge cache with the reference provider cached bugs
- WorkspaceModifyOperation op = new WorkspaceModifyOperation() {
- protected void execute(IProgressMonitor monitor) throws CoreException {
-
- List<ITask> tasks = MylarTasksPlugin.getTaskListManager().getTaskList().getRootTasks();
-
- for (ITask task : tasks) {
- if (task instanceof BugzillaTask) {
- ((BugzillaTask)task).refresh();
- }
- }
- for (AbstractCategory cat : MylarTasksPlugin.getTaskListManager().getTaskList().getCategories()) {
- if (cat instanceof TaskCategory) {
- for (ITask task : ((TaskCategory)cat).getChildren()) {
- if (task instanceof BugzillaTask) {
- ((BugzillaTask)task).refresh();
- }
- }
- RefreshBugzillaReportsAction.this.view.refreshChildren(((TaskCategory)cat).getChildren());
- }
- else if (cat instanceof BugzillaQueryCategory) {
- final BugzillaQueryCategory bqc = (BugzillaQueryCategory) cat;
- PlatformUI.getWorkbench().getDisplay().syncExec(new Runnable() {
-
- public void run() {
- bqc.refreshBugs();
- RefreshBugzillaReportsAction.this.view.getViewer().refresh();
- }
- });
- }
- }
-
- // clear the caches
- Set<String> cachedHandles = new HashSet<String>();
- cachedHandles.addAll(MylarTasksPlugin.getDefault().getStructureBridge().getCachedHandles());
- cachedHandles.addAll(MylarTasksPlugin.getReferenceProvider().getCachedHandles());
- MylarTasksPlugin.getDefault().getStructureBridge().clearCache();
- MylarTasksPlugin.getReferenceProvider().clearCachedReports();
-
- BugzillaStructureBridge bridge = MylarTasksPlugin.getDefault().getStructureBridge();
- monitor.beginTask("Downloading Bugs" , cachedHandles.size());
- for(String key: cachedHandles){
- try {
- String [] parts = key.split(";");
- final int id = Integer.parseInt(parts[1]);
- BugReport bug = BugzillaRepository.getInstance().getCurrentBug(id);
- if(bug != null)
- bridge.cache(key, bug);
- }catch(Exception e){}
-
- monitor.worked(1);
- }
- monitor.done();
- RefreshBugzillaReportsAction.this.view.getViewer().refresh();
- }
- };
-
- // Use the progess service to execute the runnable
- IProgressService service = PlatformUI.getWorkbench().getProgressService();
- try {
- service.run(true, false, op);
- } catch (InvocationTargetException e) {
- // Operation was canceled
- } catch (InterruptedException e) {
- // Handle the wrapped exception
- }
- }
-} \ No newline at end of file
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/TaskActivateAction.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/TaskActivateAction.java
deleted file mode 100644
index 2de5f7c82..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/TaskActivateAction.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.mylar.tasks.ui.actions;
-
-import org.eclipse.jface.action.Action;
-import org.eclipse.mylar.core.MylarPlugin;
-import org.eclipse.mylar.tasks.ITask;
-import org.eclipse.mylar.tasks.MylarTasksPlugin;
-
-/**
- * @author Mik Kersten and Ken Sueda
- */
-public class TaskActivateAction extends Action {
-
- public static final String ID = "org.eclipse.mylar.tasks.actions.context.activate";
-
- private ITask task;
-
- public TaskActivateAction(ITask task) {
- this.task = task;
- setId(ID);
- }
-
- public void run() {
- MylarPlugin.getDefault().actionObserved(this);
- MylarTasksPlugin.getTaskListManager().activateTask(task);
- }
-} \ No newline at end of file
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/TaskDeactivateAction.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/TaskDeactivateAction.java
deleted file mode 100644
index 6d1c4e021..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/TaskDeactivateAction.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.mylar.tasks.ui.actions;
-
-import org.eclipse.jface.action.Action;
-import org.eclipse.mylar.core.MylarPlugin;
-import org.eclipse.mylar.tasks.ITask;
-import org.eclipse.mylar.tasks.MylarTasksPlugin;
-
-/**
- * @author Mik Kersten and Ken Sueda
- */
-public class TaskDeactivateAction extends Action {
-
- public static final String ID = "org.eclipse.mylar.tasks.actions.context.deactivate";
-
- private ITask task;
-
- public TaskDeactivateAction(ITask task) {
- this.task = task;
- setId(ID);
- }
-
- public void run() {
- MylarPlugin.getDefault().actionObserved(this);
- MylarTasksPlugin.getTaskListManager().deactivateTask(task);
- }
-} \ No newline at end of file
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/ToggleIntersectionModeAction.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/ToggleIntersectionModeAction.java
deleted file mode 100644
index f80225f4d..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/actions/ToggleIntersectionModeAction.java
+++ /dev/null
@@ -1,42 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on May 11, 2005
- */
-package org.eclipse.mylar.tasks.ui.actions;
-
-import org.eclipse.jface.action.Action;
-import org.eclipse.mylar.core.ITaskscapeListener;
-import org.eclipse.mylar.core.MylarPlugin;
-import org.eclipse.mylar.ui.MylarImages;
-import org.eclipse.mylar.ui.MylarUiPlugin;
-
-/**
- * @author Mik Kersten
- */
-public class ToggleIntersectionModeAction extends Action {
-
- public ToggleIntersectionModeAction() {
- super();
- setText("Intersect Tasskscapes");
- setToolTipText("Intersect Taskscapes");
- setImageDescriptor(MylarImages.MYLAR);
- setActionDefinitionId("org.eclipse.mylar.ui.interest.intersection");
- setChecked(MylarUiPlugin.getDefault().isGlobalFilteringEnabled());
- }
-
- @Override
- public void run() {
- setChecked(!isChecked());
- MylarUiPlugin.getDefault().setIntersectionMode(isChecked());
- MylarPlugin.getTaskscapeManager().notifyActivePresentationSettingsChange(ITaskscapeListener.UpdateKind.HIGHLIGHTER);
- }
-}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/views/BugzillaQueryDialog.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/views/BugzillaQueryDialog.java
deleted file mode 100644
index 3ce476e95..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/views/BugzillaQueryDialog.java
+++ /dev/null
@@ -1,225 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-package org.eclipse.mylar.tasks.ui.views;
-
-import java.io.UnsupportedEncodingException;
-
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.dialogs.IDialogConstants;
-import org.eclipse.jface.dialogs.IInputValidator;
-import org.eclipse.jface.dialogs.InputDialog;
-import org.eclipse.jface.operation.IRunnableContext;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.mylar.bugzilla.saveQuery.GetQueryDialog;
-import org.eclipse.mylar.bugzilla.saveQuery.SaveQueryDialog;
-import org.eclipse.mylar.bugzilla.search.BugzillaSearchPage;
-import org.eclipse.search.ui.ISearchPageContainer;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Group;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.ui.IWorkingSet;
-
-/**
- * @author Shawn Minto
- */
-public class BugzillaQueryDialog extends Dialog {
-
- private String url;
- private String name;
- private BugzillaSearchOptionPage searchOptionPage;
-
- public BugzillaQueryDialog(Shell parentShell) {
- super(parentShell);
- searchOptionPage = new BugzillaSearchOptionPage();
-
- }
-
- public String getName() {
- return name;
- }
-
- public String getUrl() {
- return url;
- }
-
- @Override
- protected Control createContents(Composite parent) {
- searchOptionPage.createControl(parent);
- searchOptionPage.setVisible(true); // called to initialize the values
- return super.createContents(parent);
- }
-
- @Override
- protected void okPressed(){
- url = searchOptionPage.getSearchURL();
- if(url == null || url.equals("")){
- /*
- * Should never get here. Every implementation of the Java platform is required
- * to support the standard charset "UTF-8"
- */
- return;
- }
- InputDialog getNameDialog = new InputDialog(Display.getCurrent().getActiveShell(), "Bugzilla Query Category Name", "Please enter a name for the bugzilla query category","", new IInputValidator(){
-
- public String isValid(String newText) {
- if(newText != null && !newText.equals("")){
- return null;
- } else {
- return "You must enter a name for the category";
- }
- }
-
- });
- getNameDialog.setBlockOnOpen(true);
- if(getNameDialog.open() == InputDialog.OK){
- name = getNameDialog.getValue();
-
- super.okPressed();
- } else {
- super.cancelPressed();
- }
- }
-
- private class BugzillaSearchOptionPage extends BugzillaSearchPage{
-
- public BugzillaSearchOptionPage(){
- scontainer = new ISearchPageContainer(){
- public ISelection getSelection() {
- // TODO Auto-generated method stub
- return null;
- }
-
- public IRunnableContext getRunnableContext() {
- return null;
- }
-
- public void setPerformActionEnabled(boolean state) {
- Button ok = BugzillaQueryDialog.this.getButton(Dialog.OK);
- if(ok != null)
- ok.setEnabled(state);
- }
-
- public int getSelectedScope() {
- return 0;
- }
-
- public void setSelectedScope(int scope) {}
-
- public boolean hasValidScope() {
- return true;
- }
-
- public IWorkingSet[] getSelectedWorkingSets() {
- return null;
- }
-
- public void setSelectedWorkingSets(IWorkingSet[] workingSets) {}
- };
- }
-
- public String getSearchURL() {
- try{
- if(rememberedQuery){
- return getQueryURL(new StringBuffer(input.getQueryParameters(selIndex)));
- } else {
- return getQueryURL(getQueryParameters());
- }
- } catch (UnsupportedEncodingException e){
- /*
- * Do nothing. Every implementation of the Java platform is required
- * to support the standard charset "UTF-8"
- */
- }
- return "";
- }
-
- @Override
- protected Control createSaveQuery(Composite control) {
- GridLayout layout;
- GridData gd;
-
- Group group = new Group(control, SWT.NONE);
- layout = new GridLayout(3, false);
- group.setLayout(layout);
- group.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
- gd = new GridData(GridData.BEGINNING | GridData.FILL_HORIZONTAL | GridData.GRAB_HORIZONTAL);
- gd.horizontalSpan = 2;
- group.setLayoutData(gd);
-
- loadButton = new Button(group, SWT.PUSH | SWT.LEFT);
- loadButton.setText("Saved Queries...");
- loadButton.addSelectionListener(new SelectionAdapter() {
-
- @Override
- public void widgetSelected(SelectionEvent event) {
- GetQueryDialog qd = new GetQueryDialog(getShell(),
- "Saved Queries", input){
- @Override
- protected void createButtonsForButtonBar(Composite parent) {
- super.createButtonsForButtonBar(parent);
- Button okButton = super.getButton(IDialogConstants.OK_ID);
- if(okButton != null)
- okButton.setText("Select");
- }
- };
-
- if (qd.open() == InputDialog.OK) {
- selIndex = qd.getSelected();
- if (selIndex != -1) {
- rememberedQuery = true;
- }
- } else {
- rememberedQuery = false;
- }
- }
- });
- loadButton.setEnabled(true);
- loadButton.setLayoutData(new GridData(GridData.HORIZONTAL_ALIGN_BEGINNING));
-
- saveButton = new Button(group, SWT.PUSH | SWT.LEFT);
- saveButton.setText("Remember...");
- saveButton.addSelectionListener(new SelectionAdapter() {
-
- @Override
- public void widgetSelected(SelectionEvent event) {
- SaveQueryDialog qd = new SaveQueryDialog(getShell(),
- "Remember Query");
- if (qd.open() == InputDialog.OK) {
- String qName = qd.getText();
- if (qName != null && qName.compareTo("") != 0) {
- try {
- input.add(getQueryParameters().toString(), qName, summaryPattern.getText());
- }
- catch (UnsupportedEncodingException e) {
- /*
- * Do nothing. Every implementation of the Java platform is required
- * to support the standard charset "UTF-8"
- */
- }
- }
- }
- }
- });
- saveButton.setEnabled(true);
- saveButton.setLayoutData(new GridData(GridData.HORIZONTAL_ALIGN_BEGINNING));
-
- return group;
- }
- }
-}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/views/TaskListLabelProvider.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/views/TaskListLabelProvider.java
deleted file mode 100644
index c3af29a34..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/views/TaskListLabelProvider.java
+++ /dev/null
@@ -1,235 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on Feb 18, 2005
- */
-package org.eclipse.mylar.tasks.ui.views;
-
-import org.eclipse.jface.viewers.IColorProvider;
-import org.eclipse.jface.viewers.IFontProvider;
-import org.eclipse.jface.viewers.ITableLabelProvider;
-import org.eclipse.jface.viewers.LabelProvider;
-import org.eclipse.mylar.tasks.AbstractCategory;
-import org.eclipse.mylar.tasks.BugzillaHit;
-import org.eclipse.mylar.tasks.BugzillaQueryCategory;
-import org.eclipse.mylar.tasks.BugzillaTask;
-import org.eclipse.mylar.tasks.ITask;
-import org.eclipse.mylar.tasks.ITaskListElement;
-import org.eclipse.mylar.tasks.TaskCategory;
-import org.eclipse.mylar.ui.MylarUiPlugin;
-import org.eclipse.mylar.ui.internal.UiUtil;
-import org.eclipse.mylar.ui.internal.views.Highlighter;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.Font;
-import org.eclipse.swt.graphics.Image;
-
-/**
- * @author Mik Kersten
- */
-public class TaskListLabelProvider extends LabelProvider implements ITableLabelProvider, IColorProvider, IFontProvider {
-
- private Color backgroundColor = null;
-
- public String getColumnText(Object obj, int columnIndex) {
- if (obj instanceof ITaskListElement) {
- ITaskListElement element = (ITaskListElement) obj;
- switch (columnIndex) {
- case 0:
- return "";
- case 1:
- return "";
- case 2:
- return element.getPriority();
- case 3:
- return element.getDescription(true);
- case 4:
- return element.getHandle();
- }
- }
- System.out.println("Not TaskListElement");
- return "";
- }
-
- public Font getFont(Object element) {
- if (element instanceof ITask) {
- ITask task = (ITask)element;
- if (task.isActive()) return UiUtil.BOLD;
- if (task.isCompleted()) return UiUtil.ITALIC;
- for (ITask child : task.getChildren()) {
- if (child.isActive())
- return UiUtil.BOLD;
- }
- } else if (element instanceof TaskCategory) {
- TaskCategory cat = (TaskCategory) element;
- for (ITask child : cat.getChildren()) {
- if (child.isActive())
- return UiUtil.BOLD;
- }
- }else if (element instanceof BugzillaHit) {
- BugzillaHit hit = (BugzillaHit)element;
- BugzillaTask task = hit.getAssociatedTask();
- if(task != null){
- if (task.isActive()) return UiUtil.BOLD;
- if (task.isCompleted()) return UiUtil.ITALIC;
- }
- } else if (element instanceof BugzillaQueryCategory) {
- BugzillaQueryCategory cat = (BugzillaQueryCategory) element;
- for (ITaskListElement child : cat.getHits()) {
- if (child instanceof BugzillaHit){
- BugzillaHit hit = (BugzillaHit) child;
- BugzillaTask task = hit.getAssociatedTask();
- if(task != null && task.isActive()){
- return UiUtil.BOLD;
- }
- }
- }
- }
- return null;
- }
-
- public Image getColumnImage(Object element, int columnIndex) {
-
- if (! (element instanceof ITaskListElement)) {
- return null;
- }
- if (columnIndex == 0) {
- return ((ITaskListElement)element).getStatusIcon();
- } else if (columnIndex == 1) {
- return ((ITaskListElement)element).getIcon();
- } else {
- return null;
- }
- }
-
- public Color getBackground(Object element) {
- if (element instanceof ITask) {
- ITask task = (ITask)element;
- Highlighter highlighter = MylarUiPlugin.getDefault().getHighlighterForTaskId("" + task.getHandle());
- if (highlighter != null) return highlighter.getHighlightColor();
- } else if (element instanceof BugzillaHit) {
- BugzillaHit hit = (BugzillaHit)element;
- BugzillaTask task = hit.getAssociatedTask();
- if(task != null){
- Highlighter highlighter = MylarUiPlugin.getDefault().getHighlighterForTaskId("" + task.getHandle());
- if (highlighter != null) return highlighter.getHighlightColor();
- }
- }else if (element instanceof AbstractCategory) {
- return backgroundColor;
- }
- return null;
- }
-
- public Color getForeground(Object element) {
- if (element instanceof ITask) {
- ITask task = (ITask)element;
- if (task.isCompleted()) return MylarUiPlugin.getDefault().getColorMap().GRAY_VERY_LIGHT;
- } else if (element instanceof BugzillaHit) {
- BugzillaHit hit = (BugzillaHit)element;
- BugzillaTask task = hit.getAssociatedTask();
- if (task != null && task.isCompleted()) return MylarUiPlugin.getDefault().getColorMap().GRAY_VERY_LIGHT;
- }
- return null;
- }
-
- public void setBackgroundColor(Color c) {
- this.backgroundColor = c;
- }
-}
-
-//public Image getColumnImage(Object obj, int columnIndex) {
-//if (obj instanceof Highlighter) {
-// Highlighter h = (Highlighter) obj;
-// switch (columnIndex) {
-// case 1:
-// HighlighterImageDescriptor des;
-// if (h.isGradient()) {
-// des = new HighlighterImageDescriptor(h.getBase(), h
-// .getLandmarkColor());
-// } else {
-// des = new HighlighterImageDescriptor(h
-// .getLandmarkColor(), h.getLandmarkColor());
-// }
-// return des.getImage();
-// default:
-// break;
-// }
-// }
-// return null;
-//}
-
-//public Color getBackground(Object element) {
-//if (element instanceof Task) {
-// Task task = (Task)element;
-// if (task.isActive()) {
-// Highlighter highlighter = MylarUiPlugin.getDefault().getHighlighterForTaskId(((Task)task).getId());
-// if (highlighter != null) {
-// return highlighter.getHighlightColor();
-// } else {
-// return null;
-// }
-// }
-//}
-//return null;
-//}
-
-//public class TaskListLabelProvider extends LabelProvider implements IColorProvider, IFontProvider {
-//
-// public String getText(Object obj) {
-// if (obj instanceof BugzillaTask) {
-// String desc = MylarTasksPlugin.getDefault().getBugzillaProvider().getBugzillaDescription(
-// ((BugzillaTask)obj));
-// return desc;
-// } else if (obj instanceof Task) {
-// Task task = (Task)obj;
-// return task.toString();// + " [" + task.getId() + "]";
-// } else {
-// return obj.toString();
-// }
-// }
-//
-// public Image getImage(Object obj) {
-// String imageKey = ISharedImages.IMG_OBJ_ELEMENT;
-// if (obj instanceof BugzillaTask) {
-// return MylarImages.getImage(MylarImages.TASK_BUGZILLA);
-// } else if (obj instanceof Task) {
-// return MylarImages.getImage(MylarImages.TASK);
-// } else {
-// return null;
-// }
-// }
-// public Color getForeground(Object element) {
-// return null;
-// }
-//
-// public Color getBackground(Object element) {
-// if (element instanceof Task) {
-// Task task = (Task)element;
-// if (task.isActive()) {
-// Highlighter highlighter = MylarUiPlugin.getDefault().getHighlighterForTaskId(((Task)task).getId());
-// if (highlighter != null) {
-// return highlighter.getHighlightColor();
-// } else {
-// return null;
-// }
-// }
-// }
-// return null;
-// }
-//
-// public Font getFont(Object element) {
-// if (element instanceof Task) {
-// if (((Task)element).isActive()) {
-// return UiUtil.BOLD;
-// }
-// }
-// return null;
-// }
-//} \ No newline at end of file
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/views/TaskListView.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/views/TaskListView.java
deleted file mode 100644
index 02b0857f6..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/views/TaskListView.java
+++ /dev/null
@@ -1,1307 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.mylar.tasks.ui.views;
-
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Iterator;
-import java.util.List;
-
-import javax.security.auth.login.LoginException;
-
-import org.eclipse.jface.action.Action;
-import org.eclipse.jface.action.ActionContributionItem;
-import org.eclipse.jface.action.IMenuCreator;
-import org.eclipse.jface.action.IMenuListener;
-import org.eclipse.jface.action.IMenuManager;
-import org.eclipse.jface.action.IToolBarManager;
-import org.eclipse.jface.action.MenuManager;
-import org.eclipse.jface.action.Separator;
-import org.eclipse.jface.dialogs.InputDialog;
-import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.jface.viewers.CellEditor;
-import org.eclipse.jface.viewers.CheckboxCellEditor;
-import org.eclipse.jface.viewers.ComboBoxCellEditor;
-import org.eclipse.jface.viewers.DoubleClickEvent;
-import org.eclipse.jface.viewers.ICellModifier;
-import org.eclipse.jface.viewers.IDoubleClickListener;
-import org.eclipse.jface.viewers.IStructuredContentProvider;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.ITreeContentProvider;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.viewers.TextCellEditor;
-import org.eclipse.jface.viewers.TreeViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerDropAdapter;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.jface.viewers.ViewerSorter;
-import org.eclipse.jface.window.Window;
-import org.eclipse.mylar.core.ITaskscapeListener;
-import org.eclipse.mylar.core.MylarPlugin;
-import org.eclipse.mylar.dt.MylarWebRef;
-import org.eclipse.mylar.tasks.AbstractCategory;
-import org.eclipse.mylar.tasks.BugzillaHit;
-import org.eclipse.mylar.tasks.BugzillaQueryCategory;
-import org.eclipse.mylar.tasks.BugzillaTask;
-import org.eclipse.mylar.tasks.ITask;
-import org.eclipse.mylar.tasks.ITaskListElement;
-import org.eclipse.mylar.tasks.MylarTasksPlugin;
-import org.eclipse.mylar.tasks.Task;
-import org.eclipse.mylar.tasks.TaskCategory;
-import org.eclipse.mylar.tasks.MylarTasksPlugin.Priority_Level;
-import org.eclipse.mylar.tasks.ui.BugzillaTaskEditorInput;
-import org.eclipse.mylar.tasks.ui.TaskEditorInput;
-import org.eclipse.mylar.tasks.ui.actions.ClearContextAction;
-import org.eclipse.mylar.tasks.ui.actions.CreateBugzillaQueryCategoryAction;
-import org.eclipse.mylar.tasks.ui.actions.CreateBugzillaTaskAction;
-import org.eclipse.mylar.tasks.ui.actions.CreateCategoryAction;
-import org.eclipse.mylar.tasks.ui.actions.CreateTaskAction;
-import org.eclipse.mylar.tasks.ui.actions.DeleteAction;
-import org.eclipse.mylar.tasks.ui.actions.FilterCompletedTasksAction;
-import org.eclipse.mylar.tasks.ui.actions.MarkTaskCompleteAction;
-import org.eclipse.mylar.tasks.ui.actions.MarkTaskIncompleteAction;
-import org.eclipse.mylar.tasks.ui.actions.MoveTaskToRootAction;
-import org.eclipse.mylar.tasks.ui.actions.OpenTaskEditorAction;
-import org.eclipse.mylar.tasks.ui.actions.RefreshBugzillaReportsAction;
-import org.eclipse.mylar.tasks.ui.actions.TaskActivateAction;
-import org.eclipse.mylar.tasks.ui.actions.TaskDeactivateAction;
-import org.eclipse.mylar.ui.MylarImages;
-import org.eclipse.mylar.ui.MylarUiPlugin;
-import org.eclipse.mylar.ui.internal.views.Highlighter;
-import org.eclipse.mylar.ui.internal.views.HighlighterImageDescriptor;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.dnd.DND;
-import org.eclipse.swt.dnd.DragSourceEvent;
-import org.eclipse.swt.dnd.DragSourceListener;
-import org.eclipse.swt.dnd.TextTransfer;
-import org.eclipse.swt.dnd.Transfer;
-import org.eclipse.swt.dnd.TransferData;
-import org.eclipse.swt.events.ControlEvent;
-import org.eclipse.swt.events.ControlListener;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Menu;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.swt.widgets.TreeColumn;
-import org.eclipse.swt.widgets.TreeItem;
-import org.eclipse.ui.IActionBars;
-import org.eclipse.ui.IEditorInput;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.IMemento;
-import org.eclipse.ui.IViewSite;
-import org.eclipse.ui.IWorkbenchActionConstants;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.internal.Workbench;
-import org.eclipse.ui.part.DrillDownAdapter;
-import org.eclipse.ui.part.ViewPart;
-
-/**
- * @author Mik Kersten
- */
-public class TaskListView extends ViewPart {
-
- private static TaskListView INSTANCE;
-
- TreeViewer viewer;
- private DrillDownAdapter drillDownAdapter;
-
- private RefreshBugzillaReportsAction refresh;
- private CreateTaskAction createTask;
- private CreateCategoryAction createCategory;
- private CreateBugzillaQueryCategoryAction createBugzillaQueryCategory;
- private CreateBugzillaTaskAction createBugzillaTask;
-// private RenameAction rename;
- private DeleteAction delete;
- private OpenTaskEditorAction doubleClickAction;
- private ClearContextAction clearSelectedTaskscapeAction;
-
- //private Action toggleIntersectionModeAction = new ToggleIntersectionModeAction();
-// private Action toggleFilteringAction = new ToggleGlobalInterestFilteringAction();
-
- private MarkTaskCompleteAction completeTask;
- private MarkTaskIncompleteAction incompleteTask;
- private FilterCompletedTasksAction filterCompleteTask;
-// private FilterIncompleteTasksAction filterInCompleteTask;
- private PriorityDropDownAction filterOnPriority;
- private Action moveTaskToRoot;
- private PriorityFilter priorityFilter = new PriorityFilter();
-
- protected String[] columnNames = new String[] { "", ".", "!", "Description", "handle" };
- protected int[] columnWidths = new int[] { 70, 20, 20, 120, 70 };
- private TreeColumn[] columns;
- private IMemento taskListMemento;
- public static final String columnWidthIdentifier = "org.eclipse.mylar.tasks.ui.views.tasklist.columnwidth";
- public static final String tableSortIdentifier = "org.eclipse.mylar.tasks.ui.views.tasklist.sortIndex";
- private int sortIndex = 2;
-
- private String[] PRIORITY_LEVELS = { "P1", "P2", "P3", "P4", "P5" };
-
- private final class PriorityDropDownAction extends Action implements IMenuCreator {
- private Menu dropDownMenu = null;
-
- public PriorityDropDownAction() {
- super();
- setText("Display Priorities");
- setToolTipText("Show Tasks with Priority Levels");
- setImageDescriptor(MylarImages.FILTER_PRIORITY);
- setMenuCreator(this);
- }
-
- public void dispose() {
- if (dropDownMenu != null) {
- dropDownMenu.dispose();
- dropDownMenu = null;
- }
- }
-
- public Menu getMenu(Control parent) {
- if (dropDownMenu != null) {
- dropDownMenu.dispose();
- }
- dropDownMenu = new Menu(parent);
- addActionsToMenu();
- return dropDownMenu;
- }
-
- public Menu getMenu(Menu parent) {
- if (dropDownMenu != null) {
- dropDownMenu.dispose();
- }
- dropDownMenu = new Menu(parent);
- addActionsToMenu();
- return dropDownMenu;
- }
-
- public void addActionsToMenu() {
- Action P1 = new Action(PRIORITY_LEVELS[0], AS_CHECK_BOX) {
- @Override
- public void run() {
- MylarTasksPlugin.setPriorityLevel(MylarTasksPlugin.Priority_Level.P1, isChecked());
- if (isChecked()) {
- priorityFilter.displayPriority(PRIORITY_LEVELS[0]);
- } else {
- priorityFilter.hidePriority(PRIORITY_LEVELS[0]);
- }
- viewer.refresh();
- }
- };
- P1.setEnabled(true);
- P1.setChecked(MylarTasksPlugin.getPriorityLevel(MylarTasksPlugin.Priority_Level.P1));
- P1.setToolTipText(PRIORITY_LEVELS[0]);
- ActionContributionItem item= new ActionContributionItem(P1);
- item.fill(dropDownMenu, -1);
-
- Action P2 = new Action(PRIORITY_LEVELS[1], AS_CHECK_BOX) {
- @Override
- public void run() {
- MylarTasksPlugin.setPriorityLevel(MylarTasksPlugin.Priority_Level.P2, isChecked());
- if (isChecked()) {
- priorityFilter.displayPriority(PRIORITY_LEVELS[1]);
- } else {
- priorityFilter.hidePriority(PRIORITY_LEVELS[1]);
- }
- viewer.refresh();
- }
- };
- P2.setEnabled(true);
- P2.setChecked(MylarTasksPlugin.getPriorityLevel(MylarTasksPlugin.Priority_Level.P2));
- P2.setToolTipText(PRIORITY_LEVELS[1]);
- item= new ActionContributionItem(P2);
- item.fill(dropDownMenu, -1);
-
- Action P3 = new Action(PRIORITY_LEVELS[2], AS_CHECK_BOX) {
- @Override
- public void run() {
- MylarTasksPlugin.setPriorityLevel(MylarTasksPlugin.Priority_Level.P3, isChecked());
- if (isChecked()) {
- priorityFilter.displayPriority(PRIORITY_LEVELS[2]);
- } else {
- priorityFilter.hidePriority(PRIORITY_LEVELS[2]);
- }
- viewer.refresh();
- }
- };
- P3.setEnabled(true);
- P3.setChecked(MylarTasksPlugin.getPriorityLevel(MylarTasksPlugin.Priority_Level.P3));
- P3.setToolTipText(PRIORITY_LEVELS[2]);
- item= new ActionContributionItem(P3);
- item.fill(dropDownMenu, -1);
-
- Action P4 = new Action(PRIORITY_LEVELS[3], AS_CHECK_BOX) {
- @Override
- public void run() {
- MylarTasksPlugin.setPriorityLevel(MylarTasksPlugin.Priority_Level.P4, isChecked());
- if (isChecked()) {
- priorityFilter.displayPriority(PRIORITY_LEVELS[3]);
- } else {
- priorityFilter.hidePriority(PRIORITY_LEVELS[3]);
- }
- viewer.refresh();
- }
- };
- P4.setEnabled(true);
- P4.setChecked(MylarTasksPlugin.getPriorityLevel(MylarTasksPlugin.Priority_Level.P4));
- P4.setToolTipText(PRIORITY_LEVELS[3]);
- item= new ActionContributionItem(P4);
- item.fill(dropDownMenu, -1);
-
- Action P5 = new Action(PRIORITY_LEVELS[4], AS_CHECK_BOX) {
- @Override
- public void run() {
- MylarTasksPlugin.setPriorityLevel(MylarTasksPlugin.Priority_Level.P5, isChecked());
- if (isChecked()) {
- priorityFilter.displayPriority(PRIORITY_LEVELS[4]);
- } else {
- priorityFilter.hidePriority(PRIORITY_LEVELS[4]);
- }
- viewer.refresh();
- }
- };
- P5.setEnabled(true);
- P5.setChecked(MylarTasksPlugin.getPriorityLevel(MylarTasksPlugin.Priority_Level.P5));
- P5.setToolTipText(PRIORITY_LEVELS[4]);
- item= new ActionContributionItem(P5);
- item.fill(dropDownMenu, -1);
- }
- public void run() {
- this.setChecked(isChecked());
- }
- }
-
- private ViewerFilter completeFilter = new ViewerFilter(){
- @Override
- public boolean select(Viewer viewer, Object parentElement, Object element) {
- if (element instanceof ITask) {
- return !((ITask)element).isCompleted();
- } else {
- return true;
- }
- }
- };
-
- private ViewerFilter inCompleteFilter = new ViewerFilter(){
- @Override
- public boolean select(Viewer viewer, Object parentElement, Object element) {
- if (element instanceof ITask) {
- return ((ITask)element).isCompleted();
- } else {
- return true;
- }
- }
- };
-
- public class PriorityFilter extends ViewerFilter {
- // list of priorities that will be shown in the tasklistview
- private List<String> priorities = new ArrayList<String>();
-
- public PriorityFilter() {
- for (Priority_Level level : MylarTasksPlugin.getPriorityLevels()) {
- displayPriority(level.toString());
- }
- }
-
- public void displayPriority(String p) {
- if (!priorities.contains(p)) {
- priorities.add(p);
- }
- }
-
- public void hidePriority(String p) {
- priorities.remove(p);
- }
- @Override
- public boolean select(Viewer viewer, Object parentElement, Object element) {
- if (element instanceof ITask) {
- ITask task = (ITask) element;
- if (priorities.size() == PRIORITY_LEVELS.length) {
- return true;
- } else {
- for (String filter : priorities) {
- if (task.getPriority().equals(filter)) {
- return true;
- }
- }
- return false;
- }
- } else {
- return true;
- }
- }
-
- };
-
- class TaskListContentProvider implements IStructuredContentProvider, ITreeContentProvider {
- public void inputChanged(Viewer v, Object oldInput, Object newInput) {
- // don't care if the input changes
- }
- public void dispose() {
- // don't care if we are disposed
- }
- public Object[] getElements(Object parent) {
- if (parent.equals(getViewSite())) {
- return MylarTasksPlugin.getTaskListManager().getTaskList().getRoots().toArray();
- }
- return getChildren(parent);
- }
- public Object getParent(Object child) {
- if (child instanceof ITask) {
- if (((ITask)child).getParent() != null) {
- return ((ITask)child).getParent();
- } else {
- return ((ITask)child).getCategory();
- }
-
- }
- return null;
- }
- public Object [] getChildren(Object parent) {
- if (parent instanceof TaskCategory) {
- return ((TaskCategory)parent).getChildren().toArray();
- } else if (parent instanceof Task) {
- return ((Task)parent).getChildren().toArray();
- } else if (parent instanceof BugzillaQueryCategory) {
- return ((BugzillaQueryCategory) parent).getHits().toArray();
- }
- return new Object[0];
- }
- public boolean hasChildren(Object parent) {
- if (parent instanceof TaskCategory) {
- TaskCategory cat = (TaskCategory)parent;
- return cat.getChildren() != null && cat.getChildren().size() > 0;
- } else if (parent instanceof Task) {
- Task t = (Task) parent;
- return t.getChildren() != null && t.getChildren().size() > 0;
- } else if (parent instanceof BugzillaQueryCategory) {
- BugzillaQueryCategory cat = (BugzillaQueryCategory)parent;
- return cat.getHits() != null && cat.getHits().size() > 0;
- }
- return false;
- }
- }
-
- public TaskListView() {
- INSTANCE = this;
- }
-
- class TaskListCellModifier implements ICellModifier {
-
- public boolean canModify(Object element, String property) {
- int columnIndex = Arrays.asList(columnNames).indexOf(property);
- if (element instanceof ITask) {
- ITask task = (ITask) element;
- switch (columnIndex) {
- case 0: return true;
- case 1: return false;
- case 2: return !(task instanceof BugzillaTask);
- case 3: return !(task instanceof BugzillaTask);
- case 4: return false;
- }
- } else if (element instanceof AbstractCategory) {
- switch (columnIndex) {
- case 0:
- case 1:
- case 2:
- return false;
- case 3: return true;
- case 4: return false;
- }
- } else if (element instanceof BugzillaHit){
- if (columnIndex == 0) {
- return true;
- }else {
- return false;
- }
- }
- return false;
- }
-
- public Object getValue(Object element, String property) {
- int columnIndex = Arrays.asList(columnNames).indexOf(property);
- if (element instanceof ITask) {
- ITask task = (ITask) element;
- switch (columnIndex) {
- case 0:
- return new Boolean(task.isCompleted());
- case 1:
- return "";
- case 2:
- String priorityString = task.getPriority().substring(1);
- return new Integer(priorityString);
- case 3:
- return task.getLabel();
- case 4:
- return task.getHandle();
- }
- } else if (element instanceof AbstractCategory) {
- AbstractCategory cat = (AbstractCategory) element;
- switch (columnIndex) {
- case 0:
- return new Boolean(false);
- case 1:
- return "";
- case 2:
- return "";
- case 3:
- return cat.getDescription(true);
- case 4:
- return "";
- }
- } else if (element instanceof BugzillaHit) {
- BugzillaHit hit = (BugzillaHit) element;
- ITask task = hit.getAssociatedTask();
- switch (columnIndex) {
- case 0:
- if(task == null){
- return new Boolean(true);
- } else {
- return new Boolean(task.isCompleted());
- }
- case 1:
- return "";
- case 2:
- String priorityString = hit.getPriority().substring(1);
- return new Integer(priorityString);
- case 3:
- return hit.getDescription(true);
- case 4:
- return hit.getHandle();
- }
- }
- return "";
- }
-
- public void modify(Object element, String property, Object value) {
- int columnIndex = -1;
- try {
- columnIndex = Arrays.asList(columnNames).indexOf(property);
- if (((TreeItem) element).getData() instanceof ITask) {
-
- final ITask task = (ITask) ((TreeItem) element).getData();
- switch (columnIndex) {
- case 0:
- if (task.isActive()) {
- new TaskDeactivateAction(task).run();
- } else {
- new TaskActivateAction(task).run();
- }
- viewer.setSelection(null);
- break;
- case 1:
- break;
- case 2:
- Integer intVal = (Integer) value;
- task.setPriority("P" + (intVal + 1));
- viewer.setSelection(null);
- break;
- case 3:
- task.setLabel(((String) value).trim());
- MylarTasksPlugin.getTaskListManager()
- .taskPropertyChanged(task, columnNames[3]);
- viewer.setSelection(null);
- break;
- case 4:
- break;
- }
- } else if (((TreeItem) element).getData() instanceof AbstractCategory) {
- AbstractCategory cat = (AbstractCategory)((TreeItem) element).getData();
- switch (columnIndex) {
- case 0:
- viewer.setSelection(null);
- break;
- case 1:
- break;
- case 2:
- break;
- case 3:
- cat.setDescription(((String) value).trim());
- viewer.setSelection(null);
- break;
- case 4:
- break;
- }
- } else if (((TreeItem) element).getData() instanceof BugzillaHit) {
- BugzillaHit hit = (BugzillaHit)((TreeItem) element).getData();
- switch (columnIndex) {
- case 0:
- BugzillaTask task = hit.getAssociatedTask();
- if(task == null){
- task = new BugzillaTask(hit);
- hit.setAssociatedTask(task);
- MylarTasksPlugin.getTaskListManager().getTaskList().addToBugzillaTaskRegistry(task);
- // TODO move the task to a special folder
- }
- if (task.isActive()) {
- MylarTasksPlugin.getTaskListManager()
- .deactivateTask(task);
- } else {
- MylarTasksPlugin.getTaskListManager().activateTask(
- task);
- }
- viewer.setSelection(null);
- break;
- case 1:
- break;
- case 2:
- break;
- case 3:
- viewer.setSelection(null);
- break;
- case 4:
- break;
- }
- }
- viewer.refresh();
- } catch (Exception e) {
- MylarPlugin.log(e, e.getMessage());
- }
- }
- }
-
- private class TaskListTableSorter extends ViewerSorter {
-
- private String column;
-
- public TaskListTableSorter(String column) {
- super();
- this.column = column;
- }
-
- /**
- * compare - invoked when column is selected calls the actual comparison
- * method for particular criteria
- */
- @Override
- public int compare(Viewer compareViewer, Object o1, Object o2) {
- if (o1 instanceof AbstractCategory) {
- if (o2 instanceof AbstractCategory) {
- return 0;
- } else {
- return -1;
- }
- } else if(o1 instanceof ITask){
- if (o2 instanceof AbstractCategory) {
- return -1;
- } else if(o2 instanceof ITask) {
-
- ITask task1 = (ITask) o1;
- ITask task2 = (ITask) o2;
-
- if (task1.isCompleted()) return 1;
- if (task2.isCompleted()) return -1;
- if (column == columnNames[1]) {
- if (task1 instanceof BugzillaTask && !(task2 instanceof BugzillaTask)) {
- return 1;
- } else {
- return -1;
- }
- } else if (column == columnNames[2]) {
- return task1.getPriority().compareTo(task2.getPriority());
- } else if (column == columnNames[3]) {
- return task1.getLabel().compareTo(task2.getLabel());
- } else if (column == columnNames[4]){
- return task1.getPath().compareTo(task2.getPath());
- } else {
- return 0;
- }
- }
- } else if(o1 instanceof BugzillaHit && o2 instanceof BugzillaHit){
- BugzillaHit task1 = (BugzillaHit) o1;
- BugzillaHit task2 = (BugzillaHit) o2;
-
- if (column == columnNames[1]) {
- return 0;
- } else if (column == columnNames[2]) {
- return task1.getPriority().compareTo(task2.getPriority());
- } else if (column == columnNames[3]) {
- return task1.getDescription(false).compareTo(task2.getDescription(false));
- } else if (column == columnNames[4]){
- return task1.getHandle().compareTo(task2.getHandle());
- } else {
- return 0;
- }
- } else{
- return 0;
- }
- return 0;
- }
- }
-
- @Override
- public void init(IViewSite site,IMemento memento) throws PartInitException {
- init(site);
- this.taskListMemento = memento;
- }
-
- @Override
- public void saveState(IMemento memento) {
- IMemento colMemento = memento.createChild(columnWidthIdentifier);
-
- for (int i = 0; i < columnWidths.length; i++) {
- IMemento m = colMemento.createChild("col"+i);
- m.putInteger("width", columnWidths[i]);
- }
-
- IMemento sorter = memento.createChild(tableSortIdentifier);
- IMemento m = sorter.createChild("sorter");
- m.putInteger("sortIndex", sortIndex);
- }
-
- private void restoreState() {
- if (taskListMemento == null)
- return;
- IMemento taskListWidth = taskListMemento.getChild(columnWidthIdentifier);
- if (taskListWidth != null) {
- for (int i = 0; i < columnWidths.length; i++) {
- IMemento m = taskListWidth.getChild("col"+i);
- if (m != null) {
- int width = m.getInteger("width");
- columnWidths[i] = width;
- columns[i].setWidth(width);
- }
- }
- }
- IMemento sorterMemento = taskListMemento.getChild(tableSortIdentifier);
- if (sorterMemento != null) {
- IMemento m = sorterMemento.getChild("sorter");
- if (m != null) {
- sortIndex = m.getInteger("sortIndex");
- } else {
- sortIndex = 2;
- }
- } else {
- sortIndex = 2; // default priority
- }
- viewer.setSorter(new TaskListTableSorter(columnNames[sortIndex]));
- viewer.addFilter(priorityFilter);
- if(MylarTasksPlugin.getDefault().isFilterInCompleteMode()) viewer.addFilter(inCompleteFilter);
- if(MylarTasksPlugin.getDefault().isFilterCompleteMode()) viewer.addFilter(completeFilter);
- viewer.refresh();
- }
-
- /**
- * This is a callback that will allow us
- * to create the viewer and initialize it.
- */
- @Override
- public void createPartControl(Composite parent) {
- viewer = new TreeViewer(parent, SWT.VERTICAL | SWT.H_SCROLL | SWT.V_SCROLL | SWT.FULL_SELECTION | SWT.HIDE_SELECTION);
- viewer.getTree().setHeaderVisible(true);
- viewer.getTree().setLinesVisible(true);
- viewer.setColumnProperties(columnNames);
- viewer.setUseHashlookup(true);
-
- columns = new TreeColumn[columnNames.length];
- for (int i = 0; i < columnNames.length; i++) {
- columns[i] = new TreeColumn(viewer.getTree(), 0); // SWT.LEFT
- columns[i].setText(columnNames[i]);
- columns[i].setWidth(columnWidths[i]);
- final int index = i;
- columns[i].addSelectionListener(new SelectionAdapter() {
-
- @Override
- public void widgetSelected(SelectionEvent e) {
- sortIndex = index;
- viewer.setSorter(new TaskListTableSorter(columnNames[sortIndex]));
- }
- });
- columns[i].addControlListener(new ControlListener () {
- public void controlResized(ControlEvent e) {
- for (int j = 0; j < columnWidths.length; j++) {
- if (columns[j].equals(e.getSource())) {
- columnWidths[j] = columns[j].getWidth();
- }
- }
- }
- public void controlMoved(ControlEvent e) {
- // don't care if the control is moved
- }
- });
- }
-
- CellEditor[] editors = new CellEditor[columnNames.length];
- TextCellEditor textEditor = new TextCellEditor(viewer.getTree());
- ((Text) textEditor.getControl()).setOrientation(SWT.LEFT_TO_RIGHT);
- editors[0] = new CheckboxCellEditor();
- editors[1] = textEditor;
- editors[2] = new ComboBoxCellEditor(viewer.getTree(), PRIORITY_LEVELS, SWT.READ_ONLY);
- editors[3] = textEditor;
- viewer.setCellEditors(editors);
- viewer.setCellModifier(new TaskListCellModifier());
- viewer.setSorter(new TaskListTableSorter(columnNames[sortIndex]));
-
- drillDownAdapter = new DrillDownAdapter(viewer);
- viewer.setContentProvider(new TaskListContentProvider());
- TaskListLabelProvider lp = new TaskListLabelProvider();
- lp.setBackgroundColor(parent.getBackground());
- viewer.setLabelProvider(lp);
- viewer.setInput(getViewSite());
-
- makeActions();
- hookContextMenu();
- hookDoubleClickAction();
- contributeToActionBars();
- ToolTipHandler toolTipHandler = new ToolTipHandler(viewer.getControl().getShell());
- toolTipHandler.activateHoverHelp(viewer.getControl());
-
- initDragAndDrop(parent);
- expandToActiveTasks();
- restoreState();
- }
-
- @MylarWebRef(name="Drag and drop article", url="http://www.eclipse.org/articles/Article-Workbench-DND/drag_drop.html")
- private void initDragAndDrop(Composite parent) {
- Transfer[] types = new Transfer[] { TextTransfer.getInstance() };
-
- viewer.addDragSupport(DND.DROP_MOVE, types, new DragSourceListener() {
-
- public void dragStart(DragSourceEvent event) {
- if (((StructuredSelection) viewer.getSelection()).isEmpty()) {
- event.doit = false;
- }
- }
-
- public void dragSetData(DragSourceEvent event) {
- StructuredSelection selection = (StructuredSelection) viewer.getSelection();
- if (!selection.isEmpty()) {
- event.data = "" + ((ITask) selection.getFirstElement()).getHandle();
- } else {
- event.data = "null";
- }
- }
-
- public void dragFinished(DragSourceEvent event) {
- // don't care if the drag is done
- }
- });
-
- viewer.addDropSupport(DND.DROP_MOVE, types, new ViewerDropAdapter(viewer) {
- {
- setFeedbackEnabled(false);
- }
-
- @Override
- public boolean performDrop(Object data) {
- Object selectedObject = ((IStructuredSelection) ((TreeViewer) getViewer())
- .getSelection()).getFirstElement();
- if (selectedObject instanceof ITask) {
- ITask source = (ITask) selectedObject;
- if (source.getCategory() != null) {
- source.getCategory().removeTask(source);
- } else if (source.getParent() != null) {
- source.getParent().removeSubTask(source);
- } else {
- MylarTasksPlugin.getTaskListManager().getTaskList().getRootTasks().remove(source);
- }
-
- if (getCurrentTarget() instanceof TaskCategory) {
- ((TaskCategory) getCurrentTarget()).addTask(source);
- source.setCategory((TaskCategory)getCurrentTarget());
- } else if (getCurrentTarget() instanceof ITask) {
- ITask target = (ITask) getCurrentTarget();
- source.setCategory(null);
- target.addSubTask(source);
- source.setParent(target);
- }
- viewer.setSelection(null);
- viewer.refresh();
- return true;
- }
- return false;
- }
-
- @Override
- public boolean validateDrop(Object targetObject, int operation,
- TransferData transferType) {
- Object selectedObject = ((IStructuredSelection) ((TreeViewer) getViewer())
- .getSelection()).getFirstElement();
- if (selectedObject instanceof ITask) {
- if (getCurrentTarget() != null &&
- (getCurrentTarget() instanceof ITask || getCurrentTarget() instanceof TaskCategory)) {
- return true;
- } else {
- return false;
- }
- }
- return TextTransfer.getInstance().isSupportedType(transferType);
- }
-
- });
- }
-
- private void expandToActiveTasks() {
- List<ITask> activeTasks = MylarTasksPlugin.getTaskListManager().getTaskList().getActiveTasks();
- for (ITask t : activeTasks) {
- viewer.expandToLevel(t, 0);
- }
- }
-
- private void hookContextMenu() {
- MenuManager menuMgr = new MenuManager("#PopupMenu");
- menuMgr.setRemoveAllWhenShown(true);
- menuMgr.addMenuListener(new IMenuListener() {
- public void menuAboutToShow(IMenuManager manager) {
- TaskListView.this.fillContextMenu(manager);
- }
- });
- Menu menu = menuMgr.createContextMenu(viewer.getControl());
- viewer.getControl().setMenu(menu);
- getSite().registerContextMenu(menuMgr, viewer);
- }
-
- private void contributeToActionBars() {
- IActionBars bars = getViewSite().getActionBars();
- fillLocalPullDown(bars.getMenuManager());
- fillLocalToolBar(bars.getToolBarManager());
- }
-
- private void fillLocalPullDown(IMenuManager manager) {
- drillDownAdapter.addNavigationActions(manager);
-// manager.add(createCategory);
-// manager.add(new Separator());
-// manager.add(createTask);
- }
-
- void fillContextMenu(IMenuManager manager) {
- manager.add(completeTask);
- manager.add(incompleteTask);
-// manager.add(new Separator());
- manager.add(createTask);
- manager.add(createBugzillaTask);
-// manager.add(rename);
- manager.add(delete);
- manager.add(clearSelectedTaskscapeAction);
- manager.add(moveTaskToRoot);
- manager.add(new Separator());
- MenuManager subMenuManager = new MenuManager("Choose Highlighter");
- final Object selectedObject = ((IStructuredSelection)viewer.getSelection()).getFirstElement();
- for (Iterator<Highlighter> it = MylarUiPlugin.getDefault().getHighlighters().iterator(); it.hasNext();) {
- final Highlighter highlighter = it.next();
- if (selectedObject instanceof Task){
- Action action = new Action() {
-
- @Override
- public void run() {
- Task task = (Task)selectedObject;
- MylarUiPlugin.getDefault().setHighlighterMapping(task.getHandle(), highlighter.getName());
- TaskListView.this.viewer.refresh();
- MylarPlugin.getTaskscapeManager().notifyPostPresentationSettingsChange(ITaskscapeListener.UpdateKind.HIGHLIGHTER);
-// taskscapeComponent.getTableViewer().refresh();
- }
- };
- if (highlighter.isGradient()) {
- action.setImageDescriptor(new HighlighterImageDescriptor(highlighter.getBase(), highlighter.getLandmarkColor()));
- } else {
- action.setImageDescriptor(new HighlighterImageDescriptor(highlighter.getLandmarkColor(), highlighter.getLandmarkColor()));
- }
- action.setText(highlighter.toString());
- subMenuManager.add(action);
- } else {
-// showMessage("Select task before choosing highlighter");
- }
- }
- manager.add(subMenuManager);
- manager.add(new Separator(IWorkbenchActionConstants.MB_ADDITIONS));
- updateActionEnablement(selectedObject);
- }
-
- private void updateActionEnablement(Object sel){
- if(sel != null && sel instanceof ITaskListElement){
- if(sel instanceof BugzillaHit){
- BugzillaTask task = ((BugzillaHit)sel).getAssociatedTask();
- if(task == null){
- clearSelectedTaskscapeAction.setEnabled(false);
- } else {
- clearSelectedTaskscapeAction.setEnabled(true);
- }
- completeTask.setEnabled(false);
- incompleteTask.setEnabled(false);
- moveTaskToRoot.setEnabled(false);
- delete.setEnabled(false);
- } else if(sel instanceof BugzillaTask){
- completeTask.setEnabled(false);
- incompleteTask.setEnabled(false);
- } else if(sel instanceof AbstractCategory){
- clearSelectedTaskscapeAction.setEnabled(false);
- moveTaskToRoot.setEnabled(false);
- completeTask.setEnabled(false);
- incompleteTask.setEnabled(false);
- } else {
- delete.setEnabled(true);
- moveTaskToRoot.setEnabled(true);
- completeTask.setEnabled(true);
- incompleteTask.setEnabled(true);
- clearSelectedTaskscapeAction.setEnabled(true);
- }
-
- }else {
- delete.setEnabled(true);
- moveTaskToRoot.setEnabled(true);
- clearSelectedTaskscapeAction.setEnabled(false);
- }
- }
-
- private void fillLocalToolBar(IToolBarManager manager) {
- manager.add(createTask);
- manager.add(createCategory);
- manager.add(new Separator());
- manager.add(createBugzillaTask);
-
- manager.add(createBugzillaQueryCategory);
- manager.add(refresh);
- manager.add(new Separator());
- manager.add(filterCompleteTask);
-// manager.add(filterInCompleteTask);
- manager.add(filterOnPriority);
-
- }
-
- /**
- * @see org.eclipse.pde.internal.ui.view.HistoryDropDownAction
- *
- */
- private void makeActions() {
- refresh = new RefreshBugzillaReportsAction(this);
- createTask = new CreateTaskAction(this);
- createCategory = new CreateCategoryAction(this);
- createBugzillaQueryCategory = new CreateBugzillaQueryCategoryAction(this);
- createBugzillaTask = new CreateBugzillaTaskAction(this);
- delete = new DeleteAction(this);
- completeTask = new MarkTaskCompleteAction(this);
- incompleteTask = new MarkTaskIncompleteAction(this);
-// rename = new RenameAction();
- clearSelectedTaskscapeAction = new ClearContextAction(this);
- moveTaskToRoot = new MoveTaskToRootAction(this);
- doubleClickAction = new OpenTaskEditorAction(this);
- filterCompleteTask = new FilterCompletedTasksAction(this);
-// filterInCompleteTask = new FilterIncompleteTasksAction();
- filterOnPriority = new PriorityDropDownAction();
- }
-
- /**
- * Recursive function that checks for the occurrence of a certain task id.
- * All children of the supplied node will be checked.
- *
- * @param task
- * The <code>ITask</code> object that is to be searched.
- * @param taskId
- * The id that is being searched for.
- * @return <code>true</code> if the id was found in the node or any of its
- * children
- */
- protected boolean lookForId(String taskId) {
- for (ITask task : MylarTasksPlugin.getTaskListManager().getTaskList().getRootTasks()) {
- if (task.getHandle().equals(taskId)) {
- return true;
- }
- }
- for (TaskCategory cat : MylarTasksPlugin.getTaskListManager().getTaskList().getTaskCategories()) {
- for (ITask task : cat.getChildren()) {
- if (task.getHandle().equals(taskId)) {
- return true;
- }
- }
- }
- return false;
- }
-
- public void closeTaskEditors(ITask task, IWorkbenchPage page) throws LoginException, IOException{
- IEditorInput input = null;
- if (task instanceof BugzillaTask) {
- input = new BugzillaTaskEditorInput((BugzillaTask)task);
- } else if (task instanceof Task) {
- input = new TaskEditorInput((Task) task);
- }
- IEditorPart editor = page.findEditor(input);
-
- if (editor != null) {
- page.closeEditor(editor, false);
- }
- }
-
- public void refreshChildren(List<ITask> children) {
- if (children != null) {
- for (ITask child : children) {
- if (child instanceof BugzillaTask) {
- ((BugzillaTask)child).refresh();
- }
- }
- }
- }
-
- private void hookDoubleClickAction() {
- viewer.addDoubleClickListener(new IDoubleClickListener() {
- public void doubleClick(DoubleClickEvent event) {
- doubleClickAction.run();
- }
- });
- }
-
- public void showMessage(String message) {
- MessageDialog.openInformation(
- viewer.getControl().getShell(),
- "Tasklist Message",
- message);
- }
-
- /**
- * Passing the focus request to the viewer's control.
- */
- @Override
- public void setFocus() {
- viewer.getControl().setFocus();
- //TODO: foo
- }
-
- public String getBugIdFromUser() {
- InputDialog dialog = new InputDialog(
- Workbench.getInstance().getActiveWorkbenchWindow().getShell(),
- "Enter Bugzilla ID",
- "Enter the Bugzilla ID: ",
- "",
- null);
- int dialogResult = dialog.open();
- if (dialogResult == Window.OK) {
- return dialog.getValue();
- } else {
- return null;
- }
- }
-
- public String getLabelNameFromUser(String kind) {
-
- InputDialog dialog = new InputDialog(
- Workbench.getInstance().getActiveWorkbenchWindow().getShell(),
- "Enter name",
- "Enter a name for the " + kind + ": ",
- "",
- null);
- int dialogResult = dialog.open();
- if (dialogResult == Window.OK) {
- return dialog.getValue();
- } else {
- return null;
- }
- }
-
- public void notifyTaskDataChanged(ITask task) {
- if (viewer.getTree() != null && !viewer.getTree().isDisposed()) {
- viewer.refresh();
- }
- }
-
- public static TaskListView getDefault() {
- return INSTANCE;
- }
-
- public TreeViewer getViewer() {
- return viewer;
- }
-
- public ViewerFilter getCompleteFilter() {
- return completeFilter;
- }
-
- public ViewerFilter getInCompleteFilter() {
- return inCompleteFilter;
- }
-
- public PriorityFilter getPriorityFilter() {
- return priorityFilter;
- }
-}
-
-//TextTransfer textTransfer = TextTransfer.getInstance();
-//DropTarget target = new DropTarget(viewer.getTree(), DND.DROP_MOVE);
-//target.setTransfer(new Transfer[] { textTransfer });
-//target.addDropListener(new TaskListDropTargetListener(parent, null, textTransfer, true));
-//
-//DragSource source = new DragSource(viewer.getTree(), DND.DROP_MOVE);
-//source.setTransfer(types);
-
-//source.addDragListener(new DragSourceListener() {
-//public void dragStart(DragSourceEvent event) {
-// if (((StructuredSelection)viewer.getSelection()).isEmpty()) {
-// event.doit = false;
-// }
-//}
-//public void dragSetData(DragSourceEvent event) {
-// StructuredSelection selection = (StructuredSelection) viewer.getSelection();
-// if (!selection.isEmpty()) {
-// event.data = "" + ((ITask)selection.getFirstElement()).getId();
-// } else {
-// event.data = "null";
-// }
-//}
-//
-//public void dragFinished(DragSourceEvent event) { }
-//});
-
-
-// public boolean getServerStatus() {
-// return serverStatus;
-// }
-//
-// /**
-// * Sets whether or not we could connect to the Bugzilla server. If
-// * necessary, the corresponding label in the view is updated.
-// *
-// * @param canRead
-// * <code>true</code> if the Bugzilla server could be connected
-// * to
-// */
-// public void setServerStatus(boolean canRead) {
-// if (serverStatus != canRead) {
-// serverStatus = canRead;
-// updateServerStatusLabel();
-// }
-// }
-//
-// private void updateServerStatusLabel() {
-// if (serverStatusLabel.isDisposed()) {
-// return;
-// }
-// if (serverStatus) {
-// serverStatusLabel.setText(CAN_READ_LABEL);
-// }
-// else {
-// serverStatusLabel.setText(CANNOT_READ_LABEL);
-// }
-// }
-//
-// private class ServerPingJob extends Job {
-// private boolean shouldCheckAgain = true;
-// private int counter = 0;
-//
-// public ServerPingJob(String name) {
-// super(name);
-// }
-//
-// public void stopPinging() {
-// shouldCheckAgain = false;
-// }
-//
-// protected IStatus run(IProgressMonitor monitor) {
-// while (shouldCheckAgain) {
-// try {
-// final boolean canReadFromServer = TaskListView.checkServer();
-// Workbench.getInstance().getDisplay().asyncExec(new Runnable() {
-// public void run() {
-// setServerStatus(canReadFromServer);
-// }
-// });
-// Thread.sleep(10000/*MylarPreferencePage.getServerPing()*5000*/);
-// } catch (InterruptedException e) {
-// break;
-// }
-// }
-// return new Status(IStatus.OK, MylarPlugin.IDENTIFIER, IStatus.OK, "", null);
-// }
-// }
-//
-// /**
-// * @return <code>true</code> if we could connect to the Bugzilla server
-// */
-// public static boolean checkServer() {
-// boolean canRead = true;
-// BufferedReader in = null;
-//
-// // Call this function to intialize the Bugzilla url that the repository
-// // is using.
-// BugzillaRepository.getInstance();
-//
-// try {
-// // connect to the bugzilla server
-// SSLContext ctx = SSLContext.getInstance("TLS");
-// javax.net.ssl.TrustManager[] tm = new javax.net.ssl.TrustManager[]{new TrustAll()};
-// ctx.init(null, tm, null);
-// HttpsURLConnection.setDefaultSSLSocketFactory(ctx.getSocketFactory());
-// String urlText = "";
-//
-// // use the usename and password to get into bugzilla if we have it
-// if(BugzillaPreferences.getUserName() != null && !BugzillaPreferences.getUserName().equals("") && BugzillaPreferences.getPassword() != null && !BugzillaPreferences.getPassword().equals(""))
-// {
-// /*
-// * The UnsupportedEncodingException exception for
-// * URLEncoder.encode() should not be thrown, since every
-// * implementation of the Java platform is required to support
-// * the standard charset "UTF-8"
-// */
-// try {
-// urlText += "?GoAheadAndLogIn=1&Bugzilla_login=" + URLEncoder.encode(BugzillaPreferences.getUserName(), "UTF-8") + "&Bugzilla_password=" + URLEncoder.encode(BugzillaPreferences.getPassword(), "UTF-8");
-// } catch (UnsupportedEncodingException e) { }
-// }
-//
-// URL url = new URL(BugzillaRepository.getURL() + "/enter_bug.cgi" + urlText);
-//
-// // create a new input stream for getting the bug
-// in = new BufferedReader(new InputStreamReader(url.openStream()));
-// }
-// catch (Exception e) {
-// // If there was an IOException, then there was a problem connecting.
-// // If there was some other exception, then it was a problem not
-// // related to the server.
-// if (e instanceof IOException) {
-// canRead = false;
-// }
-// }
-//
-// // Close the BufferedReader if we opened one.
-// try {
-// if (in != null)
-// in.close();
-// } catch(IOException e) {}
-//
-// return canRead;
-// }
-//
-// public void dispose() {
-// if (serverPingJob != null) {
-// serverPingJob.stopPinging();
-// }
-// super.dispose();
-// }
-
-// source.addDragListener(new DragSourceListener() {
-//
-// public void dragStart(DragSourceEvent event) {
-// if (((StructuredSelection) viewer.getSelection()).getFirstElement() == null) {
-// event.doit = false;
-// }
-// }
-//
-// public void dragSetData(DragSourceEvent event) {
-// StructuredSelection selection = (StructuredSelection)viewer.getSelection();
-// ITask task = (ITask) selection.getFirstElement();
-// if (task != null) {
-// event.data = "" + task.getId();
-// } else {
-// event.data = " ";
-// }
-// }
-//
-// public void dragFinished(DragSourceEvent event) {
-// StructuredSelection selection = (StructuredSelection)viewer.getSelection();
-// if (selection.isEmpty()) {
-// return;
-// } else {
-// ITask task = (ITask) selection.getFirstElement();
-//
-// System.err.println(">>> got task: " + task + ">> " + );
-//
-// }
-// }
-//
-// });
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/views/ToolTipHandler.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/views/ToolTipHandler.java
deleted file mode 100644
index 5efee7529..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/views/ToolTipHandler.java
+++ /dev/null
@@ -1,240 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/**
- * Copied from newsgroup, forwarded from Make Technologies
- */
-
-package org.eclipse.mylar.tasks.ui.views;
-
-import org.eclipse.core.runtime.IAdaptable;
-import org.eclipse.mylar.tasks.ITask;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.*;
-import org.eclipse.swt.graphics.*;
-import org.eclipse.swt.layout.*;
-import org.eclipse.swt.widgets.*;
-
-
-public class ToolTipHandler {
- private Shell parentShell;
-
- private Shell tipShell;
-
- private Label tipLabelImage;
- private Label tipLabelText;
-
- private Widget tipWidget; // widget this tooltip is hovering over
-
- protected Point tipPosition; // the position being hovered over on the
- // Entire display
-
- protected Point widgetPosition; // the position hovered over in the Widget;
-
- /**
- * Creates a new tooltip handler
- *
- * @param parent
- * the parent Shell
- */
- public ToolTipHandler(Shell parent) {
- final Display display = parent.getDisplay();
- this.parentShell = parent;
- tipShell = new Shell(parent, SWT.NONE);
- GridLayout gridLayout = new GridLayout();
- gridLayout.numColumns = 2;
- gridLayout.marginWidth = 2;
- gridLayout.marginHeight = 2;
- tipShell.setLayout(gridLayout);
- tipShell.setBackground(display
- .getSystemColor(SWT.COLOR_INFO_BACKGROUND));
-
- tipLabelImage = new Label(tipShell, SWT.NONE);
- tipLabelImage.setForeground(display
- .getSystemColor(SWT.COLOR_INFO_FOREGROUND));
- tipLabelImage.setBackground(display
- .getSystemColor(SWT.COLOR_INFO_BACKGROUND));
-
- GridData imageGridData = new GridData(
- GridData.HORIZONTAL_ALIGN_BEGINNING
- | GridData.VERTICAL_ALIGN_BEGINNING);
- tipLabelImage.setLayoutData(imageGridData);
-
- tipLabelText = new Label(tipShell, SWT.NONE);
- tipLabelText.setForeground(display
- .getSystemColor(SWT.COLOR_INFO_FOREGROUND));
- tipLabelText.setBackground(display
- .getSystemColor(SWT.COLOR_INFO_BACKGROUND));
-
- GridData textGridData = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_CENTER);
- tipLabelText.setLayoutData(textGridData);
- }
-
- private ITask getTask(Object hoverObject) {
- if (hoverObject instanceof Widget) {
- Object data = ((Widget) hoverObject).getData();
- if (data != null) {
- if (data instanceof ITask) {
- return (ITask) data;
- } else if (data instanceof IAdaptable) {
- return (ITask) ((IAdaptable) data).getAdapter(ITask.class);
- }
-
- }
- }
- return null;
- }
-
- protected String getToolTipText(Object object) {
- ITask task = getTask(object);
- if (task != null) {
- return task.getToolTipText();
- }
-
- if (object instanceof Control) {
- return (String) ((Control) object).getData("TIP_TEXT");
- }
- return null;
- }
-
- protected Image getToolTipImage(Object object) {
- ITask projectNode = getTask(object);
- if (projectNode != null) {
- // TODO Code for determining image
- }
- if (object instanceof Control) {
- return (Image) ((Control) object).getData("TIP_IMAGE");
- }
- return null;
- }
-
- protected Object getToolTipHelp(Object object) {
- if (object instanceof Control) {
- return (String) ((Control) object).getData("TIP_HELPTEXT");
- }
- return null;
- }
-
- /**
- * Enables customized hover help for a specified control
- *
- * @control the control on which to enable hoverhelp
- */
- public void activateHoverHelp(final Control control) {
- /*
- * Get out of the way if we attempt to activate the control underneath
- * the tooltip
- */
- control.addMouseListener(new MouseAdapter() {
-
- @Override
- public void mouseDown(MouseEvent e) {
- if (tipShell.isVisible())
- tipShell.setVisible(false);
- }
- });
- /*
- * Trap hover events to pop-up tooltip
- */
- control.addMouseTrackListener(new MouseTrackAdapter() {
-
- @Override
- public void mouseExit(MouseEvent e) {
- if (tipShell.isVisible())
- tipShell.setVisible(false);
- tipWidget = null;
- }
-
- @Override
- public void mouseHover(MouseEvent event) {
- widgetPosition = new Point(event.x, event.y);
- Widget widget = event.widget;
- if (widget instanceof ToolBar) {
- ToolBar w = (ToolBar) widget;
- widget = w.getItem(widgetPosition);
- }
- if (widget instanceof Table) {
- Table w = (Table) widget;
- widget = w.getItem(widgetPosition);
- }
- if (widget instanceof Tree) {
- Tree w = (Tree) widget;
- widget = w.getItem(widgetPosition);
- }
- if (widget == null) {
- tipShell.setVisible(false);
- tipWidget = null;
- return;
- }
- if (widget == tipWidget)
- return;
- tipWidget = widget;
- tipPosition = control.toDisplay(widgetPosition);
- String text = getToolTipText(widget);
- Image image = getToolTipImage(widget);
- if (text == null) {
- return;
- }
- Control sourceControl = (Control) event.getSource();
- sourceControl.setFocus();
- tipLabelText.setText(text);
- tipLabelImage.setImage(image); // accepts null
- tipShell.pack();
- setHoverLocation(tipShell, tipPosition);
- tipShell.setVisible(true);
- }
- });
- /*
- * Trap F1 Help to pop up a custom help box
- */
- control.addHelpListener(new HelpListener() {
- public void helpRequested(HelpEvent event) {
- if (tipWidget == null)
- return;
- Object help = getToolTipHelp(tipWidget);
- if (help == null)
- return;
- if (help.getClass() != String.class) {
- return;
- }
- if (tipShell.isVisible()) {
- tipShell.setVisible(false);
- Shell helpShell = new Shell(parentShell, SWT.SHELL_TRIM);
- helpShell.setLayout(new FillLayout());
- Label label = new Label(helpShell, SWT.NONE);
- label.setText((String) help);
- helpShell.pack();
- setHoverLocation(helpShell, tipPosition);
- helpShell.open();
- }
- }
- });
- }
-
- /**
- * Sets the location for a hovering shell
- *
- * @param shell
- * the object that is to hover
- * @param position
- * the position of a widget to hover over
- * @return the top-left location for a hovering box
- */
- private void setHoverLocation(Shell shell, Point position) {
- Rectangle displayBounds = shell.getDisplay().getBounds();
- Rectangle shellBounds = shell.getBounds();
- shellBounds.x = Math.max(Math.min(position.x, displayBounds.width
- - shellBounds.width), 0);
- shellBounds.y = Math.max(Math.min(position.y + 16, displayBounds.height
- - shellBounds.height), 0);
- shell.setBounds(shellBounds);
- }
-} \ No newline at end of file
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/util/RelativePathUtil.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/util/RelativePathUtil.java
deleted file mode 100644
index b6105b6ed..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/util/RelativePathUtil.java
+++ /dev/null
@@ -1,41 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-package org.eclipse.mylar.tasks.util;
-
-public class RelativePathUtil {
- public static String findRelativePath(String baseDirectory, String filePath) {
- if (filePath.startsWith(baseDirectory)) {
- return filePath.substring(baseDirectory.length(), filePath.lastIndexOf('.'));
- } else {
- StringBuffer result = new StringBuffer(filePath.length());
- String[] rootFolders = baseDirectory.split("/");
- String[] pathFolders = filePath.split("/");
- int diff = 0;
- for (int i = 0; i < pathFolders.length; i++) {
- if (!rootFolders[i].equals(pathFolders[i])) {
- diff = i;
- while (i < rootFolders.length) {
- result.append('.');
- result.append('.');
- result.append('/');
- i++;
- }
- while(diff < pathFolders.length - 1){
- result.append(pathFolders[diff]);
- diff++;
- }
- result.append(pathFolders[diff].substring(0, pathFolders[diff].lastIndexOf('.')));
- }
- }
- return result.toString();
- }
- }
-}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/util/TaskTest.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/util/TaskTest.java
deleted file mode 100644
index 1a67148a2..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/util/TaskTest.java
+++ /dev/null
@@ -1,146 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on Jan 24, 2005
- */
-package org.eclipse.mylar.tasks.util;
-
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * @author Shawn Minto
- */
-public class TaskTest {
- private int id = -1;
-
- private String name = "";
-
- private List<String> categories = new ArrayList<String>();
-
- private List<TaskTest> taskList = new ArrayList<TaskTest>();
-
- @Override
- public String toString() {
- return "Task";
- }
-
- public boolean isEqual(TaskTest otherTask) {
-
- boolean result = true;
- result = result && (this.id == otherTask.id);
- int compare = (this.name.compareTo(otherTask.name));
- if (compare != 0)
- result = false;
- if (!result)
- System.out.println("this: " + this.name + " otherName: "
- + otherTask.name + " a");
-
- if (this.categories.size() == otherTask.categories.size()) {
- for (int i = 0; i < this.categories.size(); i++) {
- compare = this.categories.get(i).compareTo(
- otherTask.categories.get(i));
- if (compare != 0) {
- System.err.println(this.categories.get(i) + " vs "
- + otherTask.categories.get(i));
- result = false;
- break;
- }
- }
- } else {
- System.err.println("Category length different");
- System.err.println("length: " + this.categories.size()
- + " VS Length: " + otherTask.categories.size());
- result = false;
- }
- if (this.taskList.size() == otherTask.taskList.size()) {
- for (int i = 0; i < this.taskList.size(); i++) {
- result = result
- && (this.taskList.get(i).isEqual(otherTask.taskList
- .get(i)));
- }
- } else {
- System.err.println("TaskList size is different!");
- result = false;
- }
- return result;
- }
-
- public static void printTask(TaskTest t, String tab) {
- System.out.println(tab + "TaskID: " + t.id);
- System.out.println(tab + "Name: " + t.name);
- System.out.println(tab + "Categories: ");
- for (int i = 0; i < t.categories.size(); i++) {
- System.out.println(tab + "\t " + t.categories.get(i));
- }
- for (int i = 0; i < t.taskList.size(); i++) {
- printTask(t.taskList.get(i), tab + "\t");
- }
- }
-
- public String getName() {
- return name;
- }
-
- public void setName(String name) {
- this.name = name;
- }
-
- // public List<String> getCategories() {
- // return categories;
- // }
- // public void setCategories(List<String> categories) {
- // this.categories = categories;
- // }
- public int getId() {
- return id;
- }
-
- public void setId(int id) {
- this.id = id;
- }
-
- public void addCategory(String category) {
- this.categories.add(category);
- }
-
- /**
- * @return Returns the categories.
- */
- public List<String> getCategories() {
- return categories;
- }
-
- /**
- * @param categories The categories to set.
- */
- public void setCategories(List<String> categories) {
- this.categories = categories;
- }
-
- /**
- * @return Returns the taskList.
- */
- public List<TaskTest> getTaskList() {
- return taskList;
- }
-
- /**
- * @param taskList The taskList to set.
- */
- public void setTaskList(List<TaskTest> taskList) {
- this.taskList = taskList;
- }
-
- public void addSubTask(TaskTest sub) {
- this.taskList.add(sub);
- }
-}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/util/XmlUtil.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/util/XmlUtil.java
deleted file mode 100644
index 0ac234ab8..000000000
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/util/XmlUtil.java
+++ /dev/null
@@ -1,693 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004 - 2005 University Of British Columbia and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * University Of British Columbia - initial API and implementation
- *******************************************************************************/
-/*
- * Created on Jan 17, 2005
- */
-package org.eclipse.mylar.tasks.util;
-
-import java.io.File;
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.io.OutputStream;
-import java.util.Date;
-import java.util.List;
-import java.util.Map;
-
-import javax.xml.parsers.DocumentBuilder;
-import javax.xml.parsers.DocumentBuilderFactory;
-import javax.xml.parsers.ParserConfigurationException;
-import javax.xml.transform.Result;
-import javax.xml.transform.Source;
-import javax.xml.transform.Transformer;
-import javax.xml.transform.TransformerConfigurationException;
-import javax.xml.transform.TransformerException;
-import javax.xml.transform.TransformerFactory;
-import javax.xml.transform.TransformerFactoryConfigurationError;
-import javax.xml.transform.dom.DOMSource;
-import javax.xml.transform.stream.StreamResult;
-
-import org.eclipse.mylar.core.MylarPlugin;
-import org.eclipse.mylar.tasks.AbstractCategory;
-import org.eclipse.mylar.tasks.BugzillaQueryCategory;
-import org.eclipse.mylar.tasks.BugzillaTask;
-import org.eclipse.mylar.tasks.ITask;
-import org.eclipse.mylar.tasks.Task;
-import org.eclipse.mylar.tasks.TaskCategory;
-import org.eclipse.mylar.tasks.TaskList;
-import org.eclipse.mylar.tasks.BugzillaTask.BugTaskState;
-import org.w3c.dom.Document;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-import org.xml.sax.SAXException;
-
-
-/**
- * @author Ken Sueda
- */
-public class XmlUtil {
-
- private static String readVersion = "";
-
- /**
- *
- * @param tlist
- * @param outFile
- */
- public static void writeTaskList(TaskList tlist, File outFile) {
- DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance();
- DocumentBuilder db;
- Document doc = null;
-
- try {
- db = dbf.newDocumentBuilder();
- doc = db.newDocument();
- } catch (ParserConfigurationException e) {
- e.printStackTrace();
- }
-
- Element root = doc.createElement("TaskList");
- root.setAttribute("Version", "1.0.1");
-
- writeBugzillaRegistry(tlist.getBugzillaTaskRegistry(), doc, root);
-
- // iterate through each subtask and externalize those
- //
- for (AbstractCategory cat : tlist.getCategories()) {
- if (cat instanceof TaskCategory) {
- writeTaskCategory((TaskCategory)cat, doc, root);
- } else if (cat instanceof BugzillaQueryCategory) {
- writeQueryCategory((BugzillaQueryCategory)cat, doc, root);
- }
- }
- for (ITask task : tlist.getRootTasks()) {
- writeTask(task, doc, root);
- }
- doc.appendChild(root);
- writeDOMtoFile(doc, outFile);
- return;
- }
-
- private static void writeBugzillaRegistry(Map<String, BugzillaTask> bugzillaTaskRegistry, Document doc, Element parent) {
- Element node = doc.createElement("BugzillaTaskRegistry");
-
- for (BugzillaTask t : bugzillaTaskRegistry.values()) {
- writeTask(t, doc, node);
- }
- parent.appendChild(node);
- }
-
- /**
- * Writes an XML file from a DOM.
- *
- * doc - the document to write
- * file - the file to be written to
- */
- private static void writeDOMtoFile(Document doc, File file) {
- try {
- // A file output stream is an output stream for writing data to a File
- //
- OutputStream outputStream = new FileOutputStream(file);
- writeDOMtoStream(doc, outputStream);
- outputStream.flush();
- outputStream.close();
- } catch (Exception fnfe) {
- MylarPlugin.log(fnfe, "Tasklist could not be found");
- }
- }
-
- /**
- * Writes the provided XML document out to the specified output stream.
- *
- * doc - the document to be written
- * outputStream - the stream to which the document is to be written
- */
- private static void writeDOMtoStream(Document doc, OutputStream outputStream) {
- // Prepare the DOM document for writing
- // DOMSource - Acts as a holder for a transformation Source tree in the
- // form of a Document Object Model (DOM) tree
- //
- Source source = new DOMSource(doc);
-
- // StreamResult - Acts as an holder for a XML transformation result
- // Prepare the output stream
- //
- Result result = new StreamResult(outputStream);
-
- // An instance of this class can be obtained with the
- // TransformerFactory.newTransformer method. This instance may
- // then be used to process XML from a variety of sources and write
- // the transformation output to a variety of sinks
- //
-
- Transformer xformer = null;
- try {
- xformer = TransformerFactory.newInstance().newTransformer();
- //Transform the XML Source to a Result
- //
- xformer.transform(source, result);
- } catch (TransformerConfigurationException e) {
- e.printStackTrace();
- } catch (TransformerFactoryConfigurationError e) {
- e.printStackTrace();
- } catch (TransformerException e1) {
- e1.printStackTrace();
- }
- }
-
-// /**
-// * Method deprecated until subtasks are introduced again.
-// * @param t
-// * @param doc
-// * @param root
-// */
-// private static void writeTaskAndSubTasks(ITask t, Document doc, Element root) {
-//
-// // create node and set attributes
-// //
-// Element node = doc.createElement("Task");
-// node.setAttribute("Path", t.getPath());
-// node.setAttribute("Label", t.getLabel());
-// node.setAttribute("Handle", t.getHandle());
-// node.setAttribute("Priority", t.getPriority());
-//
-// if (t.isCategory()) {
-// node.setAttribute("IsCategory", "true");
-// } else {
-// node.setAttribute("IsCategory", "false");
-// }
-// if (t.isCompleted()) {
-// node.setAttribute("Complete", "true");
-// } else {
-// node.setAttribute("Complete", "false");
-// }
-// if (t.isActive()) {
-// node.setAttribute("Active", "true");
-// } else {
-// node.setAttribute("Active", "false");
-// }
-// if (t instanceof BugzillaTask) {
-// BugzillaTask bt = (BugzillaTask) t;
-// node.setAttribute("Bugzilla", "true");
-// node.setAttribute("LastDate", new Long(bt.getLastRefreshTime()
-// .getTime()).toString());
-// if (bt.isDirty()) {
-// node.setAttribute("Dirty", "true");
-// } else {
-// node.setAttribute("Dirty", "false");
-// }
-// bt.saveBugReport(false);
-// } else {
-// node.setAttribute("Bugzilla", "false");
-// }
-// node.setAttribute("Notes", t.getNotes());
-// node.setAttribute("Elapsed", t.getElapsedTime());
-// node.setAttribute("Estimated", t.getEstimatedTime());
-// List<String> rl = t.getRelatedLinks().getLinks();
-// int i = 0;
-// for (String link : rl) {
-// node.setAttribute("link"+i, link);
-// i++;
-// }
-//
-// List<ITask> children = t.getChildren();
-//
-// i = 0;
-// for (i = 0; i < children.size(); i++) {
-// writeTaskAndSubTasks(children.get(i), doc, node);
-// }
-//
-// // append new node to root node
-// //
-// root.appendChild(node);
-// return;
-// }
-
- private static void writeTaskCategory(TaskCategory cat, Document doc, Element parent) {
- Element node = doc.createElement("TaskCategory");
- node.setAttribute("Name", cat.getDescription(false));
-
- for (ITask t : cat.getChildren()) {
- writeTask(t, doc, node);
- }
- parent.appendChild(node);
- }
-
- private static void writeQueryCategory(BugzillaQueryCategory cat, Document doc, Element parent) {
- Element node = doc.createElement("QueryCategory");
- node.setAttribute("Description", cat.getDescription(false));
- node.setAttribute("URL", cat.getUrl());
- parent.appendChild(node);
- }
-
- private static void writeTask(ITask task, Document doc, Element parent) {
- Element node = doc.createElement("Task");
- node.setAttribute("Path", task.getPath());
- node.setAttribute("Label", task.getLabel());
- node.setAttribute("Handle", task.getHandle());
- node.setAttribute("Priority", task.getPriority());
-
- if (task.isCompleted()) {
- node.setAttribute("Complete", "true");
- } else {
- node.setAttribute("Complete", "false");
- }
- if (task.isActive()) {
- node.setAttribute("Active", "true");
- } else {
- node.setAttribute("Active", "false");
- }
- if (task instanceof BugzillaTask) {
- BugzillaTask bt = (BugzillaTask) task;
- node.setAttribute("Bugzilla", "true");
- node.setAttribute("LastDate", new Long(bt.getLastRefreshTime()
- .getTime()).toString());
- if (bt.isDirty()) {
- node.setAttribute("Dirty", "true");
- } else {
- node.setAttribute("Dirty", "false");
- }
- bt.saveBugReport(false);
- } else {
- node.setAttribute("Bugzilla", "false");
- }
- node.setAttribute("Notes", task.getNotes());
- node.setAttribute("Elapsed", task.getElapsedTime());
- node.setAttribute("Estimated", task.getEstimatedTime());
- List<String> rl = task.getRelatedLinks().getLinks();
- int i = 0;
- for (String link : rl) {
- node.setAttribute("link"+i, link);
- i++;
- }
-
- for (ITask t : task.getChildren()) {
- writeTask(t, doc, node);
- }
- parent.appendChild(node);
- return;
- }
-
- public static void readTaskList(TaskList tlist, File inFile) {
- try {
- // parse file
- //
- Document doc = openAsDOM(inFile);
-
- // read root node to get version number
- //
- Element root = doc.getDocumentElement();
- readVersion = root.getAttribute("Version");
-
- if (readVersion.equals("1.0.0")) {
- NodeList list = root.getChildNodes();
- for (int i = 0; i < list.getLength(); i++) {
- Node child = list.item(i);
- readTasksToNewFormat(child, tlist);
- //tlist.addRootTask(readTaskAndSubTasks(child, null, tlist));
- }
- } else {
- NodeList list = root.getChildNodes();
- for (int i = 0; i < list.getLength(); i++) {
- Node child = list.item(i);
- if (child.getNodeName().equals("Category") ||
- child.getNodeName().equals("TaskCategory")) {
- readTaskCategory(child, tlist);
- } else if (child.getNodeName().equals("BugzillaTaskRegistry")) {
- readBugzillaRegistry(child, tlist);
- } else if (child.getNodeName().equals("QueryCategory")) {
- readQueryCategory(child, tlist);
- } else {
- tlist.addRootTask(readTask(child, tlist, null, null));
- }
- }
- }
- } catch (Exception e) {
- String name = inFile.getAbsolutePath();
- name = name.substring(0, name.lastIndexOf('.')) + "-save.xml";
- inFile.renameTo(new File(name));
- MylarPlugin.log(e, "XmlUtil");
- }
- }
-
- private static void readBugzillaRegistry(Node node, TaskList tlist) {
- NodeList list = node.getChildNodes();
- for (int i = 0; i < list.getLength(); i++) {
- Node child = list.item(i);
- ITask task = readTask(child, tlist, null, null);
- if(task instanceof BugzillaTask){
- tlist.addToBugzillaTaskRegistry((BugzillaTask)task);
- }
- }
- }
-
- /**
- * Opens the specified XML file and parses it into a DOM Document.
- *
- * Filename - the name of the file to open
- * Return - the Document built from the XML file
- * Throws - XMLException if the file cannot be parsed as XML
- * - IOException if the file cannot be opened
- */
- private static Document openAsDOM(File inputFile) throws IOException {
-
- // A factory API that enables applications to obtain a parser
- // that produces DOM object trees from XML documents
- //
- DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
-
- // Using DocumentBuilder, obtain a Document from XML file.
- //
- DocumentBuilder builder = null;
- Document document = null;
- try {
- // create new instance of DocumentBuilder
- //
- builder = factory.newDocumentBuilder();
- } catch (ParserConfigurationException pce) {
- inputFile.renameTo(new File(inputFile.getName() + "save.xml"));
- MylarPlugin.log(pce, "Failed to load XML file");
- }
- try {
- // Parse the content of the given file as an XML document
- // and return a new DOM Document object. Also throws IOException
- document = builder.parse(inputFile);
- } catch (SAXException se) {
- inputFile.renameTo(new File(inputFile.getName() + "save.xml"));
- MylarPlugin.log(se, "Failed to parse XML file");
- }
- return document;
- }
-
-// private static ITask readTaskAndSubTasks(Node node, ITask root, TaskList tlist) {
-// //extract node and create new sub task
-// //
-// Element e = (Element) node;
-// ITask t;
-// String handle = "";
-// if (e.hasAttribute("ID")) {
-// handle = e.getAttribute("ID");
-// } else {
-// handle = e.getAttribute("Handle");
-// }
-//
-// String label = e.getAttribute("Label");
-// String priority = e.getAttribute("Priority");
-//
-// if (e.getAttribute("Bugzilla").compareTo("true") == 0) {
-// t = new BugzillaTask(handle, label, true);
-// BugzillaTask bt = (BugzillaTask) t;
-// bt.setState(BugTaskState.FREE);
-// bt.setLastRefresh(new Date(new Long(e.getAttribute("LastDate"))
-// .longValue()));
-// if (e.getAttribute("Dirty").compareTo("true") == 0) {
-// bt.setDirty(true);
-// } else {
-// bt.setDirty(false);
-// }
-// if (bt.readBugReport() == false) {
-// MylarPlugin.log("Failed to read bug report", null);
-// }
-// } else {
-// t = new Task(handle, label);
-// }
-// t.setPriority(priority);
-// t.setPath(e.getAttribute("Path"));
-//
-// if (e.getAttribute("Active").compareTo("true") == 0) {
-// t.setActive(true);
-// tlist.setActive(t, true);
-// } else {
-// t.setActive(false);
-// }
-//
-// if (e.getAttribute("Complete").compareTo("true") == 0) {
-// t.setCompleted(true);
-// } else {
-// t.setCompleted(false);
-// }
-// if (e.getAttribute("IsCategory").compareTo("true") == 0) {
-// t.setIsCategory(true);
-// } else {
-// t.setIsCategory(false);
-// }
-//
-// if (e.hasAttribute("Notes")) {
-// t.setNotes(e.getAttribute("Notes"));
-// } else {
-// t.setNotes("");
-// }
-// if (e.hasAttribute("Elapsed")) {
-// t.setElapsedTime(e.getAttribute("Elapsed"));
-// } else {
-// t.setElapsedTime("");
-// }
-// if (e.hasAttribute("Estimated")) {
-// t.setEstimatedTime(e.getAttribute("Estimated"));
-// } else {
-// t.setEstimatedTime("");
-// }
-//
-// int i = 0;
-// while (e.hasAttribute("link"+i)) {
-// t.getRelatedLinks().add(e.getAttribute("link"+i));
-// i++;
-// }
-//
-// if (!readVersion.equals("1.0.0")) {
-// // for newer revisions
-// }
-//
-// i = 0;
-// NodeList list = e.getChildNodes();
-// for (i = 0; i < list.getLength(); i++) {
-// Node child = list.item(i);
-// t.addSubTask(readTaskAndSubTasks(child, t, tlist));
-// }
-// if (root != null) {
-// t.setParent(root);
-// }
-// return t;
-// }
-
- private static void readTaskCategory(Node node, TaskList tlist) {
- Element e = (Element) node;
- TaskCategory cat = new TaskCategory(e.getAttribute("Name"));
- tlist.addCategory(cat);
- NodeList list = node.getChildNodes();
- for (int i = 0; i < list.getLength(); i++) {
- Node child = list.item(i);
- cat.addTask(readTask(child, tlist, cat, null));
- }
- }
-
- private static void readQueryCategory(Node node, TaskList tlist) {
- Element e = (Element) node;
- BugzillaQueryCategory cat = new BugzillaQueryCategory(e.getAttribute("Description"), e.getAttribute("URL"));
- tlist.addCategory(cat);
- }
-
- private static ITask readTask(Node node, TaskList tlist, TaskCategory cat, ITask parent) {
- Element e = (Element) node;
- ITask t;
- String handle = e.getAttribute("Handle");
- String label = e.getAttribute("Label");
- String priority = e.getAttribute("Priority");
-
- if (e.getAttribute("Bugzilla").compareTo("true") == 0) {
- t = new BugzillaTask(handle, label, true);
- BugzillaTask bt = (BugzillaTask) t;
- bt.setState(BugTaskState.FREE);
- bt.setLastRefresh(new Date(new Long(e.getAttribute("LastDate"))
- .longValue()));
- if (e.getAttribute("Dirty").compareTo("true") == 0) {
- bt.setDirty(true);
- } else {
- bt.setDirty(false);
- }
- if (bt.readBugReport() == false) {
- MylarPlugin.log("Failed to read bug report", null);
- }
- } else {
- t = new Task(handle, label);
- }
- t.setPriority(priority);
- t.setPath(e.getAttribute("Path"));
-
- if (e.getAttribute("Active").compareTo("true") == 0) {
- t.setActive(true);
- tlist.setActive(t, true);
- } else {
- t.setActive(false);
- }
- if (e.getAttribute("Complete").compareTo("true") == 0) {
- t.setCompleted(true);
- } else {
- t.setCompleted(false);
- }
- if (e.hasAttribute("Notes")) {
- t.setNotes(e.getAttribute("Notes"));
- } else {
- t.setNotes("");
- }
- if (e.hasAttribute("Elapsed")) {
- t.setElapsedTime(e.getAttribute("Elapsed"));
- } else {
- t.setElapsedTime("");
- }
- if (e.hasAttribute("Estimated")) {
- t.setEstimatedTime(e.getAttribute("Estimated"));
- } else {
- t.setEstimatedTime("");
- }
-
- int i = 0;
- while (e.hasAttribute("link"+i)) {
- t.getRelatedLinks().add(e.getAttribute("link"+i));
- i++;
- }
- t.setCategory(cat);
- t.setParent(parent);
- NodeList list = e.getChildNodes();
- for (i = 0; i < list.getLength(); i++) {
- Node child = list.item(i);
- t.addSubTask(readTask(child, tlist, null, t));
- }
- return t;
- }
-
- private static void readTasksToNewFormat(Node node, TaskList tlist) {
- Element e = (Element) node;
- ITask t;
- String handle = e.getAttribute("Handle");
- String label = e.getAttribute("Label");
-
- if (e.getAttribute("IsCategory").compareTo("true") == 0) {
- TaskCategory c = new TaskCategory(label);
- NodeList list = e.getChildNodes();
- for (int i = 0; i < list.getLength(); i++) {
- Node child = list.item(i);
- readSubTasksToNewFormat(child, tlist, c);
- }
- tlist.addCategory(c);
- } else {
- String priority = e.getAttribute("Priority");
- if (e.getAttribute("Bugzilla").compareTo("true") == 0) {
- t = new BugzillaTask(handle, label, true);
- BugzillaTask bt = (BugzillaTask) t;
- bt.setState(BugTaskState.FREE);
- bt.setLastRefresh(new Date(new Long(e.getAttribute("LastDate"))
- .longValue()));
- if (e.getAttribute("Dirty").compareTo("true") == 0) {
- bt.setDirty(true);
- } else {
- bt.setDirty(false);
- }
- if (bt.readBugReport() == false) {
- MylarPlugin.log("Failed to read bug report", null);
- }
- } else {
- t = new Task(handle, label);
- }
- t.setPriority(priority);
- t.setPath(e.getAttribute("Path"));
- t.setNotes(e.getAttribute("Notes"));
- t.setElapsedTime(e.getAttribute("Elapsed"));
- t.setEstimatedTime(e.getAttribute("Estimated"));
-
- if (e.getAttribute("Active").compareTo("true") == 0) {
- t.setActive(true);
- tlist.setActive(t, true);
- } else {
- t.setActive(false);
- }
- if (e.getAttribute("Complete").compareTo("true") == 0) {
- t.setCompleted(true);
- } else {
- t.setCompleted(false);
- }
-
- int i = 0;
- while (e.hasAttribute("link" + i)) {
- t.getRelatedLinks().add(e.getAttribute("link" + i));
- i++;
- }
- tlist.addRootTask(t);
- i = 0;
- NodeList list = e.getChildNodes();
- for (i = 0; i < list.getLength(); i++) {
- Node child = list.item(i);
- readSubTasksToNewFormat(child, tlist, null);
- }
- }
- }
- private static void readSubTasksToNewFormat(Node node, TaskList tlist, TaskCategory cat) {
- Element e = (Element) node;
- ITask t;
- String handle = e.getAttribute("Handle");
- String label = e.getAttribute("Label");
- String priority = e.getAttribute("Priority");
- if (e.getAttribute("Bugzilla").compareTo("true") == 0) {
- t = new BugzillaTask(handle, label, true);
- BugzillaTask bt = (BugzillaTask) t;
- bt.setState(BugTaskState.FREE);
- bt.setLastRefresh(new Date(new Long(e.getAttribute("LastDate"))
- .longValue()));
- if (e.getAttribute("Dirty").compareTo("true") == 0) {
- bt.setDirty(true);
- } else {
- bt.setDirty(false);
- }
- if (bt.readBugReport() == false) {
- MylarPlugin.log("Failed to read bug report", null);
- }
- } else {
- t = new Task(handle, label);
- }
- t.setPriority(priority);
- t.setPath(e.getAttribute("Path"));
- t.setNotes(e.getAttribute("Notes"));
- t.setElapsedTime(e.getAttribute("Elapsed"));
- t.setEstimatedTime(e.getAttribute("Estimated"));
-
- if (e.getAttribute("Active").compareTo("true") == 0) {
- t.setActive(true);
- tlist.setActive(t, true);
- } else {
- t.setActive(false);
- }
- if (e.getAttribute("Complete").compareTo("true") == 0) {
- t.setCompleted(true);
- } else {
- t.setCompleted(false);
- }
-
- int i = 0;
- while (e.hasAttribute("link" + i)) {
- t.getRelatedLinks().add(e.getAttribute("link" + i));
- i++;
- }
- if (cat == null) {
- tlist.addRootTask(t);
- } else {
- cat.addTask(t);
- t.setCategory(cat);
- }
-
- i = 0;
- NodeList list = e.getChildNodes();
- for (i = 0; i < list.getLength(); i++) {
- Node child = list.item(i);
- readSubTasksToNewFormat(child, tlist, cat);
- }
- }
-}
-

Back to the top