private void repositionViews() { int left, top, right, bottom, i; left = widths[0] - scrollX; i = firstColumn; for (View view : rowViewList) { right = left + widths[++i]; view.layout(left, 0, right, heights[0]); left = right; } top = heights[0] - scrollY; i = firstRow; for (View view : columnViewList) { bottom = top + heights[++i]; view.layout(0, top, widths[0], bottom); top = bottom; } top = heights[0] - scrollY; i = firstRow; for (List<View> list : bodyViewTable) { bottom = top + heights[++i]; left = widths[0] - scrollX; int j = firstColumn; for (View view : list) { right = left + widths[++j]; view.layout(left, top, right, bottom); left = right; } top = bottom; } invalidate(); }
private void addLineView(int l, int t, int r, int b) { if (adapter.hasLineView()) { lineView = adapter.getView(-2, -2, null, this); lineView.layout(l, t, r, b); addView(lineView, 0); } }
private View makeAndSetup(int row, int column, int left, int top, int right, int bottom) { final View view = makeView(row, column, right - left, bottom - top); view.layout(left, top, right, bottom); return view; }