Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormkersten2006-01-13 17:50:51 -0500
committermkersten2006-01-13 17:50:51 -0500
commit6bf33904a7af5bf4b37f7458ee2bda4d42fbae1e (patch)
tree146a48a8e9bfbacf254e5b309d4440747c79fda7
parent48883338594ccd2051dd00338c5ff1f426510633 (diff)
downloadorg.eclipse.mylyn.tasks-6bf33904a7af5bf4b37f7458ee2bda4d42fbae1e.tar.gz
org.eclipse.mylyn.tasks-6bf33904a7af5bf4b37f7458ee2bda4d42fbae1e.tar.xz
org.eclipse.mylyn.tasks-6bf33904a7af5bf4b37f7458ee2bda4d42fbae1e.zip
Completed: Bug 123806: create default perspective and shortcut locations
https://bugs.eclipse.org/bugs/show_bug.cgi?id=123806
-rw-r--r--org.eclipse.mylyn.bugzilla.ui/src/org/eclipse/mylyn/bugzilla/ui/actions/CreateBugzillaTaskAction.java6
-rw-r--r--org.eclipse.mylyn.bugzilla.ui/src/org/eclipse/mylyn/bugzilla/ui/actions/CreateNewBugzillaTaskAction.java5
-rw-r--r--org.eclipse.mylyn.tasks.ui/plugin.xml20
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasklist/ui/actions/CreateTaskAction.java3
4 files changed, 32 insertions, 2 deletions
diff --git a/org.eclipse.mylyn.bugzilla.ui/src/org/eclipse/mylyn/bugzilla/ui/actions/CreateBugzillaTaskAction.java b/org.eclipse.mylyn.bugzilla.ui/src/org/eclipse/mylyn/bugzilla/ui/actions/CreateBugzillaTaskAction.java
index c82584db8..0bb0cde97 100644
--- a/org.eclipse.mylyn.bugzilla.ui/src/org/eclipse/mylyn/bugzilla/ui/actions/CreateBugzillaTaskAction.java
+++ b/org.eclipse.mylyn.bugzilla.ui/src/org/eclipse/mylyn/bugzilla/ui/actions/CreateBugzillaTaskAction.java
@@ -15,6 +15,7 @@ import org.eclipse.jface.action.Action;
import org.eclipse.jface.action.IAction;
import org.eclipse.jface.viewers.ISelection;
import org.eclipse.jface.viewers.IStructuredSelection;
+import org.eclipse.jface.viewers.StructuredSelection;
import org.eclipse.mylar.bugzilla.core.BugzillaPlugin;
import org.eclipse.mylar.bugzilla.ui.BugzillaImages;
import org.eclipse.mylar.bugzilla.ui.BugzillaUiPlugin;
@@ -92,8 +93,11 @@ public class CreateBugzillaTaskAction extends Action implements IViewActionDeleg
}
BugzillaUiPlugin.getDefault().getBugzillaTaskListManager().addToBugzillaTaskRegistry((BugzillaTask)newTask);
- if(TaskListView.getDefault() != null)
+ if(TaskListView.getDefault() != null) {
+ // Make this new task the current selection in the view
+ TaskListView.getDefault().getViewer().setSelection(new StructuredSelection(newTask));
TaskListView.getDefault().getViewer().refresh();
+ }
}
public void init(IViewPart view) {
diff --git a/org.eclipse.mylyn.bugzilla.ui/src/org/eclipse/mylyn/bugzilla/ui/actions/CreateNewBugzillaTaskAction.java b/org.eclipse.mylyn.bugzilla.ui/src/org/eclipse/mylyn/bugzilla/ui/actions/CreateNewBugzillaTaskAction.java
index eb3474c42..31a6fd730 100644
--- a/org.eclipse.mylyn.bugzilla.ui/src/org/eclipse/mylyn/bugzilla/ui/actions/CreateNewBugzillaTaskAction.java
+++ b/org.eclipse.mylyn.bugzilla.ui/src/org/eclipse/mylyn/bugzilla/ui/actions/CreateNewBugzillaTaskAction.java
@@ -17,6 +17,7 @@ import org.eclipse.jface.dialogs.Dialog;
import org.eclipse.jface.dialogs.MessageDialog;
import org.eclipse.jface.viewers.ISelection;
import org.eclipse.jface.viewers.IStructuredSelection;
+import org.eclipse.jface.viewers.StructuredSelection;
import org.eclipse.jface.wizard.WizardDialog;
import org.eclipse.mylar.bugzilla.ui.BugzillaUiPlugin;
import org.eclipse.mylar.bugzilla.ui.tasklist.BugzillaTask;
@@ -116,8 +117,10 @@ public class CreateNewBugzillaTaskAction extends Action implements IViewActionDe
if(!newTask.isBugDownloaded())
newTask.scheduleDownloadReport();
- if(TaskListView.getDefault() != null)
+ if(TaskListView.getDefault() != null) {
+ TaskListView.getDefault().getViewer().setSelection(new StructuredSelection(newTask));
TaskListView.getDefault().getViewer().refresh();
+ }
} else {
// TODO handle not good
}
diff --git a/org.eclipse.mylyn.tasks.ui/plugin.xml b/org.eclipse.mylyn.tasks.ui/plugin.xml
index 8220f7dcb..0a6fa6c4b 100644
--- a/org.eclipse.mylyn.tasks.ui/plugin.xml
+++ b/org.eclipse.mylyn.tasks.ui/plugin.xml
@@ -81,6 +81,26 @@
id="org.eclipse.mylar.tasklist.repositories">
</view>
</perspectiveExtension>
+
+ <perspectiveExtension targetID="org.eclipse.team.cvs.ui.cvsPerspective">
+ <view
+ id="org.eclipse.mylar.tasklist.repositories"
+ ratio="0.7"
+ relationship="bottom"
+ relative="org.eclipse.team.ccvs.ui.RepositoriesView"
+ visible="true"/>
+ <viewShortcut id="org.eclipse.mylar.tasklist.repositories"/>
+ </perspectiveExtension>
+ <perspectiveExtension targetID="org.eclipse.team.ui.TeamSynchronizingPerspective">
+ <view
+ id="org.eclipse.mylar.tasklist.repositories"
+ ratio="0.8"
+ relationship="bottom"
+ relative="org.eclipse.team.sync.views.SynchronizeView"
+ visible="true"/>
+ <viewShortcut id="org.eclipse.mylar.tasklist.repositories"/>
+ </perspectiveExtension>
+
</extension>
<extension
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasklist/ui/actions/CreateTaskAction.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasklist/ui/actions/CreateTaskAction.java
index d401a4ae9..d9663577b 100644
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasklist/ui/actions/CreateTaskAction.java
+++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasklist/ui/actions/CreateTaskAction.java
@@ -13,6 +13,7 @@ package org.eclipse.mylar.tasklist.ui.actions;
import org.eclipse.jface.action.Action;
import org.eclipse.jface.viewers.IStructuredSelection;
+import org.eclipse.jface.viewers.StructuredSelection;
import org.eclipse.jface.window.Window;
import org.eclipse.mylar.tasklist.ITask;
import org.eclipse.mylar.tasklist.MylarTaskListPlugin;
@@ -79,6 +80,8 @@ public class CreateTaskAction extends Action {
MylarTaskListPlugin.getTaskListManager().moveToRoot(newTask);
}
newTask.openTaskInEditor(false);
+ // Make this new task the current selection in the view
+ view.getViewer().setSelection(new StructuredSelection(newTask));
view.getViewer().refresh();
}
}

Back to the top