This app have 2 Activities: MainActivity and SettingActivity (using an intent to send value). ...MainActivity :
String set="1";
public void onCreate(Bundle instant) {
super.onCreate(instant);
setContentView(R.layout.camera);
...when my app is running, i change value of set : set="2"
by SettingActivity , and it work correctly in MainActivity.
Then, i press the Home button, and start this app again , it work with set="1"
, in layout camera.xml ;
And when i press the Back button : after a little change in screen, it work with set="2"
with layout camera.xml .
Why it have 2 layout when i run it again after press Home Button. And why i have to Press the Back button to get the exact value of set
in that time.
i have tried to override onSaveInstanceState (Bundle instant). But it still the same.