Activity life cycle problem. After pressing the Home button, your photo interface will be destroyed. After reopening, the life cycle method will be repeated, which will cause the phenomenon you see that you return to the preview interface. I don’t know what your needs are that would make you want to freeze that interface, but since you have pressed the photo button, you will get the image at the moment when you took the photo. You can save the image, and you can check whether it was saved when you come back. If there is an image, the image will be displayed. If not, open the preview. I don’t know if this idea can meet your needs.
Activity life cycle problem. After pressing the Home button, your photo interface will be destroyed. After reopening, the life cycle method will be repeated, which will cause the phenomenon you see that you return to the preview interface. I don’t know what your needs are that would make you want to freeze that interface, but since you have pressed the photo button, you will get the image at the moment when you took the photo. You can save the image, and you can check whether it was saved when you come back. If there is an image, the image will be displayed. If not, open the preview. I don’t know if this idea can meet your needs.