private void eatChildren(){
  ArrayList<View> tmpChildren=new ArrayList<View>();
  int count=getChildCount();
  for (int i=0; i < count; i++) {
    tmpChildren.add(getChildAt(i));
  }
  setWrappedChildren(tmpChildren);
}

private void eatChildren ( ) { ArrayList < View > tmpChildren = new ArrayList < View > ( ) ; int count = getChildCount ( ) ; for ( int i = 0 ; i < count ; i ++ ) { tmpChildren . add ( getChildAt ( i ) ) ; } setWrappedChildren ( tmpChildren ) ; }
removes children that belong directly to the wrappinglayout , re - adding them as wrapped children . this allows to set the wrappinglayout contents from xml
