消息列表添加头、尾布局,xml居中属性失效
文章目录
生成view的时候使用:LayoutInflater.from(getContext()).inflate(R.layout.my_view, (ViewGroup) view,false);而不是:LayoutInflater.from(getContext()).inflate(R.layout.my_view, null,false);
生成view的时候使用:LayoutInflater.from(getContext()).inflate(R.layout.my_view, (ViewGroup) view,false);而不是:LayoutInflater.from(getContext()).inflate(R.layout.my_view, null,false);
评论
登录后参与技术讨论,分享你的经验与见解。
登录 / 注册暂无评论