android - onSavedInstance in a fragment bundle issue -


public view oncreateview(layoutinflater inflater, viewgroup container, bundle savedinstancestate) {  root = inflater.inflate(r.layout.frag_alert_center, container, false);  if (savedinstancestate != null) {             mitems = (arraylist<alertitemi>) savedinstancestate.getserializable("itembundle");         }   //everything else here } 

at bottom have

@override     public void onsaveinstancestate(bundle outstate) {        super.onsaveinstancestate(outstate);        outstate.putserializable("itembundle", mitems);     } 

am doing right? when debug, never comes oncreateview() when should.


Comments

Popular posts from this blog

php - Calling a template part from a post -

Firefox SVG shape not printing when it has stroke -

How to mention the localhost in android -