Fix scroll position restoration (#42088)

Follow-up of https://github.com/zed-industries/zed/pull/42035
Scroll position needs to be stored immediately, otherwise editor close
may not register that.

Release Notes:

- N/A
149eedb73dKirill Bulatov committed on 11/6/2025, 11:37:27 AM· committed by GitHubparentfb46bae
1 file changedLine totals unavailable