OnCreateViewHolder(ViewGroup parent, int viewType) { // Inflate the CardView for the photo: View itemView = LayoutInflater.From(parent.Context). Inflate(Resource.Layout.list_items, parent, false); // Create a ViewHolder to find and hold these view references, and // register OnClick with the view holder: VegeViewHolder vh = new VegeViewHolder(itemView, OnClick, spinner_ItemSelected); return(vh); }
// Create a new photo CardView (invoked by the layout manager): public override RecyclerView.ViewHolder OnCreateViewHolder(ViewGroup parent, int viewType) { // Inflate the CardView for the photo: View itemView = LayoutInflater.From(parent.Context). Inflate(Resource.Layout.list_items, parent, false); // Create a ViewHolder to find and hold these view references, and // register OnClick with the view holder: VegeViewHolder vh = new VegeViewHolder(itemView, OnClick,spinner_ItemSelected); return vh; }