Ejemplo n.º 1
0
        protected override RecyclerView.ViewHolder CreateSectionHeaderViewHolder(ViewGroup parent)
        {
            var sectionHeaderTextView = RecyclerViewAdapter.CreateTextView(parent);

            sectionHeaderTextView.SetBackgroundColor(Color.LightBlue);
            sectionHeaderTextView.TextAlignment = TextAlignment.Center;

            return(new ViewHolder(sectionHeaderTextView));
        }
Ejemplo n.º 2
0
        protected override RecyclerView.ViewHolder CreateItemViewHolder(ViewGroup parent)
        {
            var itemTextView = RecyclerViewAdapter.CreateTextView(parent);
            var viewHolder   = new ViewHolder(itemTextView);

            itemTextView.Click += (sender, e) =>
            {
                this.AddNewRow(viewHolder.Section);
            };

            return(viewHolder);
        }