Android GridView
当GridView和SrollView嵌套使用时,GridView的高度就会产生问题,可以通过继承GridView,重写
protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) 方法,如
protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) { int expandSpec = MeasureSpec.makeMeasureSpec( Integer.MAX_VALUE >> 2, MeasureSpec.AT_MOST); super.onMeasure(widthMeasureSpec, expandSpec); }