Android - Activity / Thread / Surfaceview example needed

view story

http://stackoverflow.com – I have been struggling for weeks to try to create an Android app that does the following: (1) Has two activities (2) Each activity lets you navigate to the other one (3) Each activity has a SurfaceView, and it's own Thread which draws on the SurfaceView (4) Works properly when the app is put into the background, and then resumes again (eg. press the Home button, then press the App's icon again). I have got 1-3 above to work, but cannot make the app. resume properly. It usually crashes, or sometimes restart the whole app (but not the activity that you were on when the app went to the ba (HowTos)