question: public void addHeaderView ( View view , int viewHeight , int expandHeight ) { if ( expandHeight != - 1 ) { mHeaderViewExpandHeight = ScreenUtil . dip2px ( mContext , expandHeight ) ; } mHeaderViews . clear ( ) ; mHeaderView = view ; if ( mHeaderView . getLayoutParams ( ) == null ) { mHeaderView . setLayoutParams ( new LinearLayout . LayoutParams ( LayoutParams . MATCH_PARENT , ScreenUtil . dip2px ( mContext , viewHeight ) ) ) ; } markHeaderViewHeight ( mHeaderView ) ; mHeaderView . getLayoutParams ( ) . height = 0 ; mHeaderViews . add ( mHeaderView ) ; if ( mAdapter != null ) { if ( ! ( mAdapter instanceof XWrapAdapter ) ) { mAdapter = new XWrapAdapter ( mHeaderViews , mFootViews , mAdapter ) ; } } }
target:  add header View with the head height and expandheight