public CardHolderView(CGRect rect, List <Headline> headlines) { Frame = rect; Headlines = headlines; visibleCards = new List <HeadlineView>(); var i = 0; while (i != defaultCountOfVisibleCards) { var headline = new HeadlineView(headlines[i]); headline.OnSwipe += HandleOnSwipe; visibleCards.Add(headline); i++; } LayoutCards(); }
public HeadlineView ViewForCardAtIndex(int index) { var view = new HeadlineView(Headlines[index]); return(view != null ? view : null); }