Skip to content

CallStackView attempts to move the active frame to the top#88074

Merged
isidorn merged 1 commit intomicrosoft:masterfrom
mnovakovic:mnovakovic_callstackview
Jan 9, 2020
Merged

CallStackView attempts to move the active frame to the top#88074
isidorn merged 1 commit intomicrosoft:masterfrom
mnovakovic:mnovakovic_callstackview

Conversation

@mnovakovic
Copy link
Contributor

This PR fixes #88073

This is an attempt to fix the above issue.

If the element we're selecting is a StackFrame and it's not on the screen, I attempt to put the associated Thread at the very top of the list view. I don't force it as if the element is already on the screen, it'll scroll if up forcefully, which is not a good UX imo.

I'd appreciate any comments, there is a lot going in the code to render a stack trace, this seemed like an easy and non-invasive way to make this a little more intuitive.

@isidorn
Copy link
Collaborator

isidorn commented Jan 6, 2020

Thanks for submiting this PR.
I agree we could improve this behavior and I think your approach makes sense.

However it might be a bit overly complex to me and I think we can simplify this.
How about that in the reveal you just pass 0.5, that should just reveal the active frame in the middle making it easier to see the rest of the frames. Can you try that out and if it looks good update the PR? Thanks!

@mnovakovic mnovakovic force-pushed the mnovakovic_callstackview branch from 49bd816 to 02b5905 Compare January 6, 2020 20:06
@mnovakovic mnovakovic force-pushed the mnovakovic_callstackview branch from 02b5905 to c9aeb8a Compare January 6, 2020 21:15
@mnovakovic
Copy link
Contributor Author

mnovakovic commented Jan 6, 2020

@isidorn - Did the change you recommended and it's not a bad idea at all. I still only move the element to the middle it is outside of the visible area as otherwise it's forcefully moved there every time you step over or select a frame, which seems a little intrusive.

@mnovakovic
Copy link
Contributor Author

ping, just making sure you haven't forgotten about this :) @isidorn @egamma

@isidorn
Copy link
Collaborator

isidorn commented Jan 9, 2020

Looks good, thanks for this PR. Merging in ☀️

@isidorn isidorn merged commit a98614a into microsoft:master Jan 9, 2020
@isidorn isidorn added this to the January 2020 milestone Jan 9, 2020
@github-actions github-actions bot locked and limited conversation to collaborators Mar 27, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Make StackView scroll to the top when a breakpoint is hit

2 participants