pitr / gemini-ios

Elaho - iOS browser for Gemini protocol
Mozilla Public License 2.0
116 stars 6 forks source link

Scroll position not preserved on app switch #48

Open tdb-alcorn opened 1 year ago

tdb-alcorn commented 1 year ago

When I switch to another app or the home screen and then switch back to Elaho, the current page is reloaded and the scroll position is not preserved. I'm not sure if it is related to this issue or if I should open a new one.

Originally posted by @balazsbotond in https://github.com/pitr/gemini-ios/issues/10#issuecomment-955731827

I'm also experiencing the same issue as above. I believe it probably merits being it's own issue, since what's needed to fix this is different from the referenced issue. Afaik, iOS can purge an app from memory at any time if it is in the background. In this case it appears this is happening as soon as I switch away from Elaho. Relatedly, I'm also seeing the Elaho loading screen with the buck every time I open the app. Therefore, to fix this Elaho needs to write scroll position to storage somehow and reload it into memory whenever re-entering the app.

acidus99 commented 1 year ago

This is a pretty terrible, especially for INPUT response. I'll be using Elaho, write a post on Station or entry an input field, a notification or something else comes in which takes app focus form Elaho, then Elaho refreshes the page, losing my text in the input box.