Пример #1
0
            public ButtonVH(View itemView, ButtonItemAdapter adapter)
                : base(itemView)
            {
                Title  = itemView.FindViewById <TextView>(Resource.Id.md_title);
                Button = itemView.FindViewById <Button>(Resource.Id.md_button);

                _adapter = adapter;

                itemView.SetOnClickListener(this);
                Button.SetOnClickListener(this);
            }
Пример #2
0
        public void ShowCustomList(object sender, EventArgs e)
        {
            ButtonItemAdapter adapter = new ButtonItemAdapter(this, Resource.Array.socialNetworks);

            adapter.SetCallbacks(
                itemIndex => ShowToast("Item clicked: " + itemIndex),
                buttonIndex => ShowToast("Button clicked: " + buttonIndex));
            new MaterialDialog.Builder(this)
            .Title(Resource.String.socialNetworks)
            .Adapter(adapter, null)
            .Show();
        }