Switching files resets currently focused location
Categories
(DevTools :: Debugger, defect, P3)
Tracking
(firefox69 fixed)
Tracking | Status | |
---|---|---|
firefox69 | --- | fixed |
People
(Reporter: Harald, Assigned: davidwalsh)
References
(Blocks 1 open bug)
Details
(Whiteboard: [debugger-mvp])
Attachments
(1 file)
What were you doing?
- Open a source #a in debugger and scroll down and to the right, setting a cursor somewhere in a longer line.
- Open another source #b.
- Navigate back to source #a
Alternative
- Pause in source #a
- Switch from #b to #a
What happened?
Source #a always opens scrolled to the top.
When paused the first line in source #a gets an animation highlight for no reason.
What should have happened?
Remember the current scroll and cursor position.
Comment 1•5 years ago
|
||
I believe this is similar to https://github.com/firefox-devtools/debugger/issues/7951
[Tabs] selecting a tab should return to the prior location #7951
Comment 2•5 years ago
|
||
I and David proposed a couple of solutions but David said they weren't elegant enough.
My PR: https://github.com/firefox-devtools/debugger/pull/8076
David's PR: https://github.com/firefox-devtools/debugger/pull/8102
Can you recommend a better approach ?
Updated•5 years ago
|
Comment 3•5 years ago
|
||
Sorry Dhyey, it's been awhile and I've forgotten. I think my thinking was we should be able to have a field selectedSource
in the reducer that we set if that is you select a tab. At that point the editor would update, but we would not try and scroll.
Updated•5 years ago
|
Assignee | ||
Comment 4•5 years ago
|
||
Ensures scroll position stays the same between tab switches while paused and not paused.
Updated•5 years ago
|
Pushed by dwalsh@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/8f96077d464a Keep scrolling location for individual documents r=jlast
Comment 7•5 years ago
|
||
bugherder |
Description
•