- public class InScrollListView extends ListView {
- public InScrollListView(Context context) {
- super(context);
- }
- public InScrollListView(Context context, AttributeSet attrs, int defStyle) {
- super(context, attrs, defStyle);
- }
- public InScrollListView(Context context, AttributeSet attrs) {
- super(context, attrs);
- }
- @Override
- public void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
- int expandSpec = MeasureSpec.makeMeasureSpec(
- Integer.MAX_VALUE >> 2, MeasureSpec.AT_MOST);
- super.onMeasure(widthMeasureSpec, expandSpec);
- }
- }
ScrollView嵌套ListView解决办法
最新推荐文章于 2021-12-30 16:46:51 发布