-
Notifications
You must be signed in to change notification settings - Fork 139
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
gridLayoutManager.setSpanSizeLookup会发生错乱? #13
Comments
这个确实没处理,我抽时间处理一下~ |
youlookwhat
added a commit
that referenced
this issue
Mar 28, 2020
youlookwhat
added a commit
that referenced
this issue
Mar 28, 2020
已处理好,更新最新的包就好了~ |
默认是不显示最后一行的分割线,因为一般会使用到加载更多。 /**
* 设置从哪个位置 结束设置间距
*
* @param startFromSize 一般为HeaderView的个数 + 刷新布局(不一定设置)
* @param endFromSize 默认为1,一般为FooterView的个数 + 加载更多布局(不一定设置)
*/
public GridSpaceItemDecoration setNoShowSpace(int startFromSize, int endFromSize)
// endFromSize: 这个参数设置为 0 |
多谢,看了下代码已经解决了😂 |
解决了就好😘 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
gridLayoutManager.setSpanSizeLookup(new GridLayoutManager.SpanSizeLookup() {
@OverRide
public int getSpanSize(int position) {
//TODO:需要区分单张/多张 所占的位置,
if (position == 0) {
return 6;
}
if (position > 2 && position < 5) {
return 3;
}
return 2;
}
});
配置这个操作之后分割线显示错乱
The text was updated successfully, but these errors were encountered: