コード例 #1
0
        //INITIALIZE VH
        public override RecyclerView.ViewHolder OnCreateViewHolder(ViewGroup parent, int viewType)
        {
            View     v      = LayoutInflater.From(parent.Context).Inflate(Resource.Layout.Model, parent, false);
            MyHolder holder = new MyHolder(v, onClick);

            return(holder);
        }
コード例 #2
0
        //BIND DATA
        public override void OnBindViewHolder(RecyclerView.ViewHolder holder, int position)
        {
            MyHolder h = holder as MyHolder;

            h.NameTxt.Text = tvShows[position].Name;
            h.Img.SetImageResource(tvShows[position].Image);
        }