how to keep the applications that have been used can be saved the last activity, meaning it does not return to the initial settings. for example I have an application the on button turns off, when I turn on the button then close the application and open it again. the button returns to the initial settings i.e. off. I want the button to stay on because it's already turned on