diff options
11 files changed, 27 insertions, 153 deletions
diff --git a/org.eclipse.mylyn.bugzilla.tests/META-INF/MANIFEST.MF b/org.eclipse.mylyn.bugzilla.tests/META-INF/MANIFEST.MF index e7d66efa0..dc6d79389 100644 --- a/org.eclipse.mylyn.bugzilla.tests/META-INF/MANIFEST.MF +++ b/org.eclipse.mylyn.bugzilla.tests/META-INF/MANIFEST.MF @@ -30,7 +30,7 @@ Require-Bundle: org.eclipse.ui, Bundle-ActivationPolicy: lazy Bundle-Vendor: Eclipse.org Bundle-ClassPath: bugzilla-test.jar -Export-Package: org.eclipse.mylyn.bugzilla.deprecated, +Export-Package: org.eclipse.mylyn.bugzilla.deprecated;x-internal:=true, org.eclipse.mylyn.bugzilla.tests;x-internal:=true, org.eclipse.mylyn.bugzilla.tests.headless;x-internal:=true Bundle-RequiredExecutionEnvironment: J2SE-1.5 diff --git a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/deprecated/BugzillaTaskEditor.java b/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/deprecated/BugzillaTaskEditor.java index c8a880165..b3a776be4 100644 --- a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/deprecated/BugzillaTaskEditor.java +++ b/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/deprecated/BugzillaTaskEditor.java @@ -29,9 +29,9 @@ import org.eclipse.jface.text.TextViewer; import org.eclipse.jface.viewers.ILabelProvider; import org.eclipse.jface.window.Window; import org.eclipse.mylyn.commons.core.StatusHandler; +import org.eclipse.mylyn.internal.bugzilla.core.BugzillaAttribute; import org.eclipse.mylyn.internal.bugzilla.core.BugzillaCorePlugin; import org.eclipse.mylyn.internal.bugzilla.core.BugzillaCustomField; -import org.eclipse.mylyn.internal.bugzilla.core.BugzillaAttribute; import org.eclipse.mylyn.internal.bugzilla.core.BugzillaOperation; import org.eclipse.mylyn.internal.bugzilla.core.IBugzillaConstants; import org.eclipse.mylyn.internal.bugzilla.core.RepositoryConfiguration; @@ -87,8 +87,6 @@ public class BugzillaTaskEditor extends AbstractRepositoryTaskEditor { private static final String LABEL_TIME_TRACKING = "Bugzilla Time Tracking"; - private static final String LABEL_CUSTOM_FIELD = "Custom Fields"; - protected Text keywordsText; protected Text estimateText; @@ -317,12 +315,10 @@ public class BugzillaTaskEditor extends AbstractRepositoryTaskEditor { if (taskData == null) { return false; } - String customAttributeKeys[] = { BugzillaAttribute.BUG_FILE_LOC.getKey(), - BugzillaAttribute.DEPENDSON.getKey(), BugzillaAttribute.BLOCKED.getKey(), - BugzillaAttribute.KEYWORDS.getKey(), BugzillaAttribute.VOTES.getKey(), - BugzillaAttribute.REPORTER_ACCESSIBLE.getKey(), - BugzillaAttribute.CCLIST_ACCESSIBLE.getKey(), - BugzillaAttribute.ESTIMATED_TIME.getKey(), + String customAttributeKeys[] = { BugzillaAttribute.BUG_FILE_LOC.getKey(), BugzillaAttribute.DEPENDSON.getKey(), + BugzillaAttribute.BLOCKED.getKey(), BugzillaAttribute.KEYWORDS.getKey(), + BugzillaAttribute.VOTES.getKey(), BugzillaAttribute.REPORTER_ACCESSIBLE.getKey(), + BugzillaAttribute.CCLIST_ACCESSIBLE.getKey(), BugzillaAttribute.ESTIMATED_TIME.getKey(), BugzillaAttribute.REMAINING_TIME.getKey(), BugzillaAttribute.ACTUAL_TIME.getKey(), BugzillaAttribute.DEADLINE.getKey(), BugzillaAttribute.STATUS_WHITEBOARD.getKey() }; for (String key : customAttributeKeys) { diff --git a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/deprecated/BugzillaTaskEditorInput.java b/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/deprecated/BugzillaTaskEditorInput.java index f00bc7c20..4d39507f4 100644 --- a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/deprecated/BugzillaTaskEditorInput.java +++ b/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/deprecated/BugzillaTaskEditorInput.java @@ -10,12 +10,8 @@ */ package org.eclipse.mylyn.bugzilla.deprecated; -import org.eclipse.core.runtime.NullProgressMonitor; -import org.eclipse.mylyn.internal.bugzilla.core.BugzillaCorePlugin; -import org.eclipse.mylyn.internal.bugzilla.core.RepositoryConfiguration; import org.eclipse.mylyn.internal.tasks.ui.deprecated.RepositoryTaskEditorInput; import org.eclipse.mylyn.tasks.core.TaskRepository; -import org.eclipse.mylyn.tasks.core.data.TaskData; import org.eclipse.ui.IPersistableElement; /** @@ -69,15 +65,15 @@ public class BugzillaTaskEditorInput extends RepositoryTaskEditorInput { return bugTask; } - private void updateOptions(TaskData taskData) { - try { - if (taskData != null) { - RepositoryConfiguration config = BugzillaCorePlugin.getRepositoryConfiguration(repository, false, - new NullProgressMonitor()); - config.updateAttributeOptions(taskData); - } - } catch (Exception e) { - // ignore - } - } +// private void updateOptions(TaskData taskData) { +// try { +// if (taskData != null) { +// RepositoryConfiguration config = BugzillaCorePlugin.getRepositoryConfiguration(repository, false, +// new NullProgressMonitor()); +// config.updateAttributeOptions(taskData); +// } +// } catch (Exception e) { +// // ignore +// } +// } } diff --git a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/tests/BugzillaRepositoryConnectorTest2.java b/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/tests/BugzillaRepositoryConnectorTest2.java index 2044de22a..2fd3ec43f 100644 --- a/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/tests/BugzillaRepositoryConnectorTest2.java +++ b/org.eclipse.mylyn.bugzilla.tests/src/org/eclipse/mylyn/bugzilla/tests/BugzillaRepositoryConnectorTest2.java @@ -53,10 +53,10 @@ public class BugzillaRepositoryConnectorTest2 extends AbstractBugzillaTest { assertNotNull(taskData); assertEquals(SynchronizationState.SYNCHRONIZED, task.getSynchronizationState()); assertEquals(taskNumber, taskData.getTaskId()); - int numAttached = taskData.getAttributeMapper() - .getAttributesByType(taskData, TaskAttribute.TYPE_ATTACHMENT) - .size(); - String fileName = "test-attach-" + System.currentTimeMillis() + ".txt"; +// int numAttached = taskData.getAttributeMapper() +// .getAttributesByType(taskData, TaskAttribute.TYPE_ATTACHMENT) +// .size(); +// String fileName = "test-attach-" + System.currentTimeMillis() + ".txt"; assertNotNull(repository.getUserName()); assertNotNull(repository.getPassword()); @@ -252,9 +252,9 @@ public class BugzillaRepositoryConnectorTest2 extends AbstractBugzillaTest { TaskData taskData = model.getTaskData(); assertNotNull(taskData); - int numComments = taskData.getAttributeMapper() - .getAttributesByType(taskData, TaskAttribute.TYPE_ATTACHMENT) - .size(); +// int numComments = taskData.getAttributeMapper() +// .getAttributesByType(taskData, TaskAttribute.TYPE_ATTACHMENT) +// .size(); // Modify it String newCommentText = "BugzillaRepositoryClientTest.testSynchronize(): " + (new Date()).toString(); diff --git a/org.eclipse.mylyn.tasks.tests/plugin.xml b/org.eclipse.mylyn.tasks.tests/plugin.xml index 490968b7d..07dd3f98a 100644 --- a/org.eclipse.mylyn.tasks.tests/plugin.xml +++ b/org.eclipse.mylyn.tasks.tests/plugin.xml @@ -6,15 +6,10 @@ id="org.eclipse.mylyn.jira.repository" name="JIRA Repository" point="org.eclipse.mylyn.tasks.ui.repositories"> - <connectorCore class="org.eclipse.mylyn.tasks.tests.connector.MockRepositoryConnector" id="org.eclipse.mylyn.tasks.tests.repositories" name="Mock Repository Client"/> - - <taskListFactory - class="org.eclipse.mylyn.tasks.tests.connector.MockTaskListFactory" - id="org.eclipse.mylyn.tasks.tests.factory"/> <connectorUi class="org.eclipse.mylyn.tasks.tests.connector.MockRepositoryConnectorUi" id="org.eclipse.mylyn.tasks.tests.repositories.ui" diff --git a/org.eclipse.mylyn.tasks.ui/schema/editors.exsd b/org.eclipse.mylyn.tasks.ui/schema/editors.exsd index 82bf34021..9bef9fa71 100644 --- a/org.eclipse.mylyn.tasks.ui/schema/editors.exsd +++ b/org.eclipse.mylyn.tasks.ui/schema/editors.exsd @@ -18,7 +18,6 @@ </annotation> <complexType> <sequence> - <element ref="editorFactory" minOccurs="0" maxOccurs="unbounded"/> <element ref="pageFactory" minOccurs="0" maxOccurs="unbounded"/> </sequence> <attribute name="point" type="string" use="required"> @@ -48,33 +47,6 @@ </complexType> </element> - <element name="editorFactory"> - <annotation> - <appinfo> - <meta.element deprecated="true"/> - </appinfo> - </annotation> - <complexType> - <attribute name="id" type="string"> - <annotation> - <documentation> - - </documentation> - </annotation> - </attribute> - <attribute name="class" type="string" use="required"> - <annotation> - <documentation> - - </documentation> - <appinfo> - <meta.attribute kind="java" basedOn="org.eclipse.mylyn.tasks.ui.editors.AbstractTaskEditorFactory:"/> - </appinfo> - </annotation> - </attribute> - </complexType> - </element> - <element name="pageFactory"> <complexType> <attribute name="id" type="string" use="required"> diff --git a/org.eclipse.mylyn.tasks.ui/schema/repositories.exsd b/org.eclipse.mylyn.tasks.ui/schema/repositories.exsd index b44928ea3..c47d613a1 100644 --- a/org.eclipse.mylyn.tasks.ui/schema/repositories.exsd +++ b/org.eclipse.mylyn.tasks.ui/schema/repositories.exsd @@ -23,7 +23,6 @@ <sequence> <element ref="connectorCore"/> <element ref="connectorUi" minOccurs="0" maxOccurs="1"/> - <element ref="taskListFactory" minOccurs="0" maxOccurs="1"/> <element ref="taskListMigrator" minOccurs="0" maxOccurs="1"/> </sequence> <attribute name="point" type="string" use="required"> @@ -53,46 +52,6 @@ </complexType> </element> - <element name="taskListFactory"> - <annotation> - <appinfo> - <meta.element labelAttribute="name" deprecated="true"/> - </appinfo> - <documentation> - (no description available) - </documentation> - </annotation> - <complexType> - <attribute name="class" type="string" use="required"> - <annotation> - <documentation> - - </documentation> - <appinfo> - <meta.attribute kind="java" basedOn="org.eclipse.mylyn.tasks.core.AbstractTaskListFactory:"/> - </appinfo> - </annotation> - </attribute> - <attribute name="id" type="string"> - <annotation> - <documentation> - - </documentation> - </annotation> - </attribute> - <attribute name="name" type="string"> - <annotation> - <documentation> - - </documentation> - <appinfo> - <meta.attribute translatable="true"/> - </appinfo> - </annotation> - </attribute> - </complexType> - </element> - <element name="taskListMigrator"> <annotation> <appinfo> diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/TasksUiPlugin.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/TasksUiPlugin.java index 9ffd4b1c6..f98a88631 100644 --- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/TasksUiPlugin.java +++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/TasksUiPlugin.java @@ -43,7 +43,6 @@ import org.eclipse.jface.dialogs.MessageDialog; import org.eclipse.jface.operation.IRunnableWithProgress; import org.eclipse.jface.preference.IPreferenceStore; import org.eclipse.jface.resource.ImageDescriptor; -import org.eclipse.jface.text.hyperlink.IHyperlinkDetector; import org.eclipse.jface.util.SafeRunnable; import org.eclipse.mylyn.commons.core.CoreUtil; import org.eclipse.mylyn.commons.core.StatusHandler; @@ -161,12 +160,11 @@ public class TasksUiPlugin extends AbstractUIPlugin { private RepositoryTemplateManager repositoryTemplateManager; + @Deprecated private final Set<AbstractTaskEditorFactory> taskEditorFactories = new HashSet<AbstractTaskEditorFactory>(); private final Set<AbstractTaskEditorPageFactory> taskEditorPageFactories = new HashSet<AbstractTaskEditorPageFactory>(); - private final Set<IHyperlinkDetector> hyperlinkDetectors = new HashSet<IHyperlinkDetector>(); - private final TreeSet<AbstractTaskRepositoryLinkProvider> repositoryLinkProviders = new TreeSet<AbstractTaskRepositoryLinkProvider>( new OrderComparator()); diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/deprecated/CopyAttachmentToClipboardJob.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/deprecated/CopyAttachmentToClipboardJob.java index b3240b8ab..f189ab9bf 100644 --- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/deprecated/CopyAttachmentToClipboardJob.java +++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/deprecated/CopyAttachmentToClipboardJob.java @@ -31,6 +31,7 @@ import org.eclipse.ui.PlatformUI; /** * @author Steffen Pingel */ +@Deprecated public class CopyAttachmentToClipboardJob extends Job { private final RepositoryAttachment attachment; diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/deprecated/DownloadAttachmentJob.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/deprecated/DownloadAttachmentJob.java index 787f2d6f4..0ebd3ec34 100644 --- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/deprecated/DownloadAttachmentJob.java +++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/deprecated/DownloadAttachmentJob.java @@ -31,6 +31,7 @@ import org.eclipse.mylyn.tasks.ui.TasksUi; /** * @author Steffen Pingel */ +@Deprecated public class DownloadAttachmentJob extends Job { private static final int BUFFER_SIZE = 1024; diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/editors/TaskEditor.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/editors/TaskEditor.java index 385e8ae46..82a9783c5 100644 --- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/editors/TaskEditor.java +++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/editors/TaskEditor.java @@ -674,48 +674,4 @@ public class TaskEditor extends SharedHeaderFormEditor { } } - @Override - protected void pageChange(int newPageIndex) { - // fix for windows handles - int oldPageIndex = getCurrentPage(); - if (oldPageIndex != -1 && pages.size() > oldPageIndex && pages.get(oldPageIndex) instanceof IFormPage - && oldPageIndex != newPageIndex) { - // Check the old page - IFormPage oldFormPage = (IFormPage) pages.get(oldPageIndex); - if (oldFormPage.canLeaveThePage() == false) { - setActivePage(oldPageIndex); - return; - } - } - // Now is the absolute last moment to create the page control. - Object page = pages.get(newPageIndex); - if (page instanceof IFormPage) { - IFormPage fpage = (IFormPage) page; - if (fpage.getPartControl() == null) { - fpage.createPartControl(getContainer()); - setControl(newPageIndex, fpage.getPartControl()); - fpage.getPartControl().setMenu(getContainer().getMenu()); - } - } - if (oldPageIndex != -1 && pages.size() > oldPageIndex && pages.get(oldPageIndex) instanceof IFormPage) { - // Commit old page before activating the new one - IFormPage oldFormPage = (IFormPage) pages.get(oldPageIndex); - IManagedForm mform = oldFormPage.getManagedForm(); - if (mform != null) { - mform.commit(false); - } - } - if (pages.size() > newPageIndex && pages.get(newPageIndex) instanceof IFormPage) { - ((IFormPage) pages.get(newPageIndex)).setActive(true); - } - if (oldPageIndex != -1 && pages.size() > oldPageIndex && newPageIndex != oldPageIndex - && pages.get(oldPageIndex) instanceof IFormPage) { - ((IFormPage) pages.get(oldPageIndex)).setActive(false); - } - // Call super - this will cause pages to switch - //setActivePage(newPageIndex); -// IFormPage newPage = getActivePageInstance(); -// if (newPage != null) -// firePageChanged(new PageChangedEvent(this, newPage)); - } } |