Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clicking on collapsed debug session stack expands then collapses it immediately #64463

Closed
roblourens opened this issue Dec 5, 2018 · 9 comments
Assignees
Labels
bug Issue identified by VS Code Team member as probable bug debug Debug viewlet, configurations, breakpoints, adapter issues verified Verification succeeded
Milestone

Comments

@roblourens
Copy link
Member

  • Just debugging two normal sessions
  • A is active, B is collapsed
  • Click B, it blinks open then collapses again

I'm guessing it's toggled by the click and by becoming active and they interfere?

dec-05-2018 15-09-01

@isidorn isidorn added the debug Debug viewlet, configurations, breakpoints, adapter issues label Dec 6, 2018
@isidorn isidorn added this to the November 2018 milestone Dec 6, 2018
@isidorn
Copy link
Contributor

isidorn commented Dec 6, 2018

The issue here is the following:
There is a tree navigator, which will react on click -> based on that reaction I will call tree.expand
However while I am doing this the tree plans to toggle expansion because of the click. My expand gets resovled first, which expands the element and than the tree collapses it.

@joaomoreno on advice what best to do here

@isidorn isidorn added the bug Issue identified by VS Code Team member as probable bug label Dec 6, 2018
@joaomoreno
Copy link
Member

There is a tree navigator, which will react on click -> based on that reaction I will call tree.expand

Why are we calling expand there?

@isidorn
Copy link
Contributor

isidorn commented Dec 6, 2018

Because of the way my code is strucutred, whenever a stack frame gets focused I want to expand the session and the thread to show the stack frame.

So what happens here is a weird cycle. Click on sessions, session due to navigator gets focused, because session gets focused we find a stack frame belonging to it and it gets focus and the expand happens

@roblourens
Copy link
Member Author

roblourens commented Dec 6, 2018

The workaround of keeping a flag on the callstack's side is awkward and would be nicer if we could pass some context through the setFocus call in the tree like the old tree allows.

@joaomoreno
Copy link
Member

New tree allows that too.

@isidorn
Copy link
Contributor

isidorn commented Dec 7, 2018

Does not apply in this use case.
But thanks for the advice, however for now I will go with the workaround.

@alexr00 alexr00 added the verified Verification succeeded label Dec 7, 2018
@roblourens
Copy link
Member Author

The browserEvent? https://github.com/Microsoft/vscode/blob/master/src/vs/base/browser/ui/tree/abstractTree.ts#L361 For search, I'm looking for a way to pass some arbitrary flag in, although I could pack it into a fake browser event.

@joaomoreno
Copy link
Member

Yeah the browser event... I'm not too keen on allowing any there. What is the use case exactly for search?

@roblourens
Copy link
Member Author

I opened #64743

@vscodebot vscodebot bot locked and limited conversation to collaborators Jan 20, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Issue identified by VS Code Team member as probable bug debug Debug viewlet, configurations, breakpoints, adapter issues verified Verification succeeded
Projects
None yet
Development

No branches or pull requests

4 participants