boolean removeViewIfHidden(View view){
  final int index=mCallback.indexOfChild(view);
  if (index == -1) {
    if (mHiddenViews.remove(view) && DEBUG) {
      throw new IllegalStateException("view is in hidden list but not in view group");
    }
    return true;
  }
  if (mBucket.get(index)) {
    mBucket.remove(index);
    mCallback.removeViewAt(index);
    if (!mHiddenViews.remove(view) && DEBUG) {
      throw new IllegalStateException("removed a hidden view but it is not in hidden views list");
    }
    return true;
  }
  return false;
}

boolean removeViewIfHidden ( View view ) { final int index = mCallback . indexOfChild ( view ) ; if ( index == - 1 ) { if ( mHiddenViews . remove ( view ) && DEBUG ) { throw new IllegalStateException ( "view is in hidden list but not in view group" ) ; } return true ; } if ( mBucket . get ( index ) ) { mBucket . remove ( index ) ; mCallback . removeViewAt ( index ) ; if ( ! mHiddenViews . remove ( view ) && DEBUG ) { throw new IllegalStateException ( "removed a hidden view but it is not in hidden views list" ) ; } return true ; } return false ; }
removes a view from the viewgroup if it is hidden .
