public override RecyclerView.ViewHolder OnCreateViewHolder(ViewGroup parent, int viewType) { View itemView = LayoutInflater.From(parent.Context).Inflate(Resource.Layout.RecyclerViewCard, parent, false); PhotoViewHolder vh = new PhotoViewHolder(itemView, OnClick); ParentContext = parent.Context; return(vh); }
public override void OnBindViewHolder(RecyclerView.ViewHolder holder, int position) { PhotoViewHolder vh = holder as PhotoViewHolder; Picasso.With(ParentContext).Load(mPhotoAlbum[position]?.imageHref).Error(Resource.Mipmap.defaultImage).Into(vh.Image); vh.Caption.Text = mPhotoAlbum[position].Title; vh.Description.Text = mPhotoAlbum[position].description; }