Community
Participate
Working Groups
The desired behavior (implemented by default by JDT, CDT, etc) is that if a stack frame is already selected, another thread suspending will NOT change the selection in Debug view. This is also true during launching, when numerous events cause the selection to change. To fix this bug, DSF needs to implement IModelSelectionPolicy.
Created attachment 101714 [details] Implement IModelSelectionPolicy Implementation follows platform's DefaultSelectionPolicy.
Created attachment 101715 [details] Minor correction (+committed) The previous patch was not correct. I forgot to remove a comment.
Thanks Toni, I haven't had time to look at your patch today. I'll review it next week.
Thanks Toni! I applied the patch as is with one minor addition: public ISelection replaceInvalidSelection(ISelection invalidSelection, ISelection newSelection) { if (invalidSelection instanceof ITreeSelection) { ITreeSelection treeSelection = (ITreeSelection)invalidSelection; if (treeSelection.getPaths().length == 1) { TreePath path = treeSelection.getPaths()[0]; return new TreeSelection(path.getParentPath()); } } return newSelection; } We use this change in Wind River Workbench so that if a thread is resumed and a stack frame is selected, the parent element (the thread) is automatically selected. Unfortunately this doesn't work if the parent is also removed. Randy please review.
Looks good. Scary thing is it is starting to make more sense now. Randy
DD 1.1 reelased!