You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Keep and restore scroll position for readonly documents #22420
debugDebug viewlet, configurations, breakpoints, adapter issuesfeature-requestRequest for new features or functionalityhelp wantedIssues identified as good community contribution opportunitiesverification-neededVerification of issue is requestedverifiedVerification succeeded
Isidor Nikolic (@isidorn) we do it for files and untitled via the saveTextEditorViewState and restoreTextEditorViewState methods that are actually defined in src/vs/workbench/browser/parts/editor/textEditor and we could probably push this down from resourceTextEditor and textFileEditor and just use it from textEditor for any input that has a resource 👍
With #26317 landed, we keep the UI state when you switch editors, though we clear it when you close a tab. The rationale is that the lifecycle of these editors that have virtual resources is not known, as such we assume the view state can be ditched once the editor closes.
debugDebug viewlet, configurations, breakpoints, adapter issuesfeature-requestRequest for new features or functionalityhelp wantedIssues identified as good community contribution opportunitiesverification-neededVerification of issue is requestedverifiedVerification succeeded
Activity
weinand commentedon Mar 29, 2017
This problem is independent from the "Open Loaded Scripts" feature.
To reproduce:
Observe: you loose the scroll position in the internal module
isidorn commentedon Mar 29, 2017
March to investigate
isidorn commentedon Mar 29, 2017
Workbench is not preserving scroll location of in memory resources.
Same is true for diff view.
Forwarding to Benjamin Pasero (@bpasero) since he probably already has an issue for this
5 remaining items
isidorn commentedon Mar 29, 2017
Benjamin Pasero (@bpasero) give me some code pointers for the PR and I can do it in debt week
bpasero commentedon Mar 29, 2017
Isidor Nikolic (@isidorn) we do it for
filesanduntitledvia thesaveTextEditorViewStateandrestoreTextEditorViewStatemethods that are actually defined insrc/vs/workbench/browser/parts/editor/textEditorand we could probably push this down fromresourceTextEditorandtextFileEditorand just use it from textEditor for any input that has a resource 👍isidorn commentedon Mar 29, 2017
Ok, makes sense. Assigning to me and April to look into it
soncodi commentedon May 9, 2017
Related: #26251
bpasero commentedon May 9, 2017
With #26317 landed, we keep the UI state when you switch editors, though we clear it when you close a tab. The rationale is that the lifecycle of these editors that have virtual resources is not known, as such we assume the view state can be ditched once the editor closes.
eamodio commentedon May 9, 2017
That sounds perfect!