ForBritishEyesOnly icon indicating copy to clipboard operation
ForBritishEyesOnly copied to clipboard

Scroll position and navigation history are lost across process death

Open Zhuinden opened this issue 4 years ago • 2 comments

I tried putting the app in background to see what happens, and the first screen gets reloaded.

But that's not the general expected behavior.

I wonder if Square already has something in place to make the restoration of workflow stack easy.

Zhuinden avatar May 04 '20 07:05 Zhuinden

There is a snapshot api. Try uncomment code in the activity

digitalbuddha avatar May 04 '20 10:05 digitalbuddha

This should work, it's likely that the templates are out of date.

Note that saving and restoring view state is exercised by https://github.com/square/workflow/blob/master/kotlin/samples/tictactoe/app/src/androidTest/java/com/squareup/sample/TicTacToeEspressoTest.kt#L131

rjrjr avatar May 04 '20 17:05 rjrjr