Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 255923 - activating a newly created task switches to Java perspective
Summary: activating a newly created task switches to Java perspective
Status: RESOLVED FIXED
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: Mylyn (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows XP
: P3 minor (vote)
Target Milestone: 3.7   Edit
Assignee: Steffen Pingel CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 226618
  Show dependency tree
 
Reported: 2008-11-20 03:32 EST by Raphael Ackermann CLA
Modified: 2012-02-23 21:45 EST (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Raphael Ackermann CLA 2008-11-20 03:32:25 EST
1. Open a perspective other then the Java perspective. 
2. Show the Task List view and activate or deactivate a task. 
3. Observe an automatic switch of the perspective to the default java perspective.

I don't think that I have been asked whether I always want to switch to the java perspective when clicking. 

This is especially annoying when using a "java" perspective but saved as a custom perspective.

Expected outcome would be that mylyn doesn't change the perspective of the user.
Comment 1 Steffen Pingel CLA 2008-11-20 05:46:04 EST
Raphael, please check if you have enabled Tasks > Context > Open last used perspective on task activation in the Eclipse Preferences.
Comment 2 Raphael Ackermann CLA 2008-11-20 10:40:39 EST
(In reply to comment #1)
> Raphael, please check if you have enabled Tasks > Context > Open last used
> perspective on task activation in the Eclipse Preferences.
> 

That's it. Had it checked. That also explains why it didn't happen with all the tasks that I activated. Thanks for the quick response.
Comment 3 Raphael Ackermann CLA 2008-11-21 04:38:34 EST
There is still a bug. 

If I create a task in my custom perspective and activate it, the perspective is switched to the Java perspective. This might make sense if the perspective is e.g. the synchronize cvs perspective, but not if I use a java custom perspective. (e.g I have two java perspectives, the default one and my custom one) and activating the task should not switch away from the custom java perspective).
Comment 4 Steffen Pingel CLA 2008-11-21 05:01:47 EST
Mylyn should switch to the perspective active when the task was last deactivated. If that does not work, please provide further information how to reproduce the problem.
Comment 5 Raphael Ackermann CLA 2008-11-21 07:42:06 EST
As I tried but failed to explain. When you create a task from scratch (I am talking about local tasks here) in Perspective A and then activate the task for the first time. The Perspective will be changed to the Java Perspective with A != Java.
Comment 6 Steffen Pingel CLA 2008-11-24 06:04:13 EST
Thanks for clarifying. I'll take a look. I don't think that is the intended behavior.
Comment 7 Steffen Pingel CLA 2008-12-22 16:12:33 EST
Mik, this is related to bug 226618, I have added a test case that triggers the bug. 

The information about the last used perspectives is not cleared properly when tasks are deleted. I suspect that a perspective from a previously deleted task is restored when a new task is activated. 
Comment 8 Mik Kersten CLA 2009-01-27 20:25:16 EST
Steffen: Consider for 3.1 along with your other fix.
Comment 9 Shawn Minto CLA 2009-05-01 18:51:30 EDT
It looks like this should be using context activation not task activation which is why it isn't/can't be cleared.
Comment 10 Steffen Pingel CLA 2009-05-28 21:19:01 EDT
Moving to next milestone. Due to time constraints we'll need to postpone bug 226618 which this bug depends on.
Comment 11 Steffen Pingel CLA 2012-02-23 21:45:15 EST
This has been fixed as part of bug 226618. The context state is now properly managed when submitting tasks or deleting (local) tasks.