I have this problem now: java.lang.RuntimeException: Parcelable encountered IOException writing serializable object .. Class Filho implements serializable. How to solve?
public View getView(int position, View view, ViewGroup parent)
{
final Filho filhoPosition = this.listaFilhos.get(position);
view = LayoutInflater.from(this.context).inflate(R.layout.lista_filho,null);
TextView textViewNomeFilho = (TextView) view.findViewById(R.id.textViewNomeFilho);
TextView textViewTelefoneFilho = (TextView) view.findViewById(R.id.textViewTelefoneFilho);
ImageView imageViewFotoFilho = (ImageView) view.findViewById(R.id.imageViewFotoFilho);
textViewNomeFilho.setText(filhoPosition.getNome());
textViewTelefoneFilho.setText(filhoPosition.getTelefone());
imageViewFotoFilho.setImageBitmap(filhoPosition.getFoto());
final ImageButton imageButtonConfigFilho = (ImageButton) view.findViewById(R.id.imageButtonConfigFilho);
imageButtonConfigFilho.setOnClickListener(new View.OnClickListener(){
@Override
public void onClick(View v){
filho = new Filho(filhoPosition.getIdFilho(),filhoPosition.getNome(),filhoPosition.getTelefone(),filhoPosition.getFoto(),filhoPosition.getLoginConfig());
Intent it = new Intent(context, CadastrarFilhoActivity.class);
it.putExtra("filho",filho);
context.startActivity(it);
}
});
return view;
}