Exemplo n.º 1
0
        private View GetTemplateDelegate(int i, ForumBoards forumBoards, View arg3)
        {
            var view = Activity.LayoutInflater.Inflate(Resource.Layout.ForumMainPagePinnedBoardItem, null);
            var root = view.FindViewById(Resource.Id.ForumMainPagePinnedBoardItemRootContainer);

            root.Click += OnPinnedBoardClick;
            root.Tag    = (int)forumBoards;

            var txt = forumBoards.GetDescription();

            if (txt.Length > 20 && txt.Length < 23)
            {
                txt = txt.Substring(0, 20) + "...";
            }
            view.FindViewById <TextView>(Resource.Id.ForumMainPagePinnedBoardItemText).Text = txt;


            return(view);
        }