Exemplo n.º 1
0
 private void loadData(Bundle savedInstanceState) {
   Elements data;
   if (savedInstanceState != null
       && (data = (Elements) savedInstanceState.getSerializable(DATA)) != null) {
     adapter.setData(data);
   } else {
     refresh();
   }
 }
Exemplo n.º 2
0
 @Override
 protected void onSaveInstanceState(Bundle outState) {
   super.onSaveInstanceState(outState);
   outState.putSerializable(DATA, adapter.getData());
 }