Community
Participate
Working Groups
Some connectors use information on the ITask to determine task kind labels and other information. When a new task is created, there is no way that this can be set to ensure that the UI has the information that it needs on the ITask. There should be some way of being able to updateTaskFromTaskData with new task data before the new task editor is opened.
+1 Shawn, if you make that change please watch for backwards compatibility problems. We may need to introduce another method, e.g. updateNewTaskFromTaskData() if this breaks existing connectors.
I think that we will need to have a new method as many that I know of assume that the task data is not new and has valid values for some task attributes. Also, for new tasks, I would assume that less information would need to be stored on the task than for existing tasks. I will have a look into adding this new API.
Created attachment 186453 [details] patch I think this should do it. Note that there could be other callers of org.eclipse.mylyn.tasks.ui.TasksUiUtil.createOutgoingNewTask(String, String) outside of Mylyn, and they may want to call updateNewTaskFromTaskData() themselves.
Created attachment 186454 [details] mylyn/context/zip
Thanks Sam. Can you merge the new method into AbstractRepositoryConnector and add some documentation and an appropriate @since tag? The default implementation should simply do nothing.
Created attachment 186538 [details] clipboard.txt Modified patch.
Created attachment 186544 [details] clipboard.txt Patch that passes the correct task repository...
Thanks. Patch applied to head.