public virtual AbstractViewHolder GetCellViewHolder(int xPosition, int yPosition) { CellRecyclerView cellRowRecyclerView = (CellRecyclerView)FindViewByPosition(yPosition); if (cellRowRecyclerView != null) { return((AbstractViewHolder)cellRowRecyclerView.FindViewHolderForAdapterPosition(xPosition)); } return(null); }
public virtual AbstractViewHolder[] GetVisibleViewHolders() { int visibleChildCount = FindLastVisibleItemPosition() - FindFirstVisibleItemPosition() + 1; int index = 0; AbstractViewHolder[] views = new AbstractViewHolder[visibleChildCount]; for (int i = FindFirstVisibleItemPosition(); i < FindLastVisibleItemPosition() + 1; i++) { views[index] = (AbstractViewHolder)mCellRowRecyclerView.FindViewHolderForAdapterPosition(i); index++; } return(views); }
public virtual AbstractViewHolder[] GetVisibleCellViewsByColumnPosition(int xPosition) { int visibleChildCount = FindLastVisibleItemPosition() - FindFirstVisibleItemPosition() + 1; int index = 0; AbstractViewHolder[] viewHolders = new AbstractViewHolder[visibleChildCount]; for (int i = FindFirstVisibleItemPosition(); i < FindLastVisibleItemPosition() + 1; i++) { CellRecyclerView cellRowRecyclerView = (CellRecyclerView)FindViewByPosition(i); AbstractViewHolder holder = (AbstractViewHolder)cellRowRecyclerView.FindViewHolderForAdapterPosition(xPosition); viewHolders[index] = holder; index++; } return(viewHolders); }