예제 #1
0
 public override void OnBindViewHolder(RecyclerView.ViewHolder holder, int position)
 {
     if (holder is BaseHolder)
     {
         //myHolder.ItemView.Tag = position;
         //myHolder.
         BaseHolder myHolder = holder as BaseHolder;
         OnConvertView(myHolder, position);
     }
 }
예제 #2
0
        public override RecyclerView.ViewHolder OnCreateViewHolder(ViewGroup parent, int viewType)
        {
            if (viewType == VIEW_FOOTER)
            {
                footerView = inflater.Inflate(Resource.Layout.item_recyclerView_footer_loading, parent, false);
                return(new  FooterViewHolder(footerView));
            }

            if (viewType == VIEW_NULL)
            {
                emptyView = inflater.Inflate(Resource.Layout.item_recyclerView_footer_empty, parent, false);
                return(new EmptyViewHolder(emptyView));
            }
            View view = inflater.Inflate(itemLayoutId, parent, false);

            return(BaseHolder.GetRecyclerHolder(context, view, ItemClick, ItemLongClick));
        }