Ejemplo n.º 1
0
 private void layoutChildren() {
   final int childCount = getChildCount();
   for (int i = 0; i < childCount; i++) {
     final View child = getChildAt(i);
     layoutChild(child);
   }
 }
Ejemplo n.º 2
0
 private void measureAndLayoutChild(View v) {
   int childWidthMeasureSpec = MeasureSpec.makeMeasureSpec(getWidth(), MeasureSpec.EXACTLY);
   int childHeightMeasureSpec = MeasureSpec.makeMeasureSpec(getHeight(), MeasureSpec.EXACTLY);
   measureChild(v, childWidthMeasureSpec, childHeightMeasureSpec);
   layoutChild(v);
 }